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

Issue 1166003004: SRI fail open on ineligible resources. (Closed)

Created:
5 years, 6 months ago by jww
Modified:
5 years, 6 months ago
Reviewers:
Mike West
CC:
blink-reviews
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Target Ref:
refs/heads/master
Project:
blink
Visibility:
Public.

Description

SRI fail open on ineligible resources. Previously, SRI failed closed if a resource was ineligible (i.e. if it's a cross-origin request and was not a CORS request). However, for forwards compatibility, the spec now states that ineligible resources should fail open, with a developer console warning (https://github.com/w3c/webappsec/pull/394). This is okay from a security perspective because if the reverse case happens (a CORS request is made, but the server responds without or with unusable CORS headers), SRI still fails closed because Fetch() will not let it reach the integrity check. This is important because an attacker could modify or drop the CORS headers on the server if they have control, which is the attack vector SRI is protecting against. BUG=355467 R=mkwst@chromium.org Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=196703

Patch Set 1 #

Total comments: 2

Patch Set 2 : Remove a bunch of -expected.txt files #

Unified diffs Side-by-side diffs Delta from patch set Stats (+106 lines, -77 lines) Patch
A LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-hash-function-priority-console-messages.html View 1 1 chunk +16 lines, -0 lines 0 comments Download
A + LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-hash-function-priority-console-messages-expected.txt View 1 1 chunk +0 lines, -3 lines 0 comments Download
D LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-hash-function-priority-expected.txt View 1 1 chunk +0 lines, -5 lines 0 comments Download
M LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-invalid-integrity.html View 1 chunk +19 lines, -8 lines 0 comments Download
A LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-invalid-integrity-console-messages.html View 1 1 chunk +28 lines, -0 lines 0 comments Download
A LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-invalid-integrity-console-messages-expected.txt View 1 1 chunk +7 lines, -0 lines 0 comments Download
M LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-invalid-integrity-expected.txt View 1 1 chunk +0 lines, -4 lines 0 comments Download
D LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-script-cors-bad-integrity-expected.txt View 1 1 chunk +0 lines, -5 lines 0 comments Download
M LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-script-cors-no-xorigin.html View 1 chunk +2 lines, -2 lines 0 comments Download
A LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-script-cors-no-xorigin-console-messages.html View 1 1 chunk +12 lines, -0 lines 0 comments Download
A LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-script-cors-no-xorigin-console-messages-expected.txt View 1 1 chunk +2 lines, -0 lines 0 comments Download
M LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-script-cors-no-xorigin-expected.txt View 1 1 chunk +0 lines, -5 lines 0 comments Download
D LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-script-no-cors-expected.txt View 1 1 chunk +0 lines, -5 lines 0 comments Download
M LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-script-no-cors-no-xorigin.html View 1 chunk +2 lines, -2 lines 0 comments Download
M LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-script-no-cors-no-xorigin-expected.txt View 1 1 chunk +0 lines, -5 lines 0 comments Download
M LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-script-no-cors-no-xorigin-with-creds.html View 1 chunk +2 lines, -2 lines 0 comments Download
M LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-script-no-cors-no-xorigin-with-creds-expected.txt View 1 1 chunk +0 lines, -5 lines 0 comments Download
M LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-style-cors-no-xorigin.html View 2 chunks +2 lines, -6 lines 0 comments Download
M LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-style-no-cors-no-xorigin.html View 2 chunks +2 lines, -6 lines 0 comments Download
M LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-style-no-cors-no-xorigin-with-creds.html View 2 chunks +2 lines, -6 lines 0 comments Download
M LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-unknown-hash-allowed-expected.txt View 1 chunk +1 line, -0 lines 0 comments Download
M Source/core/frame/SubresourceIntegrity.cpp View 1 chunk +5 lines, -3 lines 0 comments Download
M Source/core/frame/SubresourceIntegrityTest.cpp View 1 chunk +4 lines, -5 lines 0 comments Download

Messages

Total messages: 9 (2 generated)
jww
5 years, 6 months ago (2015-06-06 16:51:46 UTC) #1
Mike West
LGTM, though I find the decision a bit strange. https://codereview.chromium.org/1166003004/diff/1/LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-invalid-integrity-expected.txt File LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-invalid-integrity-expected.txt (right): https://codereview.chromium.org/1166003004/diff/1/LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-invalid-integrity-expected.txt#newcode1 LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-invalid-integrity-expected.txt:1: ...
5 years, 6 months ago (2015-06-07 14:09:15 UTC) #2
jww
Hi Mike. Can you clarify why you find the decision strange? I'll try to clarify ...
5 years, 6 months ago (2015-06-07 17:20:49 UTC) #3
Mike West
On 2015/06/07 at 17:20:49, jww wrote: > From my perspective, the only reason to ever ...
5 years, 6 months ago (2015-06-08 08:30:53 UTC) #4
jww
On 2015/06/08 08:30:53, Mike West wrote: > On 2015/06/07 at 17:20:49, jww wrote: > > ...
5 years, 6 months ago (2015-06-08 19:09:19 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1166003004/20001
5 years, 6 months ago (2015-06-08 22:05:56 UTC) #8
commit-bot: I haz the power
5 years, 6 months ago (2015-06-08 23:05:03 UTC) #9
Message was sent while issue was closed.
Committed patchset #2 (id:20001) as
https://src.chromium.org/viewvc/blink?view=rev&revision=196703

Powered by Google App Engine
This is Rietveld 408576698