| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
| |
Add a few more histograms to determine how our renderer state objects are doing
in terms of cache misses and hits. This will be useful in figuring out if we
can get rid of ExtensionRendererState (and with it, its use of RenderView).
BUG=455776
Review URL: https://codereview.chromium.org/1762493002
Cr-Commit-Position: refs/heads/master@{#379657}
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch adds out of line copy constructors for classes that our
clang-plugin considers heavy. This is an effort to enable copy
constructor checks by default.
BUG=436357
R=reillyg@chromium.org, dcheng@chromium.org, thakis@chromium.org
Review URL: https://codereview.chromium.org/1724293002
Cr-Commit-Position: refs/heads/master@{#378054}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
With click-to-script turned on, webRequest needs to respect tab-specific
permissions so that when the user grants access to a tab, the extension can
operate on it. In order to do this, we also need access to the tab id on the
IO thread.
Add the tab id to the ExtensionApiFrameIdMap, and check for it in the webRequest
api. For now, don't do anything if the frame isn't cached - that'll come later.
This also doesn't hook webRequest into requesting permissions - that's next.
BUG=460306
Review URL: https://codereview.chromium.org/1687913002
Cr-Commit-Position: refs/heads/master@{#375036}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The webNavigation extension API does not work properly with out-of-process
iframes and will be broken with the upcoming changes in navigation
code (PlzNavigate). This CL is aiming to refactor the implementation to
use the NavigationHandle API, which is compatible with PlzNavigate and
helps hide some of the nasty details of cross-process navigations.
This CL depends on new APIs added to NavigationHandle in https://codereview.chromium.org/1667163002/.
BUG=584493
CQ_INCLUDE_TRYBOTS=tryserver.chromium.linux:linux_site_isolation
Review URL: https://codereview.chromium.org/1670673003
Cr-Commit-Position: refs/heads/master@{#374505}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Re-implemented https://codereview.chromium.org/952473002/, with all
checks at the browser side instead of just the renderer.
- Use the last committed URL for checking permissions instead of the
visible URL. As a result, executeScript/insertCSS will now succeed in
frames where the currently committed page is scriptable by extensions,
but the target of the pending navigation is is not.
- ExecuteScript: Do not send IPC to non-live frames (they're not going
to reply anyway).
- Include URL in the error if the extension has the tabs permission
(follow-up to TODO from https://codereview.chromium.org/1414223005).
BUG=63979,551626
TEST=./browser_tests --gtest_filter=ExecuteScriptApiTest.*
CQ_INCLUDE_TRYBOTS=tryserver.chromium.linux:linux_site_isolation
Review URL: https://codereview.chromium.org/1628423002
Cr-Commit-Position: refs/heads/master@{#374057}
|
|
Use FrameTreeNode IDs instead of RenderFrame routing IDs as "frame id"
in the extension APIs (webNavigation, webRequest, extension messaging)
because FTN IDs are globally unique, and RFH IDs are not.
This extends the public content API with:
- RenderFrameHost::FromFrameTreeNodeId
- RenderFrameHost::GetFrameTreeNodeId
- WebContents::FindFrameByFrameTreeNodeId
The extension APIs are modified as follows:
- webRequest:
* Frame IDs may be unavailable after frame removal (crbug.com/572930).
* Blocking webRequest handlers may be slower than before due to an
extra IO->UI->IO hop to determine the frameId (but this happens only
once per frame load).
- webNavigation:
* processId is no longer required in chrome.webNavigation.getFrame,
but marked as optional (deprecated) to make sure that the API is
backwards-compatible.
* frameId is constant across navigations.
- Extension messaging (chrome.runtime.connect and friends):
* Small change for extension developers in the following scenario:
1. Open port to tab.
2. Accept the port by listening to onConnect *in a child frame*.
3. Unload the document in the frame.
Old behavior: onDisconnect was not triggered in the background until
the tab was reloaded or closed.
New behavior: onDisconnect is called.
* Extension messaging works correctly in out-of-process frames.
* Move port lifetime management from renderer to browser.
* Tie port lifetime to frames instead of processes.
* Only notify frames in renderers if they have accepted the port.
* Remove obsolete work-around for crbug.com/520303.
* Unify open/close/postMessage logic in ChromeExtensionMessageFilter
(crbug.com/394383#c7)
- The extension frameId logic is no longer scattered over several files,
but resides in a single class (ExtensionApiFrameIdMap).
- IDs are now guaranteed to be -1 or higher (before this, -2 was
occasionally seen).
Depends on https://codereview.chromium.org/1413853005/
BUG=432875
TEST=browser_tests --gtest_filter=\
ExtensionWebRequestApiTest.*:\
WebNavigationApiTest.*:\
ExtensionApiTest.Messaging*:\
ExternallyConnectableMessagingTest.*:\
ExternallyConnectableMessagingWithTlsChannelIdTest.*
Review URL: https://codereview.chromium.org/1413543005
Cr-Commit-Position: refs/heads/master@{#367914}
|