New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 781111 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner:
Buried. Ping if important.
Closed: Jan 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows , Chrome , Mac
Pri: 1
Type: Bug-Security


Show other hotlists

Hotlists containing this issue:
EnamelAndFriendsFixIt


Sign in to add a comment

CSP isn't applied to Service Workers correctly in Chrome.

Reported by codingma...@gmail.com, Nov 3 2017

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/62.0.3202.75 Safari/537.36

Steps to reproduce the problem:
I think this issue is strongly related to  issue 579801 .  Issue 579801  has been fixed in this revision https://chromium.googlesource.com/chromium/src.git/+/5289a5d4c98681e9a0f2d28da0c7aa35e282db57
However, it seems that this issue is reintroduced. I reproduce it in the latest chrome stable release. 

Download the attachments provided below and visit index.html. (Due to secure policy in chrome, ServiecWorker cannot be loaded in http:// and I don't have a https://, or you can visit the website provided by the submitter of  issue 579801 , https://blazing-fire-305.firebaseapp.com/)
There exists various tests with descriptions of the expected outcomes according to the CSP specification. 
> The HTTP Content-Security-Policy (CSP) worker-src directive specifies valid sources for Worker, SharedWorker, or ServiceWorker scripts. If this directive is absent, the user agent will look for the child-src directive (which falls back to the default-src directive).

Chrome failed the first test in which 'default-src' is set to none, and alse failed the second in which 'child-src' is set to a different origin. 
I am expecting  to see CSP errors in the console rather than 'offline worker registered'.

In the latest FireFox the CSP error is triggered when loading the first and the second test.

What is the expected behavior?

What went wrong?
CSP isn't applied to Service Workers correctly in Chrome.

Did this work before? Yes 

Chrome version: 62.0.3202.75  Channel: stable
OS Version: OS X 10.12.6
Flash Version:
 
test_htmls.zip
1.2 KB Download
Cc: est...@chromium.org
Components: Blink>ServiceWorker Blink>SecurityFeature

Comment 2 by vakh@chromium.org, Nov 3 2017

Labels: ReleaseBlock-Stable Security_Severity-Medium M-62

Comment 3 by vakh@chromium.org, Nov 4 2017

Labels: -ReleaseBlock-Stable Security_Impact-Stable
Project Member

Comment 4 by sheriffbot@chromium.org, Nov 4 2017

Labels: -Pri-2 Pri-1
Cc: falken@chromium.org mkwst@chromium.org
Labels: OS-Chrome OS-Linux OS-Windows
Owner: andypaicu@chromium.org
Status: Assigned (was: Unconfirmed)

Comment 6 by est...@chromium.org, Nov 10 2017

Labels: Hotlist-EnamelAndFriendsFixIt
Project Member

Comment 7 by sheriffbot@chromium.org, Nov 17 2017

andypaicu: Uh oh! This issue still open and hasn't been updated in the last 14 days. This is a serious vulnerability, and we want to ensure that there's progress. Could you please leave an update with the current status and any potential blockers?

If you're not the right owner for this issue, could you please remove yourself as soon as possible or help us find the right one?

If the issue is fixed or you can't reproduce it, please close the bug. If you've started working on a fix, please set the status to Started.

Thanks for your time! To disable nags, add the Disable-Nags label.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot

Comment 8 Deleted

Comment 9 Deleted

Cc: -mkwst@chromium.org andypaicu@chromium.org
Owner: mkwst@chromium.org
mkwst: I bisected on the demo site https://blazing-fire-305.firebaseapp.com/ using the "Basic policy with no frame or child src. - expected errors" test. And the result was:

$ python tools/bisect-builds.py -a linux64 -g 386251 -b 516552 -- --no-first-run https://blazing-fire-305.firebaseapp.com/
...
You are probably looking for a change made after 458025 (known good), but no later than 458026 (first known bad).
CHANGELOG URL:
  https://chromium.googlesource.com/chromium/src/+log/ba21ffd704aebcc8a5e5e1ab1f072e9b79b51fcb..d8cc69507968d87cea7eeefc39c0dae78f960879

The change is:
d8cc695 CSP: Move 'worker-src' onto 'script-src' by mkwst ยท 8 months ago

Which might mean this was an intentional change to the CSP API and this is WAI?


Labels: -M-62 M-59
FWIW that change was in 59.0.3047.0.
Yes. This is an intentional change to the CSP API. I referred to the latest published CSP draft(https://www.w3.org/TR/2016/WD-CSP3-20160913/), not the latest editor draft, which leads to this misunderstanding. Thanks for the clarification!
Project Member

Comment 13 by sheriffbot@chromium.org, Nov 21 2017

Labels: -M-59 M-62
mkwst: Do you agree we can close this? 
Sure.
Project Member

Comment 16 by sheriffbot@chromium.org, Dec 1 2017

mkwst: Uh oh! This issue still open and hasn't been updated in the last 28 days. This is a serious vulnerability, and we want to ensure that there's progress. Could you please leave an update with the current status and any potential blockers?

If you're not the right owner for this issue, could you please remove yourself as soon as possible or help us find the right one?

If the issue is fixed or you can't reproduce it, please close the bug. If you've started working on a fix, please set the status to Started.

Thanks for your time! To disable nags, add the Disable-Nags label.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Project Member

Comment 17 by sheriffbot@chromium.org, Dec 7 2017

Labels: -M-62 M-63
Project Member

Comment 18 by sheriffbot@chromium.org, Jan 25 2018

Labels: -M-63 M-64
Status: WontFix (was: Assigned)
Oops, this slipped by attention. Closing as WontFix per comments.
Project Member

Comment 20 by sheriffbot@chromium.org, May 4 2018

Labels: -Restrict-View-SecurityTeam allpublic
This bug has been closed for more than 14 weeks. Removing security view restrictions.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot

Sign in to add a comment