Declarative Net Request: Support runtime host permissions.
This CL adds support for runtime host permissions to the Declarative Net Request API. Changes: - The behavior of REQUIRE_HOST_PERMISSION_FOR_URL_AND_INITIATOR is modified for the case when an extension has access to the initiator but the access to the request url is withheld. In this case, the extension is granted access to the request. This is similar to the current behavior of REQUIRE_HOST_PERMISSION_FOR_URL (used by web request API) and necessary for runtime host permissions to work. This allows extensions to intercept withheld cross-origin requests from a frame to which they have access. - RulesetManager is modified to notify the chrome layer that access to a request was withheld. This is necessary for us to track an extension's blocked/withheld actions on a tab. This CL also paves the way to transition the web request API to require host permissions to the initiator i.e. REQUIRE_HOST_PERMISSION_FOR_URL_AND_INITIATOR. BUG=157736, 809680 Change-Id: Ic4737a55a3ad6f88625149bcb39eefeb84df7d91 Reviewed-on: https://chromium-review.googlesource.com/c/1256219 Commit-Queue: Karan Bhatia <karandeepb@chromium.org> Reviewed-by:Karan Bhatia <karandeepb@chromium.org> Reviewed-by:
Devlin <rdevlin.cronin@chromium.org> Cr-Commit-Position: refs/heads/master@{#596450}
Showing
Please register or sign in to comment