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

Issue 2891123002: [Extensions Bindings] Handle updating context permissions (Closed)

Created:
3 years, 7 months ago by Devlin
Modified:
3 years, 7 months ago
Reviewers:
lazyboy, jbroman
CC:
chromium-apps-reviews_chromium.org, chromium-reviews, extensions-reviews_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

[Extensions Bindings] Handle updating context permissions Extensions can update permissions during a context's lifetime (by requesting or removing optional permissions). In this case, we need to update the bindings for that context. This includes two pieces: - Ensuring APIs from new permissions are present - Ensuring APIs that require removed permissions no longer work Note that we don't actually *remove* APIs that required old permissions; we just disable them. This is partially for simplicity and partially because removing the API from the chrome object wouldn't really matter, since scripts could cache the API object somewhere. BUG=653596 Review-Url: https://codereview.chromium.org/2891123002 Cr-Commit-Position: refs/heads/master@{#474523} Committed: https://chromium.googlesource.com/chromium/src/+/8cdd4836d0df2ae8bcb68ca3dbe17f310c02fe98

Patch Set 1 #

Patch Set 2 : comments #

Patch Set 3 : Add TODO #

Total comments: 2

Patch Set 4 : jbroman's #

Unified diffs Side-by-side diffs Delta from patch set Stats (+194 lines, -99 lines) Patch
M extensions/renderer/api_binding.h View 1 4 chunks +9 lines, -6 lines 0 comments Download
M extensions/renderer/api_binding.cc View 1 2 3 6 chunks +14 lines, -6 lines 0 comments Download
M extensions/renderer/api_binding_unittest.cc View 28 chunks +43 lines, -57 lines 0 comments Download
M extensions/renderer/api_bindings_system.h View 3 chunks +3 lines, -1 line 0 comments Download
M extensions/renderer/api_bindings_system.cc View 3 chunks +5 lines, -4 lines 0 comments Download
M extensions/renderer/api_bindings_system_unittest.cc View 7 chunks +14 lines, -13 lines 0 comments Download
M extensions/renderer/declarative_event_unittest.cc View 2 chunks +1 line, -5 lines 0 comments Download
M extensions/renderer/native_extension_bindings_system.cc View 1 2 3 3 chunks +11 lines, -7 lines 0 comments Download
M extensions/renderer/native_extension_bindings_system_unittest.cc View 1 2 3 1 chunk +94 lines, -0 lines 0 comments Download

Messages

Total messages: 23 (17 generated)
Devlin
Hey folks, mind taking a look?
3 years, 7 months ago (2017-05-18 18:36:15 UTC) #8
jbroman
lgtm https://codereview.chromium.org/2891123002/diff/40001/extensions/renderer/api_binding.cc File extensions/renderer/api_binding.cc (right): https://codereview.chromium.org/2891123002/diff/40001/extensions/renderer/api_binding.cc#newcode517 extensions/renderer/api_binding.cc:517: isolate->ThrowException(v8::Exception::Error(gin::StringToSymbol( super-nit: maybe StringToV8? (this doesn't seem like ...
3 years, 7 months ago (2017-05-24 18:09:47 UTC) #12
Devlin
https://codereview.chromium.org/2891123002/diff/40001/extensions/renderer/api_binding.cc File extensions/renderer/api_binding.cc (right): https://codereview.chromium.org/2891123002/diff/40001/extensions/renderer/api_binding.cc#newcode517 extensions/renderer/api_binding.cc:517: isolate->ThrowException(v8::Exception::Error(gin::StringToSymbol( On 2017/05/24 18:09:47, jbroman wrote: > super-nit: maybe ...
3 years, 7 months ago (2017-05-24 19:10:08 UTC) #13
lazyboy
lgtm
3 years, 7 months ago (2017-05-24 22:43:00 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2891123002/60001
3 years, 7 months ago (2017-05-25 01:37:07 UTC) #20
commit-bot: I haz the power
3 years, 7 months ago (2017-05-25 02:06:21 UTC) #23
Message was sent while issue was closed.
Committed patchset #4 (id:60001) as
https://chromium.googlesource.com/chromium/src/+/8cdd4836d0df2ae8bcb68ca3dbe1...

Powered by Google App Engine
This is Rietveld 408576698