commit | 29950ebbfdb4d438cf6ae63ddf44311cd186d41d | [log] [tgz] |
---|---|---|
author | Matt Falkenhagen <falken@chromium.org> | Thu Feb 28 23:07:13 2019 |
committer | Commit Bot <commit-bot@chromium.org> | Thu Feb 28 23:07:13 2019 |
tree | b40b36407be9542f1eeb1830bb75986360b2b623 | |
parent | cb0fbc707397ee938fddd764bcb365d6113ce4db [diff] |
Allow extensions to intercept service worker navigation preload requests. Heavily based on an original CL by Charles Vazac <cvazac@akamai.com> at https://chromium-review.googlesource.com/c/chromium/src/+/1396938 Service worker navigation preload[1] is a web platform feature that involves sending a request to network at the same time as starting up the service worker for a navigation. This network request was not visible to extensions. This CL: - Modifies the network service path for service worker navigation preload requests so that the embedder is aware of them. - In web_request_permissions.cc, if a request is not considered a browser side navigation, it becomes opaque to extensions. This CL makes it so that service worker navigation preload requests[1] are exempted from that. This CL deletes the unit test for navigation preload in ServiceWorkerNavigationLoaderTest. It was too much hassle getting that to work with a TestWebContents because the infrastructure for enabling NetworkService in content_unittests is not set up yet so unittest_test_suite.cc typically disables NetworkService (issue 901092). We have sufficient navigation preload test coverage in browser tests and web tests. [1] https://w3c.github.io/ServiceWorker/#navigationpreloadmanager Bug: 914062 Change-Id: I4c91521e55c1103a1a67d973e595094b78357c34 Reviewed-on: https://chromium-review.googlesource.com/c/1491168 Reviewed-by: Kinuko Yasuda <kinuko@chromium.org> Reviewed-by: Varun Khaneja <vakh@chromium.org> Reviewed-by: Karan Bhatia <karandeepb@chromium.org> Commit-Queue: Matt Falkenhagen <falken@chromium.org> Cr-Commit-Position: refs/heads/master@{#636598}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .