Confirmed users
971
edits
Line 183: | Line 183: | ||
==== Post Messages ==== | ==== Post Messages ==== | ||
The dialer (and the other code in the communications app) depends on window.postMessage() and setEventHandler('message',...) to send and receive cross origin messages. Usually between different pages in the same app, like dialer/index.html and dialer/oncall.html but also for remote sites like for example when we integrate with Facebook. | |||
The app handles the following post messages: | |||
* js/dialer.js:200 | |||
** "closing" | |||
** "notification" | |||
** "recent" | |||
** "contactsiframe" | |||
* js/oncall.js:505 | |||
** "exitCallScreen" | |||
* js/ussd.js:33 | |||
** "reply" | |||
** "close" | |||
ISSUE: None of the handlers verify that the message originated from a trusted/expected source. | |||
I was able to exploit this and let remote content post messages to the Dialer to trigger Missed Calls notifications to appear. | |||
ACTION: Add strict checking of event sources as described on MDN at https://developer.mozilla.org/en-US/docs/DOM/window.postMessage#Security_concerns | |||
* {{bug|845487}} Dialer responds to cross-origin messages without verifying the source (exploitable) | |||
====Web Activity Usage ==== | ====Web Activity Usage ==== |