WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
153157
CSP: Use the served CSP header for dedicated workers
https://bugs.webkit.org/show_bug.cgi?id=153157
Summary
CSP: Use the served CSP header for dedicated workers
Daniel Bates
Reported
2016-01-15 15:07:34 PST
We should merge <
https://src.chromium.org/viewvc/blink?view=rev&revision=194094
> and <
https://src.chromium.org/viewvc/blink?view=rev&revision=194143
> (in order). Use the served CSP header for dedicated workers This CL makes workers obey the CSP that was served as a header along with the worker script, instead of inheriting the CSP from the document that spawned the worker. (Blob and file URLs still inherit the CSP from the parent document.)
Attachments
Patch and Layout Test
(60.27 KB, patch)
2016-01-28 09:03 PST
,
Daniel Bates
no flags
Details
Formatted Diff
Diff
Patch and Layout Test
(63.19 KB, patch)
2016-01-28 09:37 PST
,
Daniel Bates
no flags
Details
Formatted Diff
Diff
Patch and Layout Tests
(69.90 KB, patch)
2016-01-28 10:54 PST
,
Daniel Bates
bfulgham
: review+
Details
Formatted Diff
Diff
Show Obsolete
(2)
View All
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2016-01-27 20:44:32 PST
<
rdar://problem/24383254
>
Daniel Bates
Comment 2
2016-01-28 09:03:56 PST
Created
attachment 270118
[details]
Patch and Layout Test
WebKit Commit Bot
Comment 3
2016-01-28 09:05:58 PST
Attachment 270118
[details]
did not pass style-queue: ERROR: Source/WebCore/workers/DedicatedWorkerThread.h:37: Code inside a namespace should not be indented. [whitespace/indent] [4] ERROR: Source/WebCore/workers/WorkerGlobalScopeProxy.h:41: Code inside a namespace should not be indented. [whitespace/indent] [4] ERROR: Source/WebCore/workers/WorkerMessagingProxy.h:43: Code inside a namespace should not be indented. [whitespace/indent] [4] ERROR: Source/WebCore/workers/DedicatedWorkerGlobalScope.h:39: Code inside a namespace should not be indented. [whitespace/indent] [4] ERROR: Source/WebCore/workers/WorkerThread.h:38: Code inside a namespace should not be indented. [whitespace/indent] [4] Total errors found: 5 in 26 files If any of these errors are false positives, please file a bug against check-webkit-style.
Daniel Bates
Comment 4
2016-01-28 09:37:58 PST
Created
attachment 270120
[details]
Patch and Layout Test Add files ContentSecurityPolicyResponseHeaders.{cpp, h} to the CMake build system and Visual Studio project file
WebKit Commit Bot
Comment 5
2016-01-28 09:46:37 PST
Attachment 270120
[details]
did not pass style-queue: ERROR: Source/WebCore/workers/DedicatedWorkerThread.h:37: Code inside a namespace should not be indented. [whitespace/indent] [4] ERROR: Source/WebCore/workers/WorkerGlobalScopeProxy.h:41: Code inside a namespace should not be indented. [whitespace/indent] [4] ERROR: Source/WebCore/workers/WorkerMessagingProxy.h:43: Code inside a namespace should not be indented. [whitespace/indent] [4] ERROR: Source/WebCore/workers/DedicatedWorkerGlobalScope.h:39: Code inside a namespace should not be indented. [whitespace/indent] [4] ERROR: Source/WebCore/workers/WorkerThread.h:38: Code inside a namespace should not be indented. [whitespace/indent] [4] Total errors found: 5 in 29 files If any of these errors are false positives, please file a bug against check-webkit-style.
Daniel Bates
Comment 6
2016-01-28 10:54:35 PST
Created
attachment 270127
[details]
Patch and Layout Tests Updated patch to inherit CSP from owner document of worker when script URL of worker is a file URL as per
comment #0
. Added tests LayoutTests/fast/workers/worker-inherits-csp-blocks-{eval, xhr}.html to ensure we do not regress this behavior.
WebKit Commit Bot
Comment 7
2016-01-28 10:57:26 PST
Attachment 270127
[details]
did not pass style-queue: ERROR: Source/WebCore/workers/DedicatedWorkerThread.h:37: Code inside a namespace should not be indented. [whitespace/indent] [4] ERROR: Source/WebCore/workers/WorkerGlobalScopeProxy.h:41: Code inside a namespace should not be indented. [whitespace/indent] [4] ERROR: Source/WebCore/workers/WorkerMessagingProxy.h:43: Code inside a namespace should not be indented. [whitespace/indent] [4] ERROR: Source/WebCore/workers/DedicatedWorkerGlobalScope.h:39: Code inside a namespace should not be indented. [whitespace/indent] [4] ERROR: Source/WebCore/workers/WorkerThread.h:38: Code inside a namespace should not be indented. [whitespace/indent] [4] Total errors found: 5 in 35 files If any of these errors are false positives, please file a bug against check-webkit-style.
Brent Fulgham
Comment 8
2016-01-28 18:51:58 PST
Comment on
attachment 270127
[details]
Patch and Layout Tests View in context:
https://bugs.webkit.org/attachment.cgi?id=270127&action=review
r=me. I don't know why the patch will not apply on the WK2 bot, but presumably its a machine-specific issue. Please watch test results carefully after landing.
> Source/WebCore/ChangeLog:58 > + (WebCore::ContentSecurityPolicyResponseHeaders::isolatedCopy): Make an copy of this object that is
Make *a* copy! :-)
Daniel Bates
Comment 9
2016-01-31 19:10:06 PST
Committed
r195948
: <
http://trac.webkit.org/changeset/195948
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug