Bug 814153 - Need additional security checks for the "settings" permission. r=bent

This commit is contained in:
Gregor Wagner 2012-11-29 14:23:55 -08:00
parent b48649b1f9
commit 3e4ab34c8b

View File

@ -95,6 +95,11 @@ this.SettingsChangeNotifier = {
}));
break;
case "Settings:RegisterForMessages":
if (!aMessage.target.assertPermission("settings-read")) {
Cu.reportError("Settings message " + msg.name +
" from a content process with no 'settings-read' privileges.");
return null;
}
debug("Register!");
if (this.children.indexOf(mm) == -1) {
this.children.push(mm);