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

Issue 559503002: CSP: Move policy parsing out of Document. (Closed)

Created:
6 years, 3 months ago by Mike West
Modified:
6 years, 3 months ago
CC:
blink-reviews, arv+blink, eae+blinkwatch, abarth-chromium, blink-reviews-dom_chromium.org, dglazkov+blink, blink-reviews-bindings_chromium.org, rwlbuis
Project:
blink
Visibility:
Public.

Description

CSP: Move policy parsing out of Document. This patch finishes the process of allowing policy parsing outside of an ExecutionContext, and adjusts Document::initContentSecurityPolicy to accept a ContentSecurityPolicy object rather than a set of headers. If such an object is provided, the document will take ownership of it and use it going forward. If no such object is provided, an empty policy will be created and stored. A future patch will move parsing out of FrameLoader::didBeginDocument into DocumentLoader::responseReceived so that we can begin doing some checks before a document is created. BUG=411889 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=181811

Patch Set 1 #

Patch Set 2 : Moar. #

Patch Set 3 : Rebase. #

Total comments: 6

Patch Set 4 : Reworking. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+51 lines, -43 lines) Patch
M Source/core/dom/Document.h View 1 2 3 2 chunks +1 line, -2 lines 0 comments Download
M Source/core/dom/Document.cpp View 1 2 3 4 chunks +16 lines, -11 lines 0 comments Download
M Source/core/frame/csp/ContentSecurityPolicy.h View 1 2 3 2 chunks +5 lines, -11 lines 0 comments Download
M Source/core/frame/csp/ContentSecurityPolicy.cpp View 1 2 3 5 chunks +18 lines, -15 lines 0 comments Download
M Source/core/loader/FrameLoader.cpp View 1 1 chunk +5 lines, -1 line 0 comments Download
M Source/core/workers/WorkerGlobalScope.cpp View 1 2 3 1 chunk +5 lines, -2 lines 0 comments Download
M Source/core/xml/XSLTProcessor.cpp View 1 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 11 (3 generated)
Mike West
Jochen, would you mind taking a look at this? Sigbjorn, FYI: this is decouples CSP ...
6 years, 3 months ago (2014-09-10 08:33:33 UTC) #2
sof
Sorry about the delay. The re-casting looks fine, but got one clarifying question regarding Document::initSecurityContext(). ...
6 years, 3 months ago (2014-09-11 07:44:04 UTC) #4
Mike West
Thanks for taking a look. https://codereview.chromium.org/559503002/diff/40001/Source/core/dom/Document.cpp File Source/core/dom/Document.cpp (right): https://codereview.chromium.org/559503002/diff/40001/Source/core/dom/Document.cpp#newcode4819 Source/core/dom/Document.cpp:4819: // Otherwise, the CSP ...
6 years, 3 months ago (2014-09-11 08:29:13 UTC) #5
Mike West
Took another pass. I don't like calling `initContentSecurityPolicy` there when I'm pretty sure it's going ...
6 years, 3 months ago (2014-09-11 08:38:03 UTC) #6
sof
On 2014/09/11 08:38:03, Mike West wrote: > Took another pass. I don't like calling `initContentSecurityPolicy` ...
6 years, 3 months ago (2014-09-11 08:45:59 UTC) #7
Mike West
On 2014/09/11 08:45:59, sof wrote: > On 2014/09/11 08:38:03, Mike West wrote: > > Took ...
6 years, 3 months ago (2014-09-11 08:56:03 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patchset/559503002/60001
6 years, 3 months ago (2014-09-11 08:57:18 UTC) #10
commit-bot: I haz the power
6 years, 3 months ago (2014-09-11 10:42:35 UTC) #11
Message was sent while issue was closed.
Committed patchset #4 (id:60001) as 181811

Powered by Google App Engine
This is Rietveld 408576698