Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(443)

Side by Side Diff: chrome/browser/search/local_ntp_source.cc

Issue 2012393003: Replace frame-src with child-src in WebUI CSP (Closed) Base URL: https://chromium.googlesource.com/a/chromium/src.git@csp
Patch Set: Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/search/local_ntp_source.h" 5 #include "chrome/browser/search/local_ntp_source.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <memory> 9 #include <memory>
10 10
(...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after
263 std::string filename; 263 std::string filename;
264 webui::ParsePathAndScale(request->url(), &filename, NULL); 264 webui::ParsePathAndScale(request->url(), &filename, NULL);
265 for (size_t i = 0; i < arraysize(kResources); ++i) { 265 for (size_t i = 0; i < arraysize(kResources); ++i) {
266 if (filename == kResources[i].filename) 266 if (filename == kResources[i].filename)
267 return true; 267 return true;
268 } 268 }
269 } 269 }
270 return false; 270 return false;
271 } 271 }
272 272
273 std::string LocalNtpSource::GetContentSecurityPolicyFrameSrc() const { 273 std::string LocalNtpSource::GetContentSecurityPolicyChildSrc() const {
274 // Allow embedding of most visited iframes. 274 // Allow embedding of most visited iframes.
275 return base::StringPrintf("frame-src %s;", 275 return base::StringPrintf("child-src %s;",
276 chrome::kChromeSearchMostVisitedUrl); 276 chrome::kChromeSearchMostVisitedUrl);
277 } 277 }
OLDNEW
« no previous file with comments | « chrome/browser/search/local_ntp_source.h ('k') | chrome/browser/ui/webui/chromeos/login/oobe_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698