System and method for applying security policies on multiple assembly caches

Information

  • Patent Application
  • 20080072276
  • Publication Number
    20080072276
  • Date Filed
    August 24, 2006
    19 years ago
  • Date Published
    March 20, 2008
    18 years ago
Abstract
The invention relates to a system and method for providing multiple assembly caches for storing shared application resources. Each assembly cache may be associated with a different security policies, locations, internal structures and management. An application may be determined to have access to an assembly cache based on the permission and security policy of the application and security policy of the assembly cache. Additionally, one or more assembly caches may have other policies for cache retention, resolution, and creation.
Description

DESCRIPTION OF DRAWINGS


FIG. 1 is a high level diagram of the prior art Global Assembly Cache system.



FIG. 2 is a high level block diagram of a system, according to one embodiment of the invention.



FIG. 3 is a block diagram of multiple assembly caches, according to one embodiment of the invention.



FIG. 4 is flow chart for a method storing assemblies into assembly cache, according to one embodiment of the invention.



FIG. 5 is a runtime application method, according to one embodiment of the invention.





DETAILED DESCRIPTION


FIG. 2 depicts a computer (100) with multiple applications (12-16). As commonly known, applications may vary with respect to function and ability. Applications (12-16) and the resources needed to execute the applications may be locally available in an assembly cache (24-28) or downloaded to a computer from an application source (34) through a network connection (32). Other sources may be included (e.g., hard disk, CD, drive storage). The application resources, which may be received with the application, refer to application assembly including, for example, .EXE files and .DLL files, among other resources. Application code and the resources used for execution on a computer may originate from various sources that may be considered as secure, un-secure, or semi-secure.


Execution of applications may be carried out using a VM 18 (e.g., Common Language Runtime, ECMA runtime, etc.). A security manager 20 allows the VM 18, at runtime, to configure the rights to one or more permissions (e.g., User Interface, Web Access, Printing, etc.) allowed to an application based on application characteristics (e.g., code group). The VM 18 and security managers 20 are generally known in the art. A novel aspect of the system includes the use of concurrent multiple assembly caches (24-28) by a single application. A Resource Installer 22 may be used to install resources (e.g., assembly files) into one or more assembly caches 24-28.


An application may include one or more assemblies needed for the application to run properly. One or more applications may share their assemblies with other applications running on the computer. Assemblies and/or application resources may be installed into assembly caches 24-28 to facilitate this sharing between applications while conserving their own security policies. Like the one or more applications they are used for, assemblies may come from various sources including, but not limited to, internet, intranet, local computer, remote server, and/or readable media. The assembly caches may be used to separately store assemblies into respective caches based on the source from which the assembly came, along with other factors that may be determined by a security policy. For example, an Internet assembly cache may be created with security policy and permissions relating to assemblies from the Internet.


A security policy may consist of a series of permissions and rights from various policy levels. An assembly's granted and refused permission sets are resolved, at runtime, by the security manager 20 using the permissions found in all (or some) policy levels including enterprise, machine, user and application domain policy levels. Policy levels are applied based on the membership of the assembly with defined identity, publisher, source (e.g., URL, website), origin (e.g., Internet, Intranet) and/or other information. Each policy level that an assembly belongs to may define permissions. The combination of permissions may be referred to as a permission set. Rights may also be assigned according to policy level and/or other assembly information.


An assembly cache may be associated with any security policy. In fact, each assembly caches may be associated with a different security policy. The security policy may be a combination of permissions from one or more of an enterprise, machine, user or application domain policy level. Policies and permissions on the enterprise level may apply to all (or some) computers of the network. Unique machines on the network may require a machine policy and permissions that are not addressed under enterprise policy. A user policy and permissions may apply to an individual user that logs in to the computer. Application level policy and permissions may be defined by the application developer to ensure optimal functionalities of the application. The combination of enterprise, machine, user, application, and/or other policies determine the set of permissions a security policy may enforce for an assembly cache. A security policy may be predetermined and characterized by name.



FIG. 3 is a block diagram of multiple assembly caches, according to one example of the invention. A user assembly cache 50 may be shared by multiple users of the system having the same or similar user level permissions. An Internet assembly cache 52 may be used for assemblies downloaded from the Internet. Assemblies stored in the Internet assembly cache 52 may have higher restrictions since assemblies from the Internet may be less trusted. Enterprise assembly cache 54 may be for assemblies coming from trusted company intranet or local network. Such a cache may be implemented remotely on an enterprise server or, in a hybrid mode, appear as a local cache to the VM while residing on a remote server. A fully trusted assembly cache (56) would be the equivalent of the currently existing global assembly cache (GAC).



FIG. 4 illustrates one method for installing an assembly into an assembly cache based on its evidence. An assembly may be received from a source (e.g., known or unknown). The assembly may be installed into an assembly cache (e.g., via resource installer) (operation 2) based on assembly identity, publisher, source, origin, and/or other information. This operation may be carried out to install an assembly (operation 4) and determine the permission set allowed for an assembly (operation 6). The resulting permission set may be compared to the permissions required by a security policy of an assembly cache (operation 8). If a match between the assembly permission set and the assembly cache's permission set is observed then the assembly is installed into the corresponding assembly cache for future use by multiple applications (operation 10). A match may be determined to varying degrees. If a majority of the permissions are the same or at least similar to the security policy, a positive match may be determined. If no corresponding assembly cache exists (not shown in figure), then the assembly may not be suitable for sharing and thus stored into a private directory or else the assembly permission set may be modified to fit into an existing assembly cache.


