Techniques for sharing virtual machine (VM) resources
Techniques for sharing virtual machine (VM) resources are provided. A relative location for a resource within a VM is created; the relative location dynamically resolves to a particular physical location when a principal requests access to the resource at runtime. The principal is located outside an environment associated with the VM. Authentication and access restrictions are dynamically enforced against the requests made by the principal before a connection is permitted between the principal and the resource (the resource located within the environment of the VM).
1. A method, comprising:
receiving, by a Virtual Machine (VM) access layer service that executes on a processor as executable instructions from a non-transitory computer-readable storage medium, a dynamic reference to an internal resource of a VM from an external resource that is external to the VM, wherein the internal resource resides in a local location within the processing environment of the VM and is a shared resource that is being externally shared outside a VM processing context with the external resource, wherein receiving further includes decrypting the dynamic reference, and wherein decrypting further includes verifying a digital signature of the decrypted dynamic reference;
dynamically resolving, by a Virtual Machine (VM) access layer service that executes on a processor, the dynamic reference to an internal location of the VM; and
providing, by a Virtual Machine (VM) access layer service that executes on a processor, the external resource access to the internal resource from the internal location based on the dynamically resolving of the dynamic reference.
2. The method of claim 1 , wherein receiving further includes authenticating the external resource and the dynamic reference for access to the internal resource.
3. The method of claim 2 , wherein authenticating further includes ensuring that at least a portion of the dynamic reference includes an identifier that matches an external resource identifier for the external resource.
4. A method, comprising:
receiving, by a Virtual Machine (VM) access layer service that executes on a processor as executable instructions from a non-transitory computer-readable storage medium, a dynamic reference to an internal resource of a VM from an external resource that is external to the VM, wherein the internal resource resides in a local location within the processing environment of the VM and is a shared resource that is being externally shared outside a VM processing context with the external resource;
dynamically resolving, by a Virtual Machine (VM) access layer service that executes on a processor, the dynamic reference to an internal location of the VM; and
providing, by a Virtual Machine (VM) access layer service that executes on a processor, the external resource access to the internal resource from the internal location based on the dynamically resolving of the dynamic reference, wherein providing further includes enforcing access restrictions against the external resource while the external resource accesses the internal resource at the internal location, wherein enforcing further includes obtaining the access restrictions as data decrypted from the dynamic reference.