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

Issue 1177983007: Cache Storage: restrict access to secure origins (Blink-side) (Closed)

Created:
5 years, 6 months ago by jsbell
Modified:
5 years, 4 months ago
CC:
blink-reviews
Target Ref:
refs/heads/master
Project:
blink
Visibility:
Public.

Description

Cache Storage: restrict access to secure origins (Blink-side) Per spec discussions[1], the Cache Storage API (i.e. window.caches) should be restricted to secure origins. Reject access attempts with SecurityError if made from non-secure origins After this lands, https://codereview.chromium.org/1192003006/ will go in to enforce things on the browser side. [1] https://github.com/slightlyoff/ServiceWorker/issues/709 BUG=501380 R=falken@chromium.org,mkwst@chromium.org,asvitkine@chromium.org Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=200191

Patch Set 1 #

Total comments: 1

Patch Set 2 : Inspector should run permission checks too #

Patch Set 3 : Factor out common checks #

Total comments: 3

Patch Set 4 : Add static method exposing access check for CacheStorage #

Patch Set 5 : DevTools: Skip enumeration if access denied #

Total comments: 4

Patch Set 6 : Simplify DevTools agent changes #

Unified diffs Side-by-side diffs Delta from patch set Stats (+119 lines, -12 lines) Patch
A LayoutTests/http/tests/security/powerfulFeatureRestrictions/cachestorage-on-insecure-origin.html View 1 chunk +63 lines, -0 lines 0 comments Download
M Source/modules/cachestorage/CacheStorage.h View 1 2 4 5 1 chunk +4 lines, -4 lines 0 comments Download
M Source/modules/cachestorage/CacheStorage.cpp View 1 2 3 4 5 6 chunks +33 lines, -4 lines 0 comments Download
M Source/modules/cachestorage/CacheStorage.idl View 1 2 3 1 chunk +4 lines, -4 lines 0 comments Download
M Source/modules/cachestorage/InspectorCacheStorageAgent.cpp View 1 2 3 4 5 2 chunks +15 lines, -0 lines 0 comments Download

Messages

Total messages: 27 (7 generated)
jsbell
falken@, mkwst@ - please take a look? I just cribbed this from what Service Worker ...
5 years, 6 months ago (2015-06-18 19:06:59 UTC) #1
jsbell
This should land after the blink side CL: https://codereview.chromium.org/1181973004 please take a look? Note that ...
5 years, 6 months ago (2015-06-18 19:12:31 UTC) #3
jsbell
Whoops, sorry, this email was intended to be on the Chromium-side CL. Please disregard. On ...
5 years, 6 months ago (2015-06-18 19:13:48 UTC) #4
Mike West
LGTM % nit. https://codereview.chromium.org/1177983007/diff/1/Source/modules/cachestorage/CacheStorage.cpp File Source/modules/cachestorage/CacheStorage.cpp (right): https://codereview.chromium.org/1177983007/diff/1/Source/modules/cachestorage/CacheStorage.cpp#newcode292 Source/modules/cachestorage/CacheStorage.cpp:292: } Nit: It might be reasonable ...
5 years, 6 months ago (2015-06-18 19:54:57 UTC) #7
jsbell
Hrm, inspector apparently will need tweaking as well. It's getting killed by the chromium-side patch ...
5 years, 6 months ago (2015-06-18 21:31:37 UTC) #8
jsbell
On 2015/06/18 21:31:37, jsbell wrote: > Hrm, inspector apparently will need tweaking as well. It's ...
5 years, 6 months ago (2015-06-18 22:00:12 UTC) #9
jsbell
+palmer, for synchronizing Blink and Chromium-side checks https://codereview.chromium.org/1177983007/diff/10003/Source/modules/cachestorage/CacheStorage.cpp File Source/modules/cachestorage/CacheStorage.cpp (right): https://codereview.chromium.org/1177983007/diff/10003/Source/modules/cachestorage/CacheStorage.cpp#newcode36 Source/modules/cachestorage/CacheStorage.cpp:36: if (!executionContext->isPrivilegedContext(errorMessage)) ...
5 years, 6 months ago (2015-06-19 20:32:40 UTC) #11
palmer
LGTM. Thanks! https://codereview.chromium.org/1177983007/diff/10003/Source/modules/cachestorage/CacheStorage.cpp File Source/modules/cachestorage/CacheStorage.cpp (right): https://codereview.chromium.org/1177983007/diff/10003/Source/modules/cachestorage/CacheStorage.cpp#newcode36 Source/modules/cachestorage/CacheStorage.cpp:36: if (!executionContext->isPrivilegedContext(errorMessage)) { > Per notes in ...
5 years, 6 months ago (2015-06-26 21:13:17 UTC) #12
falken
code lgtm, spec discussion looks stalled though
5 years, 5 months ago (2015-06-29 03:27:18 UTC) #13
jsbell
pfeldman@ - PTAL at the inspector changes?
5 years, 4 months ago (2015-08-03 23:16:16 UTC) #15
pfeldman
https://codereview.chromium.org/1177983007/diff/90001/Source/modules/cachestorage/InspectorCacheStorageAgent.cpp File Source/modules/cachestorage/InspectorCacheStorageAgent.cpp (right): https://codereview.chromium.org/1177983007/diff/90001/Source/modules/cachestorage/InspectorCacheStorageAgent.cpp#newcode403 Source/modules/cachestorage/InspectorCacheStorageAgent.cpp:403: if (!CacheStorage::canAccessCacheStorage(executionContext)) { Inspector should have access to everything, ...
5 years, 4 months ago (2015-08-03 23:53:49 UTC) #16
jsbell
https://codereview.chromium.org/1177983007/diff/90001/Source/modules/cachestorage/InspectorCacheStorageAgent.cpp File Source/modules/cachestorage/InspectorCacheStorageAgent.cpp (right): https://codereview.chromium.org/1177983007/diff/90001/Source/modules/cachestorage/InspectorCacheStorageAgent.cpp#newcode403 Source/modules/cachestorage/InspectorCacheStorageAgent.cpp:403: if (!CacheStorage::canAccessCacheStorage(executionContext)) { On 2015/08/03 23:53:49, pfeldman wrote: > ...
5 years, 4 months ago (2015-08-04 00:14:53 UTC) #17
palmer
> > what is happening here that we need to go via the blink core ...
5 years, 4 months ago (2015-08-04 00:41:00 UTC) #18
jsbell
On 2015/08/04 00:41:00, palmer wrote: > Walking the document means checking if the document is ...
5 years, 4 months ago (2015-08-04 15:24:38 UTC) #19
palmer
> So far as I understand, it's checking to see that it's not (nor is ...
5 years, 4 months ago (2015-08-05 17:55:55 UTC) #20
jsbell
Apologies for the confusion; I should know better than to solicit feedback w/o the code. ...
5 years, 4 months ago (2015-08-07 18:08:12 UTC) #21
pfeldman
devtools lgtm, thanks!
5 years, 4 months ago (2015-08-07 18:53:49 UTC) #22
palmer
LGTM.
5 years, 4 months ago (2015-08-07 19:01:59 UTC) #23
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1177983007/110001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1177983007/110001
5 years, 4 months ago (2015-08-07 20:07:02 UTC) #26
commit-bot: I haz the power
5 years, 4 months ago (2015-08-07 20:10:19 UTC) #27
Message was sent while issue was closed.
Committed patchset #6 (id:110001) as
https://src.chromium.org/viewvc/blink?view=rev&revision=200191

Powered by Google App Engine
This is Rietveld 408576698