1. A method for controlling access to a delivery of sensor information to a requesting application running on an electronic device, the method comprising: collecting, by a sensor in the electronic device hosting a plurality of applications, the sensor information associated with at least one user input action; intercepting, by the electronic device, a request to access the sensor information from the requesting application of the plurality of applications; determining, by the electronic device, that the requesting application is running in one of a foreground of the electronic device and a background of the electronic device; and controlling, by the electronic device, access of the requesting application to the sensor information associated with the at least one user input action by applying a set of access rules including at least one rule based on the determination that the requesting application is running in the foreground of the electronic device and at least one rule based on the determination that the requesting application is running in the background of the electronic device, wherein the set of rules defines access control policies to permit or to prevent the delivery of the sensor information to the requesting application running on the electronic device, the access control policies being associated with the sensor information collected by the sensor in the electronic device.