Disable origin isolation if OAC disabled via enterprise policy. [chromium/src : main]

0 views
Skip to first unread message

Liam Brady (Gerrit)

unread,
Jan 28, 2026, 8:32:50 PM (2 days ago) Jan 28
to Charlie Reis, Alex Moshchuk, Chromium LUCI CQ, chromium...@chromium.org, Enterprise Policy Reviews, ajwong...@chromium.org, alexmo...@chromium.org, chromium-a...@chromium.org, creis...@chromium.org, extension...@chromium.org, navigation...@chromium.org, pdf-r...@chromium.org
Attention needed from Alex Moshchuk and Charlie Reis

Liam Brady voted Commit-Queue+1

Commit-Queue+1
Open in Gerrit

Related details

Attention is currently required from:
  • Alex Moshchuk
  • Charlie Reis
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement is not satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Ibec69bf27e57a3368765f55928670315357be350
Gerrit-Change-Number: 7529840
Gerrit-PatchSet: 3
Gerrit-Owner: Liam Brady <lbr...@google.com>
Gerrit-Reviewer: Alex Moshchuk <ale...@chromium.org>
Gerrit-Reviewer: Charlie Reis <cr...@chromium.org>
Gerrit-Reviewer: Liam Brady <lbr...@google.com>
Gerrit-CC: Enterprise Policy Reviews <enterprise-p...@google.com>
Gerrit-Attention: Alex Moshchuk <ale...@chromium.org>
Gerrit-Attention: Charlie Reis <cr...@chromium.org>
Gerrit-Comment-Date: Thu, 29 Jan 2026 01:32:40 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
satisfied_requirement
unsatisfied_requirement
open
diffy

Liam Brady (Gerrit)

unread,
Jan 30, 2026, 5:10:12 PM (7 hours ago) Jan 30
to Charlie Reis, Alex Moshchuk, Chromium LUCI CQ, chromium...@chromium.org, Enterprise Policy Reviews, ajwong...@chromium.org, alexmo...@chromium.org, chromium-a...@chromium.org, creis...@chromium.org, extension...@chromium.org, navigation...@chromium.org, pdf-r...@chromium.org
Attention needed from Alex Moshchuk and Charlie Reis

Liam Brady added 1 comment

File content/browser/renderer_host/code_cache_host_impl.cc
Line 599, Patchset 5 (Latest): if (content::SiteIsolationPolicy::IsSitePerProcessOrStricter(nullptr)) {
Liam Brady . unresolved

I'm not 100% convinced this is the right thing to do here. Presumably we would also care about enterprise policy here, but if I try to grab an actual browser context to pass in, we hit DCHECKs because the wrong thread is trying to access a RPH ([example test failure](https://ci.chromium.org/ui/p/chromium/builders/try/mac-rel/b8691313081671647089/test-results?q=ExactID%3A%3A%2F%2F%5C%3Ablink_web_tests%21webtest%3A%3Avirtual%2Fnot-site-per-process%2Fhttp%2Ftests%2Fdom%23EventListener-incumbent-global-1.html+VHash%3Ae5ceb6ad8779f6ec&clean=))

Open in Gerrit

Related details

Attention is currently required from:
  • Alex Moshchuk
  • Charlie Reis
Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: Ibec69bf27e57a3368765f55928670315357be350
    Gerrit-Change-Number: 7529840
    Gerrit-PatchSet: 5
    Gerrit-Owner: Liam Brady <lbr...@google.com>
    Gerrit-Reviewer: Alex Moshchuk <ale...@chromium.org>
    Gerrit-Reviewer: Liam Brady <lbr...@google.com>
    Gerrit-CC: Charlie Reis <cr...@chromium.org>
    Gerrit-CC: Enterprise Policy Reviews <enterprise-p...@google.com>
    Gerrit-Attention: Alex Moshchuk <ale...@chromium.org>
    Gerrit-Attention: Charlie Reis <cr...@chromium.org>
    Gerrit-Comment-Date: Fri, 30 Jan 2026 22:10:03 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Alex Moshchuk (Gerrit)

    unread,
    Jan 30, 2026, 10:27:10 PM (2 hours ago) Jan 30
    to Liam Brady, Charlie Reis, Chromium LUCI CQ, chromium...@chromium.org, Enterprise Policy Reviews, ajwong...@chromium.org, alexmo...@chromium.org, chromium-a...@chromium.org, creis...@chromium.org, extension...@chromium.org, navigation...@chromium.org, pdf-r...@chromium.org
    Attention needed from Charlie Reis and Liam Brady

    Alex Moshchuk added 6 comments

    Patchset-level comments
    File-level comment, Patchset 5 (Latest):
    Alex Moshchuk . resolved

    Looks good!

    File content/browser/renderer_host/code_cache_host_impl.cc
    Line 599, Patchset 5 (Latest): if (content::SiteIsolationPolicy::IsSitePerProcessOrStricter(nullptr)) {
    Liam Brady . unresolved

    I'm not 100% convinced this is the right thing to do here. Presumably we would also care about enterprise policy here, but if I try to grab an actual browser context to pass in, we hit DCHECKs because the wrong thread is trying to access a RPH ([example test failure](https://ci.chromium.org/ui/p/chromium/builders/try/mac-rel/b8691313081671647089/test-results?q=ExactID%3A%3A%2F%2F%5C%3Ablink_web_tests%21webtest%3A%3Avirtual%2Fnot-site-per-process%2Fhttp%2Ftests%2Fdom%23EventListener-incumbent-global-1.html+VHash%3Ae5ceb6ad8779f6ec&clean=))

    Alex Moshchuk

    Yes, indeed this can be accessed on the IO thread... which is really unfortunate. But rereading the implementation of this function, there might be an easy fix - I left a separate comment about it.

    File content/browser/renderer_host/origin_agent_cluster_browsertest.cc
    Line 145, Patchset 5 (Latest): // will ensure that the correct MockContentBrowserClient is installed.
    Alex Moshchuk . unresolved

    nit: maybe something like "the test's actual navigation swaps to a fresh BrowsingInstance, and that the correct MockContentBrowserClient is installed before that BrowsingInstance is created and looks up OAC isolation policy."

    Line 167, Patchset 5 (Latest): // Attempt to script the popup page from its opener.
    Alex Moshchuk . unresolved

    I think it's the reverse, scripting the opener from its popup?

    Line 179, Patchset 5 (Latest): EvalJs(contents, "window.location.href").ExtractString();
    Alex Moshchuk . resolved

    Nice, this should be much more robust in ensuring that document.domain is actually working.

    File content/public/browser/site_isolation_policy.cc
    Line 116, Patchset 5 (Latest): AreOriginKeyedProcessesEnabledByDefault(browser_context);
    Alex Moshchuk . unresolved

    Hmm. I wonder if checking AreOriginKeyedProcessesEnabledByDefault is really needed here. Looking at its implementation, it will always [return false](https://source.chromium.org/chromium/chromium/src/+/main:content/public/browser/site_isolation_policy.cc;l=244;drc=72eb090be2c9a401d7f03a5b5f91c9e216e8bba3) if UseDedicatedProcessesForAllSites() is false, which makes sense - we don't want to use origin-keyed processes if site isolation is off. And since we also check this on line 114, we're basically guaranteed that this will always return false, because at this point UseDedicatedProcessesForAllSites() is false. So I wonder if this can just be removed? That would allow us to keep IsSitePerProcessOrStricter (and GetSiteIsolationDisabledReason) free from a BrowserContext dependency. (We can run this by Charlie as well, who's been involved in the other uses of IsSitePerProcessOrStricter() for metrics in browser_main_loop.)

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Charlie Reis
    • Liam Brady
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: Ibec69bf27e57a3368765f55928670315357be350
    Gerrit-Change-Number: 7529840
    Gerrit-PatchSet: 5
    Gerrit-Owner: Liam Brady <lbr...@google.com>
    Gerrit-Reviewer: Alex Moshchuk <ale...@chromium.org>
    Gerrit-Reviewer: Liam Brady <lbr...@google.com>
    Gerrit-CC: Charlie Reis <cr...@chromium.org>
    Gerrit-CC: Enterprise Policy Reviews <enterprise-p...@google.com>
    Gerrit-Attention: Liam Brady <lbr...@google.com>
    Gerrit-Attention: Charlie Reis <cr...@chromium.org>
    Gerrit-Comment-Date: Sat, 31 Jan 2026 03:26:58 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Liam Brady <lbr...@google.com>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy
    Reply all
    Reply to author
    Forward
    0 new messages