Prevent use of fallback DoH provider when ESB disabled [chromium/src : main]

0 views
Skip to first unread message

Andrew Williams (Gerrit)

unread,
Mar 29, 2026, 2:49:59 PM (6 days ago) Mar 29
to Kenichi Ishibashi, Javier Castro, Chromium IPC Reviews, Takashi Toyoshima, Brian Begnoche, Chromium LUCI CQ, Chromium Metrics Reviews, AyeAye, asvitkine...@chromium.org, network-ser...@chromium.org, net-r...@chromium.org, fenced-fra...@chromium.org
Attention needed from Chromium IPC Reviews, Javier Castro, Kenichi Ishibashi and Takashi Toyoshima

Andrew Williams added 1 comment

Patchset-level comments
File-level comment, Patchset 7 (Latest):
Andrew Williams . resolved

Kenichi, can you take a look at this overall?

Javier, can you take a look at the ESB pref tracking logic in ProfileNetworkContextService to confirm this will sufficiently track the state of whether a given profile has ESB enabled?

Takashi, PTAL for owners approval of tools/metrics/histograms/metadata/net/enums.xml

Thanks everyone!

Open in Gerrit

Related details

Attention is currently required from:
  • Chromium IPC Reviews
  • Javier Castro
  • Kenichi Ishibashi
  • Takashi Toyoshima
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: Ic68f11ac41737355a665a98f217009a6cff66d7e
Gerrit-Change-Number: 7704042
Gerrit-PatchSet: 7
Gerrit-Owner: Andrew Williams <awi...@chromium.org>
Gerrit-Reviewer: Andrew Williams <awi...@chromium.org>
Gerrit-Reviewer: Chromium IPC Reviews <chrome-ip...@google.com>
Gerrit-Reviewer: Javier Castro <jaca...@chromium.org>
Gerrit-Reviewer: Kenichi Ishibashi <ba...@chromium.org>
Gerrit-Reviewer: Takashi Toyoshima <toyo...@chromium.org>
Gerrit-CC: Brian Begnoche <b...@chromium.org>
Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
Gerrit-Attention: Javier Castro <jaca...@chromium.org>
Gerrit-Attention: Takashi Toyoshima <toyo...@chromium.org>
Gerrit-Attention: Kenichi Ishibashi <ba...@chromium.org>
Gerrit-Attention: Chromium IPC Reviews <chrome-ip...@google.com>
Gerrit-Comment-Date: Sun, 29 Mar 2026 18:49:54 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
satisfied_requirement
unsatisfied_requirement
open
diffy

gwsq (Gerrit)

unread,
Mar 29, 2026, 2:57:27 PM (6 days ago) Mar 29
to Andrew Williams, Chromium IPC Reviews, Dominic Farolino, Kenichi Ishibashi, Javier Castro, Takashi Toyoshima, Brian Begnoche, Chromium LUCI CQ, Chromium Metrics Reviews, AyeAye, asvitkine...@chromium.org, network-ser...@chromium.org, net-r...@chromium.org, fenced-fra...@chromium.org
Attention needed from Dominic Farolino, Javier Castro, Kenichi Ishibashi and Takashi Toyoshima

Message from gwsq

From googleclient/chrome/chromium_gwsq/ipc/config.gwsq:
IPC: d...@chromium.org, toyo...@chromium.org