The permissions assigned to an application at runtime may be compared to the permission set of an assembly cache. Rights may be further enforced upon access. Thus, one or more applications operating according to the same or similar permissions set (security policy) may share resources from a commonly shared assembly cache without having to create private resource directories for each application. Additionally, the application(s) may be restricted from accessing secure shared resources for which they do not have the appropriate permissions and permissions rights.


One or more applications may access one or more of the assembly caches during runtime. By way of example, application code originating from the Internet (e.g., unsecured source) may have limited permissions with respect to actions that may be performed. An application can potentially access assemblies from any cache based on the security manager's (20) restriction which, intersect the application permission set with the one from the assembly cache, and any other restriction of assembly itself could have. This prevents the application from being granted elevated rights. In another example, an application at runtime may be fully trusted and have unrestricted rights on permissions to perform any number of actions. An attempt by the fully trusted application to access an assembly cache with less trusted resources may, at first glance, seem unproductive since the fully trusted application would not be able to perform all the actions necessary for proper function of the application. The security policy of the assembly cache would not allow all the requested permissions to execute. However, this functions to contain un-trusted, or semi-trusted, code because it makes sure that the application will not supply permissions higher than what the assembly cache provides.



FIG. 5 is a flow chart for a method performed during application runtime, according to one embodiment of the invention. An applications permission set and security policy may be determined at runtime (e.g., using security manager). An application having a security policy may access an assembly cache having a similar security policy. An application is launched (operation 40) either by the operating system, which will start a new VM, or directly by an existing VM instance. The application may be evaluated based on evidence from the application code including, but not limited to, identity, publisher, source (e.g., URL, website), origin (e.g., Internet, Intranet) and/or other information (operation 42). The evidence from the application may be used to resolve the permissions of the application according to one or more of an enterprise, machine, user, and/or other policy level (operation 44). The resulting permission set may be matched to a transparent assembly cache which has the same or similar permissions in the form of a security policy (operation 48). The operation of FIG. 5 may allow applications running on a machine to share code resources (e.g., assemblies) securely and more efficiently with respect to application characteristics.


Each assembly cache may further have configurable rules for assembly resolution (e.g. cache priority), assembly retention (e.g., Internet cache), and assembly creation (e.g. transparent cache, cache using digital signatures). The rules may aid in keeping assembly caches up to date with current application running on a system and for maximizing use of shared memory.


In order to reduce the performance impact of delays introduced with multiple assembly caches, some instances of the multiple assembly caches may be implemented using a flat naming structure. Shared assemblies stored in the assembly cache may be called from other code named using name, version, culture, and public key token, among other things, in one long string rather than in complicated hierarchical directories of the prior art. Thus, for some multiple assembly caches the assemblies are simple, faster to browse, and easier to cache.


In the foregoing specification, the invention has been described with reference to specific embodiments thereof. Various modifications and changes may be made thereto without departing from the broader spirit and scope of the invention. The specification and drawings are, accordingly, to be regarded in an illustrative rather than a restrictive sense.

Claims
  • 1. A computer implemented system for securely executing an application using a virtual machine, including: a plurality of assembly caches for storing application runtime resources;means for assigning a security policy to each of the plurality of assembly caches;means for retrieving corresponding application runtime resources from one or more of the plurality of assembly caches based at least in part on the executing application and the assigned security policies.
  • 2. The system of claim 1, further including means for: receiving assembly information;determining a security policy for the assembly; andcaching the received assembly within one or the plurality of assembly caches based on security policy of the assembly cache to match the assembly.
  • 3. The system of claim 1, wherein the security policies include information from enterprise level, machine level, user level or application level.
  • 4. The system of claim 2, further including means for creating an assembly cache if an existing assembly cache does not match the determined security policy for the assembly.
  • 5. The system of claim 1, wherein objects cached in the plurality of assembly caches are stored in a flat file-based structure.
  • 6. The system of claim 1, wherein the plurality of assembly caches are remote with respect to the virtual machine.
  • 7. The system of claim 1, wherein the plurality of assembly caches are replicated between multiple cache systems on a network.
  • 8. The system of claim 1, wherein the plurality of assembly caches operate as a local cache while residing on a remote server.
  • 9. A computer implemented method for securely executing an application using a virtual machine, including step for: storing application runtime resources in one or more of a plurality of assembly caches;assigning a security policy to each of the plurality of assembly caches;retrieving corresponding application runtime resources from one or more of the plurality of assembly caches based at least in part on the executing application and the assigned security policies.
  • 10. The method of claim 9, further including steps for: receiving assembly information;determining a security policy for the assembly; andcaching the received assembly within one or the plurality of assembly caches based on security policy of the assembly cache to match the assembly.
  • 11. The method of claim 9, wherein the security policies include information from enterprise level, machine level, user level or application level.
  • 12. The method of claim 10, further including step for creating an assembly cache if an existing assembly cache does not match the determined security policy for the assembly.
  • 13. The method of claim 9, wherein objects cached in the plurality of assembly caches are stored in a flat file-based structure.
  • 14. The method of claim 9, wherein the plurality of assembly caches are remote with respect to the virtual machine.
  • 15. The method of claim 9, wherein the plurality of assembly caches are replicated between multiple cache systems on a network.