summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--chrome/renderer/notification_provider.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/chrome/renderer/notification_provider.cc b/chrome/renderer/notification_provider.cc
index 4642cff..414966f 100644
--- a/chrome/renderer/notification_provider.cc
+++ b/chrome/renderer/notification_provider.cc
@@ -95,11 +95,13 @@ void NotificationProvider::OnNavigate() {
bool NotificationProvider::ShowHTML(const WebNotification& notification,
int id) {
- // Disallow HTML notifications from non-HTTP schemes.
+ // Disallow HTML notifications from unwanted schemes. javascript:
+ // in particular allows unwanted cross-domain access.
GURL url = notification.url();
if (!url.SchemeIs(chrome::kHttpScheme) &&
!url.SchemeIs(chrome::kHttpsScheme) &&
- !url.SchemeIs(chrome::kExtensionScheme))
+ !url.SchemeIs(chrome::kExtensionScheme) &&
+ !url.SchemeIs(chrome::kDataScheme))
return false;
DCHECK(notification.isHTML());