Patent ID: 9176757
Filing Date: 2015-11-03
Classification: G06F

Abstract:
1. A method for the virtualization of a hardware resource associated with a computer system by an executable piece of code adapted for being injected into a process belonging to an application that is executed on an operating system comprising at least one application programming interface that is executed on the computer system, the method comprising: intercepting a call from the process belonging to the application to an application programming interface service related with the management of a data flow produced between the process and the hardware resource, the intercepting comprising at least redirecting an application programming interface service related with the management of the flow produced between the process and the hardware resource to a corresponding service comprised in the piece of code; and managing the data flow produced between the process and the hardware resource by the piece of code on the basis of the interception of the call from the process to the application programming interface service related with the management of the data flow produced between the process and the hardware resource, wherein the application interface service is: a function; or an object method, and wherein redirecting an application programming interface service related with the management of the data flow produced between the process and the hardware resource to a corresponding service comprised in the piece of code comprises: loading in the memory a dynamic link library comprising the application programming interface function or object method to be redirected; replacing, in a function pointer table for the application programming interface functions or object methods comprised in the loaded dynamic link library, the initial memory address in which the application programming interface function or object method to be redirected is stored with the initial memory address in which the corresponding function or object method comprised in the piece of code is stored, wherein the replacing, in case the application programming interface service is an object method is performed after having verified that the object associated with the method to be redirected is created for the first time.