Security/Reviews/Gaia/SystemMessageHandler

From MozillaWiki
< Security‎ | Reviews‎ | Gaia
Revision as of 17:58, 15 February 2013 by St3fan (talk | contribs) (→‎Components)
Jump to navigation Jump to search


App Review Details

  • System Component: System Message Handler
  • Review Date: 15 Feb 2013
  • Review Lead: Stefan Arentz
  • Review Bug: bug 751025 [Security Review] System Message Handler

Overview

Architecture

Components

The following DOM API is exposed to support the System Message API:

interface nsIDOMSystemMessageCallback : nsISupports {
    void handleMessage(in jsval message);
};

interface nsIDOMNavigatorSystemMessages : nsISupports {
{
    void mozSetMessageHandler(in DOMString type, in nsIDOMSystemMessageCallback callback);
    boolean mozHasPendingMessage(in DOMString type); 
};

Relevant Documentation

TODO I don't think there is more official documentation?

Relevant Source Code

  • gecko/dom/messages/interfaces/nsIDOMNavigatorSystemMessages.idl
  • gecko/dom/messages/interfaces/nsISystemMessagesInternal.idl
  • gecko/dom/messages/SystemMessageInternal.js
  • gecko/dom/messages/SystemMessageManager.js
  • gecko/dom/messages/SystemMessageManager.manifest
  • gecko/dom/messages/SystemMessagePermissionsChecker.jsm

Additional files that changed to support the System Messages:

  • gecko/b2g/chrome/content/shell.js
  • gecko/b2g/chrome/content/shell.js
  • gecko/config/autoconf.mk.in
  • gecko/dom/base/Navigator.cpp
  • gecko/dom/base/Navigator.h
  • gecko/dom/base/nsDOMClassInfo.cpp
  • gecko/dom/base/nsDOMWindowUtils.cpp
  • gecko/dom/base/nsGlobalWindow.cpp
  • gecko/dom/base/nsGlobalWindow.h
  • gecko/dom/Makefile.in
  • gecko/toolkit/toolkit-makefiles.sh

Code Review Notes

Actions & Recommendations