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

Unified Diff: Source/core/frame/csp/CSPDirectiveList.cpp

Issue 704723003: Revert "Allow CSP checkNonce and checkHash to pass with 'unsafe-inline' only." (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 1 month 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 side-by-side diff with in-line comments
Download patch
Index: Source/core/frame/csp/CSPDirectiveList.cpp
diff --git a/Source/core/frame/csp/CSPDirectiveList.cpp b/Source/core/frame/csp/CSPDirectiveList.cpp
index d4997139ea2c241433834f1b00cd53e88ee29a24..6ff0e090f14ddd5949f55846a98e51f57e298fad 100644
--- a/Source/core/frame/csp/CSPDirectiveList.cpp
+++ b/Source/core/frame/csp/CSPDirectiveList.cpp
@@ -86,12 +86,12 @@ bool CSPDirectiveList::checkInline(SourceListDirective* directive) const
bool CSPDirectiveList::checkNonce(SourceListDirective* directive, const String& nonce) const
{
- return !directive || directive->allowNonce(nonce) || checkInline(directive);
+ return !directive || directive->allowNonce(nonce);
}
bool CSPDirectiveList::checkHash(SourceListDirective* directive, const CSPHashValue& hashValue) const
{
- return !directive || directive->allowHash(hashValue) || checkInline(directive);
+ return !directive || directive->allowHash(hashValue);
}
bool CSPDirectiveList::checkSource(SourceListDirective* directive, const KURL& url) const
« no previous file with comments | « LayoutTests/http/tests/security/contentSecurityPolicy/1.1/scriptnonce-multiple-policies-with-unsafe-inline-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698