From 835891b37372e35b083846d781cc1da03a94abd4 Mon Sep 17 00:00:00 2001 From: deepak1556 Date: Thu, 4 Aug 2016 04:30:25 +0530 Subject: [PATCH] browser: register extension scheme as web safe scheme --- atom/browser/atom_browser_main_parts.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/atom/browser/atom_browser_main_parts.cc b/atom/browser/atom_browser_main_parts.cc index a8d18e8c5a..6c2f18be0f 100644 --- a/atom/browser/atom_browser_main_parts.cc +++ b/atom/browser/atom_browser_main_parts.cc @@ -17,6 +17,7 @@ #include "base/command_line.h" #include "base/threading/thread_task_runner_handle.h" #include "chrome/browser/browser_process.h" +#include "content/public/browser/child_process_security_policy.h" #include "v8/include/v8-debug.h" #if defined(USE_X11) @@ -43,6 +44,9 @@ AtomBrowserMainParts::AtomBrowserMainParts() gc_timer_(true, true) { DCHECK(!self_) << "Cannot have two AtomBrowserMainParts"; self_ = this; + // Register extension scheme as web safe scheme. + content::ChildProcessSecurityPolicy::GetInstance()-> + RegisterWebSafeScheme("chrome-extension"); } AtomBrowserMainParts::~AtomBrowserMainParts() {