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

Unified Diff: Source/core/frame/ContentSecurityPolicy.h

Issue 138033019: CSP 1.1: Apply hashes to style elements. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/dom/StyleElement.cpp ('k') | Source/core/frame/ContentSecurityPolicy.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/frame/ContentSecurityPolicy.h
diff --git a/Source/core/frame/ContentSecurityPolicy.h b/Source/core/frame/ContentSecurityPolicy.h
index 0720123a02d4852e905bf4e2fae5ce349990662c..7d11878dcc12ecee58ed84b82ec9f5f1c67e57fd 100644
--- a/Source/core/frame/ContentSecurityPolicy.h
+++ b/Source/core/frame/ContentSecurityPolicy.h
@@ -109,8 +109,10 @@ public:
bool allowScriptNonce(const String& nonce) const;
bool allowStyleNonce(const String& nonce) const;
bool allowScriptHash(const String& source) const;
+ bool allowStyleHash(const String& source) const;
void usesScriptHashAlgorithms(uint8_t HashAlgorithms);
+ void usesStyleHashAlgorithms(uint8_t HashAlgorithms);
ReflectedXSSDisposition reflectedXSSDisposition() const;
@@ -161,9 +163,10 @@ private:
HashSet<unsigned, AlreadyHashed> m_violationReportsSent;
// We put the hash functions used on the policy object so that we only need
- // to calculate a script hash once and then distribute it to all of the
- // directives for validation.
- uint8_t m_sourceHashAlgorithmsUsed;
+ // to calculate a hash once and then distribute it to all of the directives
+ // for validation.
+ uint8_t m_scriptHashAlgorithmsUsed;
+ uint8_t m_styleHashAlgorithmsUsed;
};
}
« no previous file with comments | « Source/core/dom/StyleElement.cpp ('k') | Source/core/frame/ContentSecurityPolicy.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698