Privacy/Reviews/OSIdleAPI: Difference between revisions

From MozillaWiki
Jump to navigation Jump to search
Line 97: Line 97:
|-
|-
| ''In:''  
| ''In:''  
| addIdleObserver()
| addIdleObserver(), e.g. addIdleObserver(idleObserverObject);
| Requested idle time in seconds. Idle callback function. Active callback function.
| idleObserverObject = {time: someIntValInSeconds, onidle: someIdleCallbackFunction; onactive: someActiveCallbackFunction}
| The requested idle time in seconds is the amount of idle time that needs to elapse before the idle observer receives 'idle' notifications. Notifications are idle and active callback functions. The mininum requested idle time in seconds must be 1 second.
| The idleObserverObject is passed as a paramater to function addIdleObserver(). 'someIntValInSeconds' is the requested idle time in seconds that needs to elapse before the idle observer receives 'idle' notifications. 'someIntValInSeconds' must be a minimum of 1 seconds and a maximum of a PRUint32. 'someIdleCallbackFunction' is the front-end developer defined callback function that is to be called when the user is idle for 'someIntValInSeconds'. 'someActiveCallbackFunction' is the front-end developer defined callback function that is to be called when the user transitions from an idle state to an active state. Please see sample test file: http://mxr.mozilla.org/mozilla-central/source/dom/base/test/test_bug715041.xul
|-
|-
| ''In:''  
| ''In:''  
| removeIdleObserver()
| removeIdleObserver(), e.g. removeIdleObserver(idleObserverObject)
| Requested idle time in seconds. Idle callback function. Active callback function.
| idleObserverObject = {time: someIntValInSeconds, onidle: someIdleCallbackFunction; onactive: someActiveCallbackFunction}
| The requested idle time in seconds is the amount of idle time that needs to elapse before the idle observer receives 'idle' notifications. The notifications are the idle and active callback functions. The mininum requested idle time in seconds must be 1 second.
| The idleObserverObject is passed as a paramater to function addIdleObserver(). 'someIntValInSeconds' is the requested idle time in seconds that needs to elapse before the idle observer receives 'idle' notifications. 'someIntValInSeconds' must be a minimum of 1 seconds and a maximum of a PRUint32. 'someIdleCallbackFunction' is the front-end developer defined callback function that is to be called when the user is idle for 'someIntValInSeconds'. 'someActiveCallbackFunction' is the front-end developer defined callback function that is to be called when the user transitions from an idle state to an active state. Please see sample test file: http://mxr.mozilla.org/mozilla-central/source/dom/base/test/test_bug715041.xul
|-
|-
| ''Out:''  
| ''Out:''  

Revision as of 17:33, 5 July 2012

Document Overview

Feature/Product: WebAPI - OS Idle API
Projected Feature Freeze Date: (tbd)
Product Champions: Bonnie Surender
Privacy Champions: (the privacy Friend you're working with)
Security Contact: Curtis Koenig
Document State: [AT RISK] risk analysis


Timeline:

Architectural Overview: 29-Jun-2012
Recommendation Meeting: n/a
Review Complete ETA: July 2012

Architecture

In this section, the product's architecture is described. Any individual components or actors are identified, their "knowledge" or what data they store is identified, and data flow between components and external entities is described.

The main objective of this feature/product is: to inform general web content within tabs and windows of the user's idle and active state.

Design Documents: https://bugzilla.mozilla.org/show_bug.cgi?id=715041#c21

Components

This feature is a new API in Firefox that web sites may interact with. The API shares information about users' interactions through a set of callbacks registered by websites.

  • Web browser/Firefox
  • Websites
    • Websites loaded onto the browser tab within the browswer window or the window itself.

Users are a component here (they communicate with the browser) but interactions between browser and user are not changed by this feature.

Firefox

  • Prevent the web page from knowing the real timing of when the user goes idle. A fuzz factor/time has been added to the 'idle' and 'active' notifications to mitigate this risk.

How it works:

  • Idle observer requested idle times are in seconds.
  • Randomly generated fuzz times for 'idle' and 'active' events are in milli-seconds.
  • Idle Notifications:
    • When the user stops using the device, i.e. becomes 'idle' the web page is notified after the requested idle time registered with the Idle API plus a random fuzz time have elapsed. This random fuzz time is generated once per state transition. i.e. when the user transitions from the 'active' state to 'idle' state.
  • Active Notifications:
    • When the user starts using the device again, i.e. becomes 'active', the web page is notified immediately if the user directly interacted (mouse over event, keyboard event, touch based event) with the web page.
    • If the user interacts with another application other than the web page, the user has become 'active' but indirectly. When the user becomes indirectly active, 'active' notifications are sent to the registered idle observers after a fuzz time has elapsed. This fuzz time is randomly generated and is generated once per state transition. I.e. when the user transitions from an 'idle' state to an 'active' state a random fuzz time is generated and applied after which time the idle observers are notified that the user is 'active'.
  • The user 'idle' and 'active' status is platform specific.
    • On platforms that do NOT support obtaining system idle time, if the user stops using the web browser but continues to use another application currently executing on the device then the web page is specifically notified that the user is idle despite the fact that the user is using another application. E.g. Linux, Android.
    • The web page is notified immediately that the user is 'active' only when the user specifically interacts with the web page.
    • On platforms that do support obtaining system idle time such as Windows, the web page is notified of user idle status only when the user is completely away from the device.
    • The web page is notified that the user is 'active' with a fuzz time added when the user interacts with any application executing on the device. The user is not directly interacting with the web page.


Stored Data:

There is no stored data.

What Where
Idle observer requested idle time in seconds Array of idle observers
Idle callback function Array of idle observers
Active callback function Array of idle observers

Communication with websites via Idle API

Direction Message Data Notes
In: addIdleObserver(), e.g. addIdleObserver(idleObserverObject); idleObserverObject = {time: someIntValInSeconds, onidle: someIdleCallbackFunction; onactive: someActiveCallbackFunction} The idleObserverObject is passed as a paramater to function addIdleObserver(). 'someIntValInSeconds' is the requested idle time in seconds that needs to elapse before the idle observer receives 'idle' notifications. 'someIntValInSeconds' must be a minimum of 1 seconds and a maximum of a PRUint32. 'someIdleCallbackFunction' is the front-end developer defined callback function that is to be called when the user is idle for 'someIntValInSeconds'. 'someActiveCallbackFunction' is the front-end developer defined callback function that is to be called when the user transitions from an idle state to an active state. Please see sample test file: http://mxr.mozilla.org/mozilla-central/source/dom/base/test/test_bug715041.xul
In: removeIdleObserver(), e.g. removeIdleObserver(idleObserverObject) idleObserverObject = {time: someIntValInSeconds, onidle: someIdleCallbackFunction; onactive: someActiveCallbackFunction} The idleObserverObject is passed as a paramater to function addIdleObserver(). 'someIntValInSeconds' is the requested idle time in seconds that needs to elapse before the idle observer receives 'idle' notifications. 'someIntValInSeconds' must be a minimum of 1 seconds and a maximum of a PRUint32. 'someIdleCallbackFunction' is the front-end developer defined callback function that is to be called when the user is idle for 'someIntValInSeconds'. 'someActiveCallbackFunction' is the front-end developer defined callback function that is to be called when the user transitions from an idle state to an active state. Please see sample test file: http://mxr.mozilla.org/mozilla-central/source/dom/base/test/test_bug715041.xul
Out: Idle callback function. Active callback function. None The idle and active callback functions are determined by the front end developer.


User Data Risk Minimization

In this section, the privacy champion will identify areas of user data risk and recommendations for minimizing the risk.

Alignment with Privacy Operating Principles

In this section, the privacy champion will identify how the feature lines up with Mozilla's privacy operating principles.

See Also: Privacy/Roadmap_2011#Operating_Principles:

Principle: Transparency / No Surprises

(How the feature addresses this)

Recommendations: (what can be improved)


Principle: Real Choice

Recommendations:


Principle: Sensible Defaults

Recommendations:


Principle: Limited Data

Recommendations:

Follow-up Tasks and tracking

What Who Bug Details
[NEW] Initial Overview Discussion Bonnie Surender, Jonas Sicking Meeting time TBD