📎 It looks like you’re making a possibly security-sensitive change! 📎 IPC security review isn’t a rubberstamp, so your friendly security reviewer will need a fair amount of context to review your CL effectively. Please review your CL description and code comments to make sure they provide context for someone unfamiliar with your project/area. Pay special attention to where data comes from and which processes it flows between (and their privilege levels). Feel free to point your security reviewer at design docs, bugs, or other links if you can’t reasonably make a self-contained CL description. (Also see https://cbea.ms/git-commit/).

IPC reviewer(s): d...@chromium.org, toyo...@chromium.org


Reviewer source(s):
d...@chromium.org is from context(googleclient/chrome/chromium_gwsq/ipc/config.gwsq)

Open in Gerrit

Related details

Attention is currently required from:
  • Dominic Farolino
  • Javier Castro
  • Kenichi Ishibashi
  • Takashi Toyoshima
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: Ic68f11ac41737355a665a98f217009a6cff66d7e
Gerrit-Change-Number: 7704042
Gerrit-PatchSet: 7
Gerrit-Owner: Andrew Williams <awi...@chromium.org>
Gerrit-Reviewer: Andrew Williams <awi...@chromium.org>
Gerrit-Reviewer: Dominic Farolino <d...@chromium.org>
Gerrit-Reviewer: Javier Castro <jaca...@chromium.org>
Gerrit-Reviewer: Kenichi Ishibashi <ba...@chromium.org>
Gerrit-Reviewer: Takashi Toyoshima <toyo...@chromium.org>
Gerrit-CC: Brian Begnoche <b...@chromium.org>
Gerrit-CC: Chromium IPC Reviews <chrome-ip...@google.com>
Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
Gerrit-CC: gwsq
Gerrit-Attention: Javier Castro <jaca...@chromium.org>
Gerrit-Attention: Takashi Toyoshima <toyo...@chromium.org>
Gerrit-Attention: Dominic Farolino <d...@chromium.org>
Gerrit-Attention: Kenichi Ishibashi <ba...@chromium.org>
Gerrit-Comment-Date: Sun, 29 Mar 2026 18:56:40 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
satisfied_requirement
unsatisfied_requirement
open
diffy

Kenichi Ishibashi (Gerrit)

unread,
Mar 29, 2026, 9:34:11 PM (6 days ago) Mar 29
to Andrew Williams, Chromium IPC Reviews, Dominic Farolino, Javier Castro, Takashi Toyoshima, Brian Begnoche, Chromium LUCI CQ, Chromium Metrics Reviews, AyeAye, asvitkine...@chromium.org, network-ser...@chromium.org, net-r...@chromium.org, fenced-fra...@chromium.org
Attention needed from Andrew Williams, Dominic Farolino, Javier Castro and Takashi Toyoshima

Kenichi Ishibashi added 8 comments

Patchset-level comments
Kenichi Ishibashi . resolved

Thank you for working on this, mostly bikeshedding.

File chrome/browser/net/profile_network_context_service.h
Line 176, Patchset 7 (Latest): void UpdateDohFallbackAllowedForContext();
Kenichi Ishibashi . unresolved

What does this "ForContext" mean? Simply name UpdateDohFallbackAllowed()?

Line 176, Patchset 7 (Latest): void UpdateDohFallbackAllowedForContext();
Kenichi Ishibashi . unresolved

As I wrote in the other comment, the term "fallback" is confusing. We use "fallback" to refer to both the DoH provider fallback and the act of falling back to insecure (in the DNS stack).

Can we figure out somewhat less confusing terms?

File net/dns/context_host_resolver.h
Line 91, Patchset 7 (Latest): void SetDohFallbackAllowedForContext(bool allowed) override;
Kenichi Ishibashi . unresolved

Ditto. Since ContextHostResolver is already per context, "ForContext" might be redundant.

File net/dns/dns_client.cc
Line 239, Patchset 7 (Latest): if (context->IsDohFallbackConfigPresent() &&
Kenichi Ishibashi . unresolved

The term 'fallback' is indeed overloaded here (referring to both the DoH provider type and the act of failing back to insecure). This logic correctly prioritizes the ESB-based restriction.

File net/dns/resolve_context.h
Line 260, Patchset 7 (Latest): void set_doh_fallback_allowed_for_context(bool allowed) {
Kenichi Ishibashi . unresolved

By `for_context`, do you want to distinguish per-profile vs per-context here? Or we may just remove it?

File services/network/public/mojom/network_context.mojom
Line 567, Patchset 7 (Latest): bool doh_fallback_allowed_for_context = false;
Kenichi Ishibashi . unresolved

Ditto.

Line 1074, Patchset 7 (Latest): SetDohFallbackAllowedForContext(bool allowed);
Kenichi Ishibashi . unresolved

Ditto.

Open in Gerrit

Related details

Attention is currently required from:
  • Andrew Williams
  • Dominic Farolino
  • Javier Castro
  • Takashi Toyoshima
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: Ic68f11ac41737355a665a98f217009a6cff66d7e
    Gerrit-Change-Number: 7704042
    Gerrit-PatchSet: 7
    Gerrit-Owner: Andrew Williams <awi...@chromium.org>
    Gerrit-Reviewer: Andrew Williams <awi...@chromium.org>
    Gerrit-Reviewer: Dominic Farolino <d...@chromium.org>
    Gerrit-Reviewer: Javier Castro <jaca...@chromium.org>
    Gerrit-Reviewer: Kenichi Ishibashi <ba...@chromium.org>
    Gerrit-Reviewer: Takashi Toyoshima <toyo...@chromium.org>
    Gerrit-CC: Brian Begnoche <b...@chromium.org>
    Gerrit-CC: Chromium IPC Reviews <chrome-ip...@google.com>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: Javier Castro <jaca...@chromium.org>
    Gerrit-Attention: Takashi Toyoshima <toyo...@chromium.org>
    Gerrit-Attention: Dominic Farolino <d...@chromium.org>
    Gerrit-Attention: Andrew Williams <awi...@chromium.org>
    Gerrit-Comment-Date: Mon, 30 Mar 2026 01:33:32 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Takashi Toyoshima (Gerrit)

    unread,
    Mar 30, 2026, 5:24:00 AM (5 days ago) Mar 30
    to Andrew Williams, Chromium IPC Reviews, Dominic Farolino, Kenichi Ishibashi, Javier Castro, Brian Begnoche, Chromium LUCI CQ, Chromium Metrics Reviews, AyeAye, asvitkine...@chromium.org, network-ser...@chromium.org, net-r...@chromium.org, fenced-fra...@chromium.org
    Attention needed from Andrew Williams, Dominic Farolino and Javier Castro

    Takashi Toyoshima added 4 comments

    Commit Message
    Line 10, Patchset 7 (Latest):fallback-to-default-DoH-provider logic for Enhanced Safe Browsing users,
    Takashi Toyoshima . unresolved

    may say "ESB: Enhanced Safe Browsing" for other references.

    File chrome/browser/net/profile_network_context_service.h
    Line 175, Patchset 7 (Latest):
    Takashi Toyoshima . unresolved

    Can we add some context in a function comment, as this is net/ in //Chrome/. So, it's nice to have more kind comments for other developers.

    File chrome/browser/net/profile_network_context_service.cc
    Line 585, Patchset 7 (Latest): pref_change_registrar_.Add(
    prefs::kSafeBrowsingEnhanced,
    base::BindRepeating(
    &ProfileNetworkContextService::UpdateDohFallbackAllowedForContext,
    base::Unretained(this)));
    Takashi Toyoshima . unresolved

    mistakenly registered twice?

    File net/dns/context_host_resolver.h
    Line 91, Patchset 7 (Latest): void SetDohFallbackAllowedForContext(bool allowed) override;
    Kenichi Ishibashi . unresolved

    Ditto. Since ContextHostResolver is already per context, "ForContext" might be redundant.

    Takashi Toyoshima

    +1

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Andrew Williams
    • Dominic Farolino
    • Javier Castro
    Gerrit-Attention: Dominic Farolino <d...@chromium.org>
    Gerrit-Attention: Andrew Williams <awi...@chromium.org>
    Gerrit-Comment-Date: Mon, 30 Mar 2026 09:23:25 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Kenichi Ishibashi <ba...@chromium.org>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Andrew Williams (Gerrit)

    unread,
    Mar 30, 2026, 11:16:47 AM (5 days ago) Mar 30
    to Chromium IPC Reviews, Dominic Farolino, Kenichi Ishibashi, Javier Castro, Takashi Toyoshima, Brian Begnoche, Chromium LUCI CQ, Chromium Metrics Reviews, AyeAye, asvitkine...@chromium.org, network-ser...@chromium.org, net-r...@chromium.org, fenced-fra...@chromium.org
    Attention needed from Dominic Farolino, Javier Castro and Kenichi Ishibashi

    Andrew Williams added 2 comments

    File chrome/browser/net/profile_network_context_service.h
    Line 176, Patchset 7 (Latest): void UpdateDohFallbackAllowedForContext();
    Kenichi Ishibashi . unresolved

    As I wrote in the other comment, the term "fallback" is confusing. We use "fallback" to refer to both the DoH provider fallback and the act of falling back to insecure (in the DNS stack).

    Can we figure out somewhat less confusing terms?

    Andrew Williams

    I'll think about this some more... These confusing terms are already in use, maybe we can proactively address those as well: https://source.chromium.org/chromium/chromium/src/+/main:net/dns/dns_config.h;l=108-116;drc=ab614c36f6203d6e3a6fbbe163136e5384f4a69d

    File net/dns/resolve_context.h
    Line 260, Patchset 7 (Latest): void set_doh_fallback_allowed_for_context(bool allowed) {
    Kenichi Ishibashi . unresolved

    By `for_context`, do you want to distinguish per-profile vs per-context here? Or we may just remove it?

    Andrew Williams

    Yeah I originally thought about using a name for these like "doh_fallback_allowed_by_profile_prefs", but from looking at existing naming it didn't seem like net/ had the concept of profiles. I figured "for_network_context" was the closest thing, but I shortened it to "for_context". I tried to explicitly avoid just using `doh_fallback_allowed` for this to disambiguate it from the case where the functionality is disabled by feature flag... I'll have to think more about this

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Dominic Farolino
    • Javier Castro
    • Kenichi Ishibashi
    Gerrit-Attention: Kenichi Ishibashi <ba...@chromium.org>
    Gerrit-Comment-Date: Mon, 30 Mar 2026 15:16:31 +0000
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Andrew Williams (Gerrit)

    unread,
    Mar 30, 2026, 9:19:23 PM (5 days ago) Mar 30
    to Chromium IPC Reviews, Dominic Farolino, Kenichi Ishibashi, Javier Castro, Takashi Toyoshima, Brian Begnoche, Chromium LUCI CQ, Chromium Metrics Reviews, AyeAye, asvitkine...@chromium.org, network-ser...@chromium.org, net-r...@chromium.org, fenced-fra...@chromium.org
    Attention needed from Dominic Farolino, Javier Castro, Kenichi Ishibashi and Takashi Toyoshima

    Andrew Williams added 1 comment

    File chrome/browser/net/profile_network_context_service.cc
    Line 585, Patchset 7 (Latest): pref_change_registrar_.Add(
    prefs::kSafeBrowsingEnhanced,
    base::BindRepeating(
    &ProfileNetworkContextService::UpdateDohFallbackAllowedForContext,
    base::Unretained(this)));
    Takashi Toyoshima . unresolved

    mistakenly registered twice?

    Andrew Williams

    I thought this as well, but these are slightly different - kSafeBrowsingEnabled vs. kSafeBrowsingEnhanced. We use the same handler when either of those change, and we listen for changes to both because that's what safe_browsing::IsEnhancedProtectionEnabled uses: https://source.chromium.org/chromium/chromium/src/+/main:components/safe_browsing/core/common/safe_browsing_prefs.cc;l=165-174;drc=9740839778fe4760edd07198ea924c880a9055d4

    @jaca...@chromium.org to confirm this is all we need, though.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Dominic Farolino
    • Javier Castro
    • Kenichi Ishibashi
    • Takashi Toyoshima
    Gerrit-Attention: Takashi Toyoshima <toyo...@chromium.org>
    Gerrit-Attention: Dominic Farolino <d...@chromium.org>
    Gerrit-Attention: Kenichi Ishibashi <ba...@chromium.org>
    Gerrit-Comment-Date: Tue, 31 Mar 2026 01:19:08 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Takashi Toyoshima <toyo...@chromium.org>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Andrew Williams (Gerrit)

    unread,
    Mar 30, 2026, 10:02:58 PM (5 days ago) Mar 30
    to Chromium IPC Reviews, Dominic Farolino, Kenichi Ishibashi, Javier Castro, Takashi Toyoshima, Brian Begnoche, Chromium LUCI CQ, Chromium Metrics Reviews, AyeAye, asvitkine...@chromium.org, network-ser...@chromium.org, net-r...@chromium.org, fenced-fra...@chromium.org
    Attention needed from Dominic Farolino, Javier Castro, Kenichi Ishibashi and Takashi Toyoshima

    Andrew Williams added 2 comments

    File chrome/browser/net/profile_network_context_service.h
    Line 176, Patchset 7 (Latest): void UpdateDohFallbackAllowedForContext();
    Kenichi Ishibashi . unresolved

    As I wrote in the other comment, the term "fallback" is confusing. We use "fallback" to refer to both the DoH provider fallback and the act of falling back to insecure (in the DNS stack).

    Can we figure out somewhat less confusing terms?

    Andrew Williams

    I'll think about this some more... These confusing terms are already in use, maybe we can proactively address those as well: https://source.chromium.org/chromium/chromium/src/+/main:net/dns/dns_config.h;l=108-116;drc=ab614c36f6203d6e3a6fbbe163136e5384f4a69d

    Andrew Williams

    WDYT about the following plan for naming? "Secondary" is the best I could come up with, but definitely open to suggestions.

    In this CL:
    ```
    ResolveContext::IsDohFallbackConfigPresent -> ResolveContext::IsDohConfigFromSecondaryDohNameservers
    NetworkContext::SetDohFallbackAllowedForContext -> NetworkContext::SetSecondaryDohAllowed
    HostResolver::SetDohFallbackAllowedForContext -> HostResolver::SetSecondaryDohAllowed
    FallbackFromSecureTransactionPreferredReason::kFallbackPreferredDohFallbackNotAllowed -> FallbackFromSecureTransactionPreferredReason::kFallbackPreferredSecondaryDohNotAllowed
    ... etc ...
    ```

    In a follow-up CL:

    ```
    DnsConfig::fallback_doh_nameservers -> DnsConfig::secondary_doh_nameservers
    DnsConfig::should_perform_doh_fallback_upgrade -> DnsConfig::doh_config_from_secondary_doh_nameservers
    ResolveContext::IsDohFallbackProbeEnabled -> ResolveContext::IsSecondaryDohProbeEnabled
    ResolveContext::doh_fallback_canary_domain_check_status -> ResolveContext::secondary_doh_canary_domain_check_status
    ... etc ...
    ```

    Maybe a less drastic change is using the phrase "DoH Fallback Upgrade" everywhere to denote this behavior and differentiate it from fallback to insecure DNS.

    File net/dns/resolve_context.h
    Line 260, Patchset 7 (Latest): void set_doh_fallback_allowed_for_context(bool allowed) {
    Kenichi Ishibashi . unresolved

    By `for_context`, do you want to distinguish per-profile vs per-context here? Or we may just remove it?

    Andrew Williams

    Yeah I originally thought about using a name for these like "doh_fallback_allowed_by_profile_prefs", but from looking at existing naming it didn't seem like net/ had the concept of profiles. I figured "for_network_context" was the closest thing, but I shortened it to "for_context". I tried to explicitly avoid just using `doh_fallback_allowed` for this to disambiguate it from the case where the functionality is disabled by feature flag... I'll have to think more about this

    Andrew Williams

    OK I thought about this some more, I think using "allowed" sufficiently differentiates it and we can try to use "enabled"/"disabled" to represent state based on feature flags. So I'll drop _for_context everywhere

    Gerrit-Comment-Date: Tue, 31 Mar 2026 02:02:51 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Kenichi Ishibashi <ba...@chromium.org>
    Comment-In-Reply-To: Andrew Williams <awi...@chromium.org>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Kenichi Ishibashi (Gerrit)

    unread,
    Mar 30, 2026, 10:47:06 PM (5 days ago) Mar 30
    to Andrew Williams, Chromium IPC Reviews, Dominic Farolino, Javier Castro, Takashi Toyoshima, Brian Begnoche, Chromium LUCI CQ, Chromium Metrics Reviews, AyeAye, asvitkine...@chromium.org, network-ser...@chromium.org, net-r...@chromium.org, fenced-fra...@chromium.org
    Attention needed from Andrew Williams, Dominic Farolino, Javier Castro and Takashi Toyoshima

    Kenichi Ishibashi added 3 comments

    Patchset-level comments
    Kenichi Ishibashi . resolved

    Thanks!

    File chrome/browser/net/profile_network_context_service.h
    Line 176, Patchset 7 (Latest): void UpdateDohFallbackAllowedForContext();
    Kenichi Ishibashi . unresolved

    As I wrote in the other comment, the term "fallback" is confusing. We use "fallback" to refer to both the DoH provider fallback and the act of falling back to insecure (in the DNS stack).

    Can we figure out somewhat less confusing terms?

    Andrew Williams

    I'll think about this some more... These confusing terms are already in use, maybe we can proactively address those as well: https://source.chromium.org/chromium/chromium/src/+/main:net/dns/dns_config.h;l=108-116;drc=ab614c36f6203d6e3a6fbbe163136e5384f4a69d

    Andrew Williams

    WDYT about the following plan for naming? "Secondary" is the best I could come up with, but definitely open to suggestions.

    In this CL:
    ```
    ResolveContext::IsDohFallbackConfigPresent -> ResolveContext::IsDohConfigFromSecondaryDohNameservers
    NetworkContext::SetDohFallbackAllowedForContext -> NetworkContext::SetSecondaryDohAllowed
    HostResolver::SetDohFallbackAllowedForContext -> HostResolver::SetSecondaryDohAllowed
    FallbackFromSecureTransactionPreferredReason::kFallbackPreferredDohFallbackNotAllowed -> FallbackFromSecureTransactionPreferredReason::kFallbackPreferredSecondaryDohNotAllowed
    ... etc ...
    ```

    In a follow-up CL:

    ```
    DnsConfig::fallback_doh_nameservers -> DnsConfig::secondary_doh_nameservers
    DnsConfig::should_perform_doh_fallback_upgrade -> DnsConfig::doh_config_from_secondary_doh_nameservers
    ResolveContext::IsDohFallbackProbeEnabled -> ResolveContext::IsSecondaryDohProbeEnabled
    ResolveContext::doh_fallback_canary_domain_check_status -> ResolveContext::secondary_doh_canary_domain_check_status
    ... etc ...
    ```

    Maybe a less drastic change is using the phrase "DoH Fallback Upgrade" everywhere to denote this behavior and differentiate it from fallback to insecure DNS.

    Kenichi Ishibashi

    AI suggested following options as well:
    1. "Alternative"
    2. "Supplemental"
    3. Public DoH or Default DoH, e.g. `SetPublicDohAllowed()`, `IsPublicDohConfigPresent()`
    4. Explicitly qualify with "Upgrade", e.g. `SetDohFallbackUpgradeAllowed()`

    Secondary sounds reasonable to me though.

    File net/dns/resolve_context.h
    Line 260, Patchset 7 (Latest): void set_doh_fallback_allowed_for_context(bool allowed) {
    Kenichi Ishibashi . resolved

    By `for_context`, do you want to distinguish per-profile vs per-context here? Or we may just remove it?

    Andrew Williams

    Yeah I originally thought about using a name for these like "doh_fallback_allowed_by_profile_prefs", but from looking at existing naming it didn't seem like net/ had the concept of profiles. I figured "for_network_context" was the closest thing, but I shortened it to "for_context". I tried to explicitly avoid just using `doh_fallback_allowed` for this to disambiguate it from the case where the functionality is disabled by feature flag... I'll have to think more about this

    Andrew Williams

    OK I thought about this some more, I think using "allowed" sufficiently differentiates it and we can try to use "enabled"/"disabled" to represent state based on feature flags. So I'll drop _for_context everywhere

    Kenichi Ishibashi

    Acknowledged

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Andrew Williams
    • Dominic Farolino
    • Javier Castro
    • Takashi Toyoshima
    Gerrit-Attention: Andrew Williams <awi...@chromium.org>
    Gerrit-Comment-Date: Tue, 31 Mar 2026 02:46:25 +0000
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Takashi Toyoshima (Gerrit)

    unread,
    Mar 31, 2026, 1:27:05 AM (4 days ago) Mar 31
    to Andrew Williams, Chromium IPC Reviews, Dominic Farolino, Kenichi Ishibashi, Javier Castro, Brian Begnoche, Chromium LUCI CQ, Chromium Metrics Reviews, AyeAye, asvitkine...@chromium.org, network-ser...@chromium.org, net-r...@chromium.org, fenced-fra...@chromium.org
    Attention needed from Andrew Williams, Dominic Farolino and Javier Castro

    Takashi Toyoshima added 1 comment

    File chrome/browser/net/profile_network_context_service.cc
    Line 585, Patchset 7 (Latest): pref_change_registrar_.Add(
    prefs::kSafeBrowsingEnhanced,
    base::BindRepeating(
    &ProfileNetworkContextService::UpdateDohFallbackAllowedForContext,
    base::Unretained(this)));
    Takashi Toyoshima . unresolved

    mistakenly registered twice?

    Andrew Williams

    I thought this as well, but these are slightly different - kSafeBrowsingEnabled vs. kSafeBrowsingEnhanced. We use the same handler when either of those change, and we listen for changes to both because that's what safe_browsing::IsEnhancedProtectionEnabled uses: https://source.chromium.org/chromium/chromium/src/+/main:components/safe_browsing/core/common/safe_browsing_prefs.cc;l=165-174;drc=9740839778fe4760edd07198ea924c880a9055d4

    @jaca...@chromium.org to confirm this is all we need, though.

    Takashi Toyoshima

    Ah, Enabled and Enhanced!
    So, as these names are very similar and confusing, can you add a short comment above these two calls, and say "register a callback for A and B"?

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Andrew Williams
    • Dominic Farolino
    • Javier Castro
    Gerrit-Attention: Dominic Farolino <d...@chromium.org>
    Gerrit-Attention: Andrew Williams <awi...@chromium.org>
    Gerrit-Comment-Date: Tue, 31 Mar 2026 05:26:39 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Takashi Toyoshima <toyo...@chromium.org>
    Comment-In-Reply-To: Andrew Williams <awi...@chromium.org>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Andrew Williams (Gerrit)

    unread,
    Mar 31, 2026, 1:54:40 PM (4 days ago) Mar 31
    to Chromium IPC Reviews, Dominic Farolino, Kenichi Ishibashi, Javier Castro, Takashi Toyoshima, Brian Begnoche, Chromium LUCI CQ, Chromium Metrics Reviews, AyeAye, asvitkine...@chromium.org, network-ser...@chromium.org, net-r...@chromium.org, fenced-fra...@chromium.org
    Attention needed from Dominic Farolino, Javier Castro, Kenichi Ishibashi and Takashi Toyoshima

    Andrew Williams added 9 comments

    Commit Message
    Line 10, Patchset 7:fallback-to-default-DoH-provider logic for Enhanced Safe Browsing users,
    Takashi Toyoshima . resolved

    may say "ESB: Enhanced Safe Browsing" for other references.

    Andrew Williams

    Done

    File chrome/browser/net/profile_network_context_service.h
    Line 176, Patchset 7: void UpdateDohFallbackAllowedForContext();
    Kenichi Ishibashi . resolved
    Andrew Williams

    Thanks for the suggestions, I'd be interested to hear what bcb@ thinks as well when he returns. Let's go with the "DoH Fallback Upgrade" naming for this CL and consider using renaming more broadly in a follow-up CL after talking with Brian. I've implemented this

    Line 176, Patchset 7: void UpdateDohFallbackAllowedForContext();
    Kenichi Ishibashi . resolved

    What does this "ForContext" mean? Simply name UpdateDohFallbackAllowed()?

    Andrew Williams

    Done

    Line 175, Patchset 7:
    Takashi Toyoshima . resolved

    Can we add some context in a function comment, as this is net/ in //Chrome/. So, it's nice to have more kind comments for other developers.

    Andrew Williams

    Done

    File chrome/browser/net/profile_network_context_service.cc
    Line 585, Patchset 7: pref_change_registrar_.Add(

    prefs::kSafeBrowsingEnhanced,
    base::BindRepeating(
    &ProfileNetworkContextService::UpdateDohFallbackAllowedForContext,
    base::Unretained(this)));
    Takashi Toyoshima . resolved

    mistakenly registered twice?

    Andrew Williams

    I thought this as well, but these are slightly different - kSafeBrowsingEnabled vs. kSafeBrowsingEnhanced. We use the same handler when either of those change, and we listen for changes to both because that's what safe_browsing::IsEnhancedProtectionEnabled uses: https://source.chromium.org/chromium/chromium/src/+/main:components/safe_browsing/core/common/safe_browsing_prefs.cc;l=165-174;drc=9740839778fe4760edd07198ea924c880a9055d4

    @jaca...@chromium.org to confirm this is all we need, though.

    Takashi Toyoshima

    Ah, Enabled and Enhanced!
    So, as these names are very similar and confusing, can you add a short comment above these two calls, and say "register a callback for A and B"?

    Andrew Williams

    Good thinking, done

    File net/dns/context_host_resolver.h
    Line 91, Patchset 7: void SetDohFallbackAllowedForContext(bool allowed) override;
    Kenichi Ishibashi . resolved

    Ditto. Since ContextHostResolver is already per context, "ForContext" might be redundant.

    Takashi Toyoshima

    +1

    Andrew Williams

    Done

    File net/dns/dns_client.cc
    Line 239, Patchset 7: if (context->IsDohFallbackConfigPresent() &&
    Kenichi Ishibashi . resolved

    The term 'fallback' is indeed overloaded here (referring to both the DoH provider type and the act of failing back to insecure). This logic correctly prioritizes the ESB-based restriction.

    Andrew Williams

    Done

    File services/network/public/mojom/network_context.mojom
    Line 567, Patchset 7: bool doh_fallback_allowed_for_context = false;
    Kenichi Ishibashi . resolved

    Ditto.

    Andrew Williams

    Done

    Line 1074, Patchset 7: SetDohFallbackAllowedForContext(bool allowed);
    Kenichi Ishibashi . resolved

    Ditto.

    Andrew Williams

    Done

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Dominic Farolino
    • Javier Castro
    • Kenichi Ishibashi
    • Takashi Toyoshima
    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: Ic68f11ac41737355a665a98f217009a6cff66d7e
      Gerrit-Change-Number: 7704042
      Gerrit-PatchSet: 9
      Gerrit-Owner: Andrew Williams <awi...@chromium.org>
      Gerrit-Reviewer: Andrew Williams <awi...@chromium.org>
      Gerrit-Reviewer: Dominic Farolino <d...@chromium.org>
      Gerrit-Reviewer: Javier Castro <jaca...@chromium.org>
      Gerrit-Reviewer: Kenichi Ishibashi <ba...@chromium.org>
      Gerrit-Reviewer: Takashi Toyoshima <toyo...@chromium.org>
      Gerrit-CC: Brian Begnoche <b...@chromium.org>
      Gerrit-CC: Chromium IPC Reviews <chrome-ip...@google.com>
      Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
      Gerrit-CC: gwsq
      Gerrit-Attention: Javier Castro <jaca...@chromium.org>
      Gerrit-Attention: Takashi Toyoshima <toyo...@chromium.org>
      Gerrit-Attention: Dominic Farolino <d...@chromium.org>
      Gerrit-Attention: Kenichi Ishibashi <ba...@chromium.org>
      Gerrit-Comment-Date: Tue, 31 Mar 2026 17:54:33 +0000
      Gerrit-HasComments: Yes
      Gerrit-Has-Labels: No
      Comment-In-Reply-To: Takashi Toyoshima <toyo...@chromium.org>
      satisfied_requirement
      unsatisfied_requirement
      open
      diffy

      Kenichi Ishibashi (Gerrit)

      unread,
      Apr 1, 2026, 12:17:45 AM (4 days ago) Apr 1
      to Andrew Williams, Chromium IPC Reviews, Dominic Farolino, Javier Castro, Takashi Toyoshima, Brian Begnoche, Chromium LUCI CQ, Chromium Metrics Reviews, AyeAye, asvitkine...@chromium.org, network-ser...@chromium.org, net-r...@chromium.org, fenced-fra...@chromium.org
      Attention needed from Andrew Williams, Dominic Farolino, Javier Castro and Takashi Toyoshima

      Kenichi Ishibashi voted and added 3 comments

      Votes added by Kenichi Ishibashi

      Code-Review+1

      3 comments

      Patchset-level comments
      File-level comment, Patchset 10 (Latest):
      Kenichi Ishibashi . resolved

      lgtm, thanks!

      File chrome/browser/net/profile_network_context_service.h
      Kenichi Ishibashi

      Ack

      File net/dns/resolve_context.h
      Line 273, Patchset 10 (Latest): // Returns true if the the current DoH configuration was added from the
      Kenichi Ishibashi . unresolved

      Typo: "the the" -> "the".

      Open in Gerrit

      Related details

      Attention is currently required from:
      • Andrew Williams
      • Dominic Farolino
      • Javier Castro
      • Takashi Toyoshima
      Submit Requirements:
        • requirement satisfiedCode-Coverage
        • requirement is not satisfiedCode-Owners
        • requirement satisfiedCode-Review
        • requirement is not satisfiedNo-Unresolved-Comments
        • requirement 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: Ic68f11ac41737355a665a98f217009a6cff66d7e
        Gerrit-Change-Number: 7704042
        Gerrit-PatchSet: 10
        Gerrit-Owner: Andrew Williams <awi...@chromium.org>
        Gerrit-Reviewer: Andrew Williams <awi...@chromium.org>
        Gerrit-Reviewer: Dominic Farolino <d...@chromium.org>
        Gerrit-Reviewer: Javier Castro <jaca...@chromium.org>
        Gerrit-Reviewer: Kenichi Ishibashi <ba...@chromium.org>
        Gerrit-Reviewer: Takashi Toyoshima <toyo...@chromium.org>
        Gerrit-CC: Brian Begnoche <b...@chromium.org>
        Gerrit-CC: Chromium IPC Reviews <chrome-ip...@google.com>
        Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
        Gerrit-CC: gwsq
        Gerrit-Attention: Javier Castro <jaca...@chromium.org>
        Gerrit-Attention: Takashi Toyoshima <toyo...@chromium.org>
        Gerrit-Attention: Dominic Farolino <d...@chromium.org>
        Gerrit-Attention: Andrew Williams <awi...@chromium.org>
        Gerrit-Comment-Date: Wed, 01 Apr 2026 04:17:16 +0000
        Gerrit-HasComments: Yes
        Gerrit-Has-Labels: Yes
        satisfied_requirement
        unsatisfied_requirement
        open
        diffy

        Takashi Toyoshima (Gerrit)

        unread,
        Apr 1, 2026, 1:59:15 AM (3 days ago) Apr 1
        to Andrew Williams, Kenichi Ishibashi, Chromium IPC Reviews, Dominic Farolino, Javier Castro, Brian Begnoche, Chromium LUCI CQ, Chromium Metrics Reviews, AyeAye, asvitkine...@chromium.org, network-ser...@chromium.org, net-r...@chromium.org, fenced-fra...@chromium.org
        Attention needed from Andrew Williams, Dominic Farolino and Javier Castro

        Takashi Toyoshima voted Code-Review+1

        Code-Review+1
        Open in Gerrit

        Related details

        Attention is currently required from:
        • Andrew Williams
        • Dominic Farolino
        • Javier Castro
        Submit Requirements:
        • requirement satisfiedCode-Coverage
        • requirement satisfiedCode-Owners
        • requirement satisfiedCode-Review
        • requirement is not satisfiedNo-Unresolved-Comments
        • requirement 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: Ic68f11ac41737355a665a98f217009a6cff66d7e
        Gerrit-Change-Number: 7704042
        Gerrit-PatchSet: 10
        Gerrit-Owner: Andrew Williams <awi...@chromium.org>
        Gerrit-Reviewer: Andrew Williams <awi...@chromium.org>
        Gerrit-Reviewer: Dominic Farolino <d...@chromium.org>
        Gerrit-Reviewer: Javier Castro <jaca...@chromium.org>
        Gerrit-Reviewer: Kenichi Ishibashi <ba...@chromium.org>
        Gerrit-Reviewer: Takashi Toyoshima <toyo...@chromium.org>
        Gerrit-CC: Brian Begnoche <b...@chromium.org>
        Gerrit-CC: Chromium IPC Reviews <chrome-ip...@google.com>
        Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
        Gerrit-CC: gwsq
        Gerrit-Attention: Javier Castro <jaca...@chromium.org>
        Gerrit-Attention: Dominic Farolino <d...@chromium.org>
        Gerrit-Attention: Andrew Williams <awi...@chromium.org>
        Gerrit-Comment-Date: Wed, 01 Apr 2026 05:58:47 +0000
        Gerrit-HasComments: No
        Gerrit-Has-Labels: Yes
        satisfied_requirement
        unsatisfied_requirement
        open
        diffy

        Javier Castro (Gerrit)

        unread,
        Apr 2, 2026, 1:30:07 PM (2 days ago) Apr 2
        to Andrew Williams, Takashi Toyoshima, Kenichi Ishibashi, Chromium IPC Reviews, Dominic Farolino, Brian Begnoche, Chromium LUCI CQ, Chromium Metrics Reviews, AyeAye, asvitkine...@chromium.org, network-ser...@chromium.org, net-r...@chromium.org, fenced-fra...@chromium.org
        Attention needed from Andrew Williams and Dominic Farolino

        Javier Castro voted and added 3 comments

        Votes added by Javier Castro

        Code-Review+1

        3 comments

        Patchset-level comments
        Javier Castro . resolved

        lgtm for ESB pref handling. I left some comments just outlining some of the issues we're taking on with this change -- but I don't expect the ESB pref implementation to change any time soon so I think this tech debt is ok. I filed crbug.com/498905576 to add an observer interface so that interested features will have an easier time with this in the future.

        File chrome/browser/net/profile_network_context_service.cc
        Line 583, Patchset 10 (Latest): prefs::kSafeBrowsingEnabled,
        Javier Castro . resolved

        I know it's not ideal, but listening to both prefs should work.

        We could probably just register for changes to prefs::kSafeBrowsingEnhanced, because changes to safe browsing state are supposed to pass through SetSafeBrowsingState which ensures that both values get updated. But since it's not easy to tell that from the code (and maybe there's a policy case that I'm not considering), listening to both sgtm.

        Also it looks like when setting the prefs, kSafeBrowsingEnhanced is consistently updated first and followed by kSafeBrowsingEnabled. Considering the state transitions, we should be getting consistent answers for IsEnhancedProtectionEnabled except for the transition from NO_PROTECTION to ENHANCED_PROTECTION -- in that case the `UpdateDohFallbackUpgradeAllowed` handler will be called twice and the first call will say enhanced protection is disabled and the second will say that it is enabled. But ultimately it gets the correct answer.

        File chrome/browser/net/profile_network_context_service_browsertest.cc
        Line 1018, Patchset 10 (Latest): profile_prefs->SetBoolean(prefs::kSafeBrowsingEnhanced, true);
        profile_prefs->SetBoolean(prefs::kSafeBrowsingEnabled, false);
        Javier Castro . resolved

        nit: enhanced true with enabled false isn't really a supported state, but it makes sense to test it here since if the safe browsing state transitions from NO_PROTECTION to ENHANCED_PROTECTION, the individual prefs will transition like this:

        ```
        kSafeBrowsingEnhanced -> false true true
        kSafeBrowsingEnabled -> false false true
        ```

        And I think that the handler we're registering in this changelist gets triggered twice and the first call gets ESB disabled and the second gets ESB enabled.

        Open in Gerrit

        Related details

        Attention is currently required from:
        • Andrew Williams
        • Dominic Farolino
        Gerrit-Attention: Dominic Farolino <d...@chromium.org>
        Gerrit-Attention: Andrew Williams <awi...@chromium.org>
        Gerrit-Comment-Date: Thu, 02 Apr 2026 17:29:59 +0000
        Gerrit-HasComments: Yes
        Gerrit-Has-Labels: Yes
        satisfied_requirement
        unsatisfied_requirement
        open
        diffy

        Andrew Williams (Gerrit)

        unread,
        Apr 3, 2026, 1:22:57 PM (24 hours ago) Apr 3
        to Javier Castro, Takashi Toyoshima, Kenichi Ishibashi, Chromium IPC Reviews, Dominic Farolino, Brian Begnoche, Chromium LUCI CQ, Chromium Metrics Reviews, AyeAye, asvitkine...@chromium.org, network-ser...@chromium.org, net-r...@chromium.org, fenced-fra...@chromium.org
        Attention needed from Dominic Farolino

        Andrew Williams added 3 comments

        Patchset-level comments
        Javier Castro . resolved

        lgtm for ESB pref handling. I left some comments just outlining some of the issues we're taking on with this change -- but I don't expect the ESB pref implementation to change any time soon so I think this tech debt is ok. I filed crbug.com/498905576 to add an observer interface so that interested features will have an easier time with this in the future.

        Andrew Williams

        Sounds great, thank you! At least for this code we shouldn't need it beyond the experiment (later we can just rely on the value of the pref specifically for this feature), so the tech debt burden should be shortlived.

        File chrome/browser/net/profile_network_context_service.cc
        Line 583, Patchset 10: prefs::kSafeBrowsingEnabled,
        Javier Castro . resolved

        I know it's not ideal, but listening to both prefs should work.

        We could probably just register for changes to prefs::kSafeBrowsingEnhanced, because changes to safe browsing state are supposed to pass through SetSafeBrowsingState which ensures that both values get updated. But since it's not easy to tell that from the code (and maybe there's a policy case that I'm not considering), listening to both sgtm.

        Also it looks like when setting the prefs, kSafeBrowsingEnhanced is consistently updated first and followed by kSafeBrowsingEnabled. Considering the state transitions, we should be getting consistent answers for IsEnhancedProtectionEnabled except for the transition from NO_PROTECTION to ENHANCED_PROTECTION -- in that case the `UpdateDohFallbackUpgradeAllowed` handler will be called twice and the first call will say enhanced protection is disabled and the second will say that it is enabled. But ultimately it gets the correct answer.

        Andrew Williams

        Thanks for confirming this, and good find on the two calls. As long as the value is correct after the last call this should be OK since all we do in the network service in response to these is update a boolean (we don't kick off probes or reschedule canary domain checks or anything)

        File net/dns/resolve_context.h
        Line 273, Patchset 10: // Returns true if the the current DoH configuration was added from the
        Kenichi Ishibashi . resolved

        Typo: "the the" -> "the".

        Andrew Williams

        Good good catch, done! 😊

        Open in Gerrit

        Related details

        Attention is currently required from:
        • Dominic Farolino
        Submit Requirements:
          • requirement satisfiedCode-Coverage
          • requirement satisfiedCode-Owners
          • requirement satisfiedCode-Review
          • requirement 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: Ic68f11ac41737355a665a98f217009a6cff66d7e
          Gerrit-Change-Number: 7704042
          Gerrit-PatchSet: 12
          Gerrit-Owner: Andrew Williams <awi...@chromium.org>
          Gerrit-Reviewer: Andrew Williams <awi...@chromium.org>
          Gerrit-Reviewer: Dominic Farolino <d...@chromium.org>
          Gerrit-Reviewer: Javier Castro <jaca...@chromium.org>
          Gerrit-Reviewer: Kenichi Ishibashi <ba...@chromium.org>
          Gerrit-Reviewer: Takashi Toyoshima <toyo...@chromium.org>
          Gerrit-CC: Brian Begnoche <b...@chromium.org>
          Gerrit-CC: Chromium IPC Reviews <chrome-ip...@google.com>
          Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
          Gerrit-CC: gwsq
          Gerrit-Attention: Dominic Farolino <d...@chromium.org>
          Gerrit-Comment-Date: Fri, 03 Apr 2026 17:22:49 +0000
          Gerrit-HasComments: Yes
          Gerrit-Has-Labels: No
          Comment-In-Reply-To: Javier Castro <jaca...@chromium.org>
          Comment-In-Reply-To: Kenichi Ishibashi <ba...@chromium.org>
          satisfied_requirement
          open
          diffy

          Chromium LUCI CQ (Gerrit)

          unread,
          Apr 3, 2026, 1:30:08 PM (24 hours ago) Apr 3
          to Andrew Williams, Dominic Farolino, Javier Castro, Takashi Toyoshima, Kenichi Ishibashi, Chromium IPC Reviews, Brian Begnoche, Chromium Metrics Reviews, AyeAye, asvitkine...@chromium.org, network-ser...@chromium.org, net-r...@chromium.org, fenced-fra...@chromium.org

          Chromium LUCI CQ submitted the change with unreviewed changes

          Unreviewed changes

          10 is the latest approved patch-set.
          The change was submitted with unreviewed changes in the following files:

          ```
          The name of the file: net/dns/resolve_context.h
          Insertions: 2, Deletions: 3.

          The diff is too large to show. Please review the diff.
          ```

          Change information

          Commit message:
          [DoH] Prevent use of fallback DoH provider when ESB disabled

          For an upcoming experiment we want to only enable the
          fallback-to-default-DoH-provider logic for Enhanced Safe Browsing (ESB)
          users, and since we intend to use a starts_active=false experiment we
          need the check of the experiment feature flag to be once we know a user
          is actually eligible for the functionality. Since the ESB prefs are
          per-profile, we need to make that check per-NetworkContext, so it's
          implemented where a ResolveContext is available.

          This functionality will continue to be disabled by default using the
          kForceSecureDnsDohFallback feature flag.

          In follow-on CLs we will also use this new pref-derived value to disable
          actually sending the DoH probes and canary domain check query when it's
          set to false.

          This CL was based on the following by bcb@:
          https://chromium-review.git.corp.google.com/c/chromium/src/+/7689192
          Bug: 490045356
          Change-Id: Ic68f11ac41737355a665a98f217009a6cff66d7e
          Reviewed-by: Takashi Toyoshima <toyo...@chromium.org>
          Reviewed-by: Javier Castro <jaca...@chromium.org>
          Reviewed-by: Kenichi Ishibashi <ba...@chromium.org>
          Commit-Queue: Andrew Williams <awi...@chromium.org>
          Cr-Commit-Position: refs/heads/main@{#1609845}
          Files:
          • M chrome/browser/net/profile_network_context_service.cc
          • M chrome/browser/net/profile_network_context_service.h
          • M chrome/browser/net/profile_network_context_service_browsertest.cc
          • M net/dns/canary_domain_service_unittest.cc
          • M net/dns/context_host_resolver.cc
          • M net/dns/context_host_resolver.h
          • M net/dns/context_host_resolver_unittest.cc
          • M net/dns/dns_client.cc
          • M net/dns/dns_client_unittest.cc
          • M net/dns/host_resolver.cc
          • M net/dns/host_resolver.h
          • M net/dns/mapped_host_resolver.cc
          • M net/dns/mapped_host_resolver.h
          • M net/dns/mock_host_resolver.cc
          • M net/dns/mock_host_resolver.h
          • M net/dns/resolve_context.cc
          • M net/dns/resolve_context.h
          • M net/dns/stale_host_resolver.cc
          • M net/dns/stale_host_resolver.h
          • M services/network/network_context.cc
          • M services/network/network_context.h
          • M services/network/network_context_unittest.cc
          • M services/network/public/mojom/network_context.mojom
          • M services/network/test/test_network_context.h
          • M tools/metrics/histograms/metadata/net/enums.xml
          Change size: L
          Delta: 25 files changed, 266 insertions(+), 9 deletions(-)
          Branch: refs/heads/main
          Submit Requirements:
          • requirement satisfiedCode-Review: +1 by Takashi Toyoshima, +1 by Kenichi Ishibashi, +1 by Javier Castro
          Open in Gerrit
          Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
          Gerrit-MessageType: merged
          Gerrit-Project: chromium/src
          Gerrit-Branch: main
          Gerrit-Change-Id: Ic68f11ac41737355a665a98f217009a6cff66d7e
          Gerrit-Change-Number: 7704042
          Gerrit-PatchSet: 13
          Gerrit-Owner: Andrew Williams <awi...@chromium.org>
          Gerrit-Reviewer: Andrew Williams <awi...@chromium.org>
          Gerrit-Reviewer: Chromium LUCI CQ <chromiu...@luci-project-accounts.iam.gserviceaccount.com>
          Gerrit-Reviewer: Javier Castro <jaca...@chromium.org>
          Gerrit-Reviewer: Kenichi Ishibashi <ba...@chromium.org>
          Gerrit-Reviewer: Takashi Toyoshima <toyo...@chromium.org>
          Gerrit-CC: Brian Begnoche <b...@chromium.org>
          Gerrit-CC: Chromium IPC Reviews <chrome-ip...@google.com>
          Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
          Gerrit-CC: Dominic Farolino <d...@chromium.org>
          Gerrit-CC: gwsq
          open
          diffy
          satisfied_requirement
          Reply all
          Reply to author
          Forward
          0 new messages