Prompt dialog to confirm protocol handlers registered by extensions [chromium/src : main]

0 views
Skip to first unread message

Javier Fernandez (Gerrit)

unread,
Oct 15, 2025, 6:03:20 PMOct 15
to Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
Attention needed from Solomon Kinard

Javier Fernandez added 1 comment

Patchset-level comments
File-level comment, Patchset 7 (Latest):
Javier Fernandez . resolved

Hi @solomonkinard, I'd appreciate some early-feedback about this CL, even though it's still work in progress.

The main functionality, as described in the design document, is complete. There are some missing translation and proper unit and browser tests, but I have doubts about the right approach to implement the custom dialog for this case.

It seems that there are different ways, from subclassing BubbleDialogDelegateView or directly from DialogDelegateView to the new composite approach described in the /class_splitting.md. In this patch I got inspiration from the ExternalHandlerDialog, which uses the static method defined in the cosntrained_window namespace. There are there comments about the preference of using the TabDialogManager.

Open in Gerrit

Related details

Attention is currently required from:
  • Solomon Kinard
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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
Gerrit-Change-Number: 7031939
Gerrit-PatchSet: 7
Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
Gerrit-Reviewer: Solomon Kinard <solomo...@chromium.org>
Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
Gerrit-CC: Peter Beverloo <pe...@chromium.org>
Gerrit-Attention: Solomon Kinard <solomo...@chromium.org>
Gerrit-Comment-Date: Wed, 15 Oct 2025 22:02:29 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
satisfied_requirement
unsatisfied_requirement
open
diffy

Javier Fernandez (Gerrit)

unread,
Oct 20, 2025, 3:46:43 AMOct 20
to Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
Attention needed from Solomon Kinard

Javier Fernandez added 1 comment

Patchset-level comments
Javier Fernandez . resolved

Hi @solomonkinard

Although the patch is still WIP, I marked it ready for review because I'm afraid you wouldn't get the notification.

I'd just need some early review regarding the best approach to implement the new prompt dialog for this use case, as explained in the design doc.

Thanks.

Open in Gerrit

Related details

Attention is currently required from:
  • Solomon Kinard
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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
Gerrit-Change-Number: 7031939
Gerrit-PatchSet: 7
Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
Gerrit-Reviewer: Solomon Kinard <solomo...@chromium.org>
Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
Gerrit-CC: Peter Beverloo <pe...@chromium.org>
Gerrit-Attention: Solomon Kinard <solomo...@chromium.org>
Gerrit-Comment-Date: Mon, 20 Oct 2025 07:46:24 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
satisfied_requirement
unsatisfied_requirement
open
diffy

Solomon Kinard (Gerrit)

unread,
Oct 20, 2025, 3:27:51 PMOct 20
to Javier Fernandez, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
Attention needed from Javier Fernandez

Solomon Kinard added 5 comments

Patchset-level comments
Solomon Kinard . resolved

Thanks.

File components/custom_handlers/confirm_protocol_handler_dialog.h
Line 42, Patchset 7 (Latest):class ConfirmProtocolHandlerDialog : public views::DialogDelegateView {
Solomon Kinard . unresolved

I didn't see a mock in the DD (design doc). Can a SS (screenshot) be added e.g. a link to a crbug.com image upload in the commit message?

File components/custom_handlers/confirm_protocol_handler_dialog.cc
Line 114, Patchset 7 (Latest): VLOG(0) << "ConfirmProtocolHandlerDialog::OnDialogCancelled -- ";
Solomon Kinard . unresolved

^

File components/custom_handlers/protocol_handler.cc
File components/custom_handlers/protocol_handler_navigation_throttle.cc
Line 87, Patchset 7 (Latest): VLOG(0) << "ProtocolHandlerNavigationThrottle::RequestPermissionForHandler "
Solomon Kinard . unresolved

Are these VLOG's intentional, here and elsewhere?

Open in Gerrit

Related details

Attention is currently required from:
  • Javier Fernandez
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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
    Gerrit-Change-Number: 7031939
    Gerrit-PatchSet: 7
    Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
    Gerrit-Reviewer: Solomon Kinard <solomo...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: Peter Beverloo <pe...@chromium.org>
    Gerrit-Attention: Javier Fernandez <jfern...@igalia.com>
    Gerrit-Comment-Date: Mon, 20 Oct 2025 19:27:40 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Javier Fernandez (Gerrit)

    unread,
    Oct 21, 2025, 5:28:19 AMOct 21
    to Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Solomon Kinard

    Javier Fernandez added 4 comments

    Patchset-level comments
    File-level comment, Patchset 9 (Latest):
    Javier Fernandez . resolved

    Thanks @solomonkinard for the comments.

    Bear in mind that the main issue I'd like to clarify is what's the best approach to implement the prompt dialog; apparently there are different ways to do it and it's not clear what fits better in this use case.

    It's also worth mentioning that the custom_handlers feature is not available in android, so we are targeting just Desktop platforms.

    File components/custom_handlers/confirm_protocol_handler_dialog.h
    Line 42, Patchset 7:class ConfirmProtocolHandlerDialog : public views::DialogDelegateView {
    Solomon Kinard . resolved

    I didn't see a mock in the DD (design doc). Can a SS (screenshot) be added e.g. a link to a crbug.com image upload in the commit message?

    Javier Fernandez

    Done

    File components/custom_handlers/confirm_protocol_handler_dialog.cc
    Line 114, Patchset 7: VLOG(0) << "ConfirmProtocolHandlerDialog::OnDialogCancelled -- ";
    Solomon Kinard . resolved

    ^

    Javier Fernandez

    Ditto

    File components/custom_handlers/protocol_handler_navigation_throttle.cc
    Line 87, Patchset 7: VLOG(0) << "ProtocolHandlerNavigationThrottle::RequestPermissionForHandler "
    Solomon Kinard . unresolved

    Are these VLOG's intentional, here and elsewhere?

    Javier Fernandez

    Well, as I said before, this is just a prototype to evaluate different ways to intercept the Navigation and launch a prompt dialog to ask the user for confirmation. These logs are going to be removed probably.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Solomon Kinard
    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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
    Gerrit-Change-Number: 7031939
    Gerrit-PatchSet: 9
    Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
    Gerrit-Reviewer: Solomon Kinard <solomo...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: Peter Beverloo <pe...@chromium.org>
    Gerrit-Attention: Solomon Kinard <solomo...@chromium.org>
    Gerrit-Comment-Date: Tue, 21 Oct 2025 09:28:06 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Solomon Kinard <solomo...@chromium.org>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Javier Fernandez (Gerrit)

    unread,
    Oct 21, 2025, 5:28:34 AMOct 21
    to Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Solomon Kinard

    Javier Fernandez added 1 comment

    File components/custom_handlers/protocol_handler.cc
    Line 79, Patchset 7: base::Time::Now(), true,
    Gerrit-Comment-Date: Tue, 21 Oct 2025 09:28:18 +0000
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Solomon Kinard (Gerrit)

    unread,
    Oct 21, 2025, 9:13:02 AMOct 21
    to Javier Fernandez, Emilia Paz, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Emilia Paz

    Solomon Kinard added 1 comment

    Patchset-level comments
    Solomon Kinard . resolved

    emiliapaz@ might know the best approach to implement the prompt dialog? If not, feel free to add back as a reviewer.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Emilia Paz
    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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
    Gerrit-Change-Number: 7031939
    Gerrit-PatchSet: 9
    Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
    Gerrit-Reviewer: Emilia Paz <emil...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: Peter Beverloo <pe...@chromium.org>
    Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
    Gerrit-Attention: Emilia Paz <emil...@chromium.org>
    Gerrit-Comment-Date: Tue, 21 Oct 2025 13:12:51 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Emilia Paz (Gerrit)

    unread,
    Oct 21, 2025, 6:15:27 PMOct 21
    to Javier Fernandez, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Javier Fernandez

    Emilia Paz added 5 comments

    Patchset-level comments
    Emilia Paz . resolved

    Thanks Javier! I only looked at the dialog construction. There is a new preferred way to construct them using `ui::DialogModel`. Linkes to some examples, but please reach out if you have any questions.
    I didn't look at the protocol handler parts

    File components/custom_handlers/confirm_protocol_handler_dialog.h
    File components/custom_handlers/confirm_protocol_handler_dialog.cc
    Line 47, Patchset 9 (Latest): VLOG(0) << "ProtocolHandlerThrottle::RunConfirmProtocolHandlerDialog -- ";
    Emilia Paz . unresolved

    nit: We shouldn't add logs into landed code unless absolutely necessary (see [guide](https://chromium.googlesource.com/chromium/src/+/main/styleguide/c++/c++.md#logging))

    File components/protocol_handler_strings.grdp
    Line 36, Patchset 9 (Latest): Confirm protocol handler.
    Emilia Paz . unresolved

    We may need to include the extension name here?
    Usually extensions dialogs have the extension name, or are anchored to thge extension action in the toolbar. What triggers the dialog?

    File ui/views/window/dialog_delegate.h
    Line 724, Patchset 9 (Latest): friend class ::custom_handlers::ConfirmProtocolHandlerDialog;
    Emilia Paz . unresolved

    We shouldn't add more classes to this. We shouldn't need this if we use `ui::DialogModel`

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Javier Fernandez
    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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
    Gerrit-Change-Number: 7031939
    Gerrit-PatchSet: 9
    Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
    Gerrit-Reviewer: Emilia Paz <emil...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: Peter Beverloo <pe...@chromium.org>
    Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
    Gerrit-Attention: Javier Fernandez <jfern...@igalia.com>
    Gerrit-Comment-Date: Tue, 21 Oct 2025 22:15:17 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Javier Fernandez (Gerrit)

    unread,
    Oct 30, 2025, 2:02:26 PMOct 30
    to Emilia Paz, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Emilia Paz and Solomon Kinard

    Javier Fernandez added 5 comments

    Patchset-level comments
    File-level comment, Patchset 11 (Latest):
    Javier Fernandez . resolved

    Many thanks for the insightful feedback @emiliapaz.

    I still need to do some additional work in the dialog, like identifying the extension in the prompt message and deal with the translation issues, but I hope the CL is going in the right direction.

    @solomonkinard, perhaps you'd have some comments regarding the navigation interception logic.

    Thanks.

    File components/custom_handlers/confirm_protocol_handler_dialog.h
    Line 42, Patchset 9:class ConfirmProtocolHandlerDialog : public views::DialogDelegateView {
    Javier Fernandez

    Thank you very much for the examples. I submitted a new patch trying to follow the same approach.

    File components/custom_handlers/confirm_protocol_handler_dialog.cc
    Line 47, Patchset 9: VLOG(0) << "ProtocolHandlerThrottle::RunConfirmProtocolHandlerDialog -- ";
    Emilia Paz . resolved

    nit: We shouldn't add logs into landed code unless absolutely necessary (see [guide](https://chromium.googlesource.com/chromium/src/+/main/styleguide/c++/c++.md#logging))

    Javier Fernandez

    Done

    File components/protocol_handler_strings.grdp
    Line 36, Patchset 9: Confirm protocol handler.
    Emilia Paz . unresolved

    We may need to include the extension name here?
    Usually extensions dialogs have the extension name, or are anchored to thge extension action in the toolbar. What triggers the dialog?

    Javier Fernandez

    Thanks for the suggestion. I think mentioning the extension that is responsible of this prompt makes a lot of sense. However, this is perhaps a special case, so I'm going to try to describe it briefly here.

    An extension may register a few protocol handlers for some specific URL's schemes. Instead of asking for permission when the handler is registered (as it happens with the Web API), these handlers are "unconfirmed" until there is a navigation request to a url with a scheme for which there such "unconfirmed" handler. In that case, the user may allow the protocol handler to take care of the navigation requests or deny it. It optionally may remember the decision for any future navigation request to the **same scheme**.

    I think in this contest, it makes sense to inform the user what extension is responsible of the custom handler that is about to be used.

    In this CL I didn't implemented that behavior, though. but I definitively will.

    File ui/views/window/dialog_delegate.h
    Line 724, Patchset 9: friend class ::custom_handlers::ConfirmProtocolHandlerDialog;
    Emilia Paz . resolved

    We shouldn't add more classes to this. We shouldn't need this if we use `ui::DialogModel`

    Javier Fernandez

    Done

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Emilia Paz
    • Solomon Kinard
    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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
    Gerrit-Change-Number: 7031939
    Gerrit-PatchSet: 11
    Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
    Gerrit-Reviewer: Emilia Paz <emil...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: Peter Beverloo <pe...@chromium.org>
    Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
    Gerrit-Attention: Solomon Kinard <solomo...@chromium.org>
    Gerrit-Attention: Emilia Paz <emil...@chromium.org>
    Gerrit-Comment-Date: Thu, 30 Oct 2025 18:02:04 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Emilia Paz <emil...@chromium.org>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Javier Fernandez (Gerrit)

    unread,
    Oct 30, 2025, 6:47:54 PMOct 30
    to Emilia Paz, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Emilia Paz and Solomon Kinard

    Javier Fernandez added 1 comment

    File components/custom_handlers/protocol_handler_navigation_throttle.cc
    Line 87, Patchset 7: VLOG(0) << "ProtocolHandlerNavigationThrottle::RequestPermissionForHandler "
    Solomon Kinard . resolved

    Are these VLOG's intentional, here and elsewhere?

    Javier Fernandez

    Well, as I said before, this is just a prototype to evaluate different ways to intercept the Navigation and launch a prompt dialog to ask the user for confirmation. These logs are going to be removed probably.

    Javier Fernandez

    These logs has been removed in the last patch.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Emilia Paz
    • Solomon Kinard
    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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
    Gerrit-Change-Number: 7031939
    Gerrit-PatchSet: 12
    Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
    Gerrit-Reviewer: Emilia Paz <emil...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: Peter Beverloo <pe...@chromium.org>
    Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
    Gerrit-Attention: Solomon Kinard <solomo...@chromium.org>
    Gerrit-Attention: Emilia Paz <emil...@chromium.org>
    Gerrit-Comment-Date: Thu, 30 Oct 2025 22:47:32 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Solomon Kinard <solomo...@chromium.org>
    Comment-In-Reply-To: Javier Fernandez <jfern...@igalia.com>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Emilia Paz (Gerrit)

    unread,
    Oct 31, 2025, 5:24:15 PMOct 31
    to Javier Fernandez, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Javier Fernandez and Solomon Kinard

    Emilia Paz added 11 comments

    Patchset-level comments
    File-level comment, Patchset 13 (Latest):
    Emilia Paz . resolved

    Thanks Javier! Extension dialog looks good, just some small comments. I would suggest dividing this change in
    (1) protocol handler work
    (2) add extension dialog
    (3) enable feature by default

    File chrome/browser/custom_handlers/chrome_protocol_handler_navigation_throttle.h
    Line 42, Patchset 13 (Latest):
    void RunConfirmProtocolHandlerDialog(
    content::WebContents* web_contents,
    const ProtocolHandler& handler,
    const std::optional<url::Origin>& initiating_origin,
    ProtocolHandlerConfirmCallback callback) const override;
    };
    Emilia Paz . unresolved

    nit: add comment

    Line 37, Patchset 13 (Latest): static void MaybeCreateAndAdd(content::NavigationThrottleRegistry&,
    ProtocolHandlerRegistry*);
    Emilia Paz . unresolved

    nit: add comment

    Line 16, Patchset 13 (Latest):}
    Emilia Paz . unresolved

    same

    Line 12, Patchset 13 (Latest):}
    Emilia Paz . unresolved

    nit: C++ namespaces should be ended with a comment, using the format // namespace <namespace_name> per https://google.github.io/styleguide/cppguide.html#Namespaces

    File chrome/browser/ui/extensions/confirm_protocol_handler_dialog.cc
    Line 49, Patchset 13 (Latest): base::UTF8ToUTF16(extension->name()),
    Emilia Paz . unresolved

    Lets use `extensions::util::GetFixupExtensionNameForUIDisplay`, which handles extension long names in the UI

    File chrome/browser/ui/extensions/extensions_dialogs.h
    Line 152, Patchset 13 (Latest):void ShowConfirmProtocolHandlerDialog(
    // const ExtensionId& extension_id,
    // const std::string& extension_name,
    Emilia Paz . unresolved

    nit: remove commented out code and add comment to the function

    Line 35, Patchset 13 (Latest):}
    Emilia Paz . unresolved

    same namespace comment on this file

    File components/protocol_handler_strings.grdp
    Line 36, Patchset 9: Confirm protocol handler.
    Emilia Paz . resolved

    We may need to include the extension name here?
    Usually extensions dialogs have the extension name, or are anchored to thge extension action in the toolbar. What triggers the dialog?

    Javier Fernandez

    Thanks for the suggestion. I think mentioning the extension that is responsible of this prompt makes a lot of sense. However, this is perhaps a special case, so I'm going to try to describe it briefly here.

    An extension may register a few protocol handlers for some specific URL's schemes. Instead of asking for permission when the handler is registered (as it happens with the Web API), these handlers are "unconfirmed" until there is a navigation request to a url with a scheme for which there such "unconfirmed" handler. In that case, the user may allow the protocol handler to take care of the navigation requests or deny it. It optionally may remember the decision for any future navigation request to the **same scheme**.

    I think in this contest, it makes sense to inform the user what extension is responsible of the custom handler that is about to be used.

    In this CL I didn't implemented that behavior, though. but I definitively will.

    Emilia Paz

    Thanks for the explanation. If I am reading this correctly, the dialog may appear not after a direct interaction with the extension. Thus, I think it's good to include the extension name in the dialog

    File extensions/common/extension_features.cc
    Line 86, Patchset 13 (Latest):BASE_FEATURE(kExtensionProtocolHandlers, base::FEATURE_ENABLED_BY_DEFAULT);
    Emilia Paz . unresolved

    This change is getting large. I would separate this to a separate change

    File ui/views/window/dialog_delegate.h
    Line 724, Patchset 13 (Latest): friend class ::custom_handlers::ConfirmProtocolHandlerDialog;
    Emilia Paz . unresolved

    do we need changes on this file? I think it's lefotver from previous patchset

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Javier Fernandez
    • Solomon Kinard
    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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
    Gerrit-Change-Number: 7031939
    Gerrit-PatchSet: 13
    Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
    Gerrit-Reviewer: Emilia Paz <emil...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: Peter Beverloo <pe...@chromium.org>
    Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
    Gerrit-Attention: Solomon Kinard <solomo...@chromium.org>
    Gerrit-Attention: Javier Fernandez <jfern...@igalia.com>
    Gerrit-Comment-Date: Fri, 31 Oct 2025 21:24:06 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Emilia Paz <emil...@chromium.org>
    Comment-In-Reply-To: Javier Fernandez <jfern...@igalia.com>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Javier Fernandez (Gerrit)

    unread,
    Nov 3, 2025, 11:51:31 AMNov 3
    to Emilia Paz, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Emilia Paz and Solomon Kinard

    Javier Fernandez added 11 comments

    Patchset-level comments
    File-level comment, Patchset 15 (Latest):
    Javier Fernandez . resolved

    Thanks for the review Emilia !

    Regarding splitting up the patch, I could perhaps implement in a separated CL the logic to handle the new ProtocolHandler attribute "is_confirmed", but the rest (eg the NavigaitonThrottle) would only make sense together with the new Dialog. I'll consider it, though.

    File chrome/browser/custom_handlers/chrome_protocol_handler_navigation_throttle.h

    void RunConfirmProtocolHandlerDialog(
    content::WebContents* web_contents,
    const ProtocolHandler& handler,
    const std::optional<url::Origin>& initiating_origin,
    ProtocolHandlerConfirmCallback callback) const override;
    };
    Emilia Paz . resolved

    nit: add comment

    Javier Fernandez

    Done

    Line 37, Patchset 13: static void MaybeCreateAndAdd(content::NavigationThrottleRegistry&,
    ProtocolHandlerRegistry*);
    Emilia Paz . resolved

    nit: add comment

    Javier Fernandez

    Done

    Line 16, Patchset 13:}
    Emilia Paz . resolved

    same

    Javier Fernandez

    Done

    Line 12, Patchset 13:}
    Emilia Paz . resolved

    nit: C++ namespaces should be ended with a comment, using the format // namespace <namespace_name> per https://google.github.io/styleguide/cppguide.html#Namespaces

    Javier Fernandez

    Done

    File chrome/browser/ui/extensions/confirm_protocol_handler_dialog.cc
    Line 49, Patchset 13: base::UTF8ToUTF16(extension->name()),
    Emilia Paz . resolved

    Lets use `extensions::util::GetFixupExtensionNameForUIDisplay`, which handles extension long names in the UI

    Javier Fernandez

    Done

    File chrome/browser/ui/extensions/extensions_dialogs.h
    Line 152, Patchset 13:void ShowConfirmProtocolHandlerDialog(

    // const ExtensionId& extension_id,
    // const std::string& extension_name,
    Emilia Paz . resolved

    nit: remove commented out code and add comment to the function

    Javier Fernandez

    Done

    Line 35, Patchset 13:}
    Emilia Paz . resolved

    same namespace comment on this file

    Javier Fernandez

    Done

    File components/custom_handlers/confirm_protocol_handler_dialog.h
    Line 42, Patchset 9:class ConfirmProtocolHandlerDialog : public views::DialogDelegateView {
    Emilia Paz . resolved

    It's preferred to use `ui::DialogModel` rather than `views::DialogDelegateView` for constructing dialogs. The model makes it easier to build the dialog, can see a guide here:
    https://chromium.googlesource.com/chromium/src/+/main/chrome/browser/ui/views/extensions/dialogs/README.md

    Some examples:
    https://source.chromium.org/chromium/chromium/src/+/main:chrome/browser/ui/extensions/extension_install_friction_dialog.cc?q=extension_install_friction&ss=chromium%2Fchromium%2Fsrc
    https://source.chromium.org/chromium/chromium/src/+/main:chrome/browser/ui/views/extensions/dialogs/mv2_deprecation_reenable_dialog.cc

    Javier Fernandez

    Thank you very much for the examples. I submitted a new patch trying to follow the same approach.

    Javier Fernandez

    Done

    File extensions/common/extension_features.cc
    Line 86, Patchset 13:BASE_FEATURE(kExtensionProtocolHandlers, base::FEATURE_ENABLED_BY_DEFAULT);
    Emilia Paz . resolved

    This change is getting large. I would separate this to a separate change

    Javier Fernandez

    Yeah, this change was unintentional The feature still needs more work before we can enable it.

    File ui/views/window/dialog_delegate.h
    Line 724, Patchset 13: friend class ::custom_handlers::ConfirmProtocolHandlerDialog;
    Emilia Paz . resolved

    do we need changes on this file? I think it's lefotver from previous patchset

    Javier Fernandez

    Yes, indeed.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Emilia Paz
    • Solomon Kinard
    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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
      Gerrit-Change-Number: 7031939
      Gerrit-PatchSet: 15
      Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
      Gerrit-Reviewer: Emilia Paz <emil...@chromium.org>
      Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
      Gerrit-CC: Peter Beverloo <pe...@chromium.org>
      Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
      Gerrit-Attention: Solomon Kinard <solomo...@chromium.org>
      Gerrit-Attention: Emilia Paz <emil...@chromium.org>
      Gerrit-Comment-Date: Mon, 03 Nov 2025 16:51:15 +0000
      satisfied_requirement
      unsatisfied_requirement
      open
      diffy

      Emilia Paz (Gerrit)

      unread,
      Nov 3, 2025, 2:33:07 PMNov 3
      to Javier Fernandez, Chromium LUCI CQ, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
      Attention needed from Javier Fernandez and Solomon Kinard

      Emilia Paz added 3 comments

      Patchset-level comments
      Emilia Paz . resolved

      Thanks Javier! Dialog construction looks good to me. There are some build errors though:
      (a) `//chrome/browser/custom_handlers/chrome_protocol_handler_navigation_throttle.cc` needs access to `chrome/browser/ui/extensions/extensions_dialogs.h`
      (b) Using views::View on Android included on components/custom_handlers/BUILD.gn

      File chrome/browser/ui/extensions/extensions_dialogs.h
      Line 47, Patchset 15 (Latest):}
      Emilia Paz . unresolved

      nit: add namespace name

      File components/custom_handlers/BUILD.gn
      Line 30, Patchset 15 (Latest): "//ui/views",
      Emilia Paz . unresolved

      is this needed? We shouldn't need to use `views::View` on this CL since we are using `ui::DialaogModel`

      Open in Gerrit

      Related details

      Attention is currently required from:
      • Javier Fernandez
      • Solomon Kinard
      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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
        Gerrit-Change-Number: 7031939
        Gerrit-PatchSet: 15
        Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
        Gerrit-Reviewer: Emilia Paz <emil...@chromium.org>
        Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
        Gerrit-CC: Peter Beverloo <pe...@chromium.org>
        Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
        Gerrit-Attention: Solomon Kinard <solomo...@chromium.org>
        Gerrit-Attention: Javier Fernandez <jfern...@igalia.com>
        Gerrit-Comment-Date: Mon, 03 Nov 2025 19:32:58 +0000
        Gerrit-HasComments: Yes
        Gerrit-Has-Labels: No
        satisfied_requirement
        unsatisfied_requirement
        open
        diffy

        Javier Fernandez (Gerrit)

        unread,
        Nov 3, 2025, 6:37:36 PMNov 3
        to Chromium LUCI CQ, Emilia Paz, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
        Attention needed from Emilia Paz and Solomon Kinard

        Javier Fernandez added 4 comments

        Patchset-level comments
        Emilia Paz . resolved

        Thanks Javier! Dialog construction looks good to me. There are some build errors though:
        (a) `//chrome/browser/custom_handlers/chrome_protocol_handler_navigation_throttle.cc` needs access to `chrome/browser/ui/extensions/extensions_dialogs.h`
        (b) Using views::View on Android included on components/custom_handlers/BUILD.gn

        Javier Fernandez

        Adding the "chrome/browser/ui/extensions:extensions" dep creates a cycle that deserves its own CL to solve it.

        File-level comment, Patchset 16 (Latest):
        Javier Fernandez . resolved

        Thanks again for the review, Emilia.
        I'm going to fix the dependency cycle issues in a different CL; I may also split up the protocol handlers part as well, as you have suggested.

        Meanwhile, I wonder what to do with the translation of the new dialog. I tried to define the text I considered more appropriated, but perhaps someone from the UI/UX team should review it before asking for translations.

        File chrome/browser/ui/extensions/extensions_dialogs.h
        Line 47, Patchset 15:}
        Emilia Paz . resolved

        nit: add namespace name

        Javier Fernandez

        Done

        File components/custom_handlers/BUILD.gn
        Line 30, Patchset 15: "//ui/views",
        Emilia Paz . resolved

        is this needed? We shouldn't need to use `views::View` on this CL since we are using `ui::DialaogModel`

        Javier Fernandez

        No, it's not needed; neither the "//components/constrained_window" dependency.
        Thanks !

        Open in Gerrit

        Related details

        Attention is currently required from:
        • Emilia Paz
        • Solomon Kinard
        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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
          Gerrit-Change-Number: 7031939
          Gerrit-PatchSet: 16
          Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
          Gerrit-Reviewer: Emilia Paz <emil...@chromium.org>
          Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
          Gerrit-CC: Peter Beverloo <pe...@chromium.org>
          Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
          Gerrit-Attention: Solomon Kinard <solomo...@chromium.org>
          Gerrit-Attention: Emilia Paz <emil...@chromium.org>
          Gerrit-Comment-Date: Mon, 03 Nov 2025 23:37:22 +0000
          Gerrit-HasComments: Yes
          Gerrit-Has-Labels: No
          Comment-In-Reply-To: Emilia Paz <emil...@chromium.org>
          satisfied_requirement
          unsatisfied_requirement
          open
          diffy

          Javier Fernandez (Gerrit)

          unread,
          Nov 19, 2025, 3:23:10 AMNov 19
          to Emilia Paz, Chromium LUCI CQ, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
          Attention needed from Emilia Paz and Javier Fernandez

          Javier Fernandez voted and added 3 comments

          Votes added by Javier Fernandez

          Commit-Queue+1

          3 comments

          Patchset-level comments
          File-level comment, Patchset 13:
          Emilia Paz . resolved

          Thanks Javier! Extension dialog looks good, just some small comments. I would suggest dividing this change in

          (1) protocol handler work
          (2) add extension dialog
          (3) enable feature by default

          Javier Fernandez

          The protocol handler work is not implemented in https://chromium-review.googlesource.com/c/chromium/src/+/7156864

          In this CL only the extension dialog related changes remain.

          The change that enabled the feature was a mistake and has been removed now.

          Emilia Paz . resolved

          Thanks Javier! Dialog construction looks good to me. There are some build errors though:
          (a) `//chrome/browser/custom_handlers/chrome_protocol_handler_navigation_throttle.cc` needs access to `chrome/browser/ui/extensions/extensions_dialogs.h`
          (b) Using views::View on Android included on components/custom_handlers/BUILD.gn

          Javier Fernandez

          Adding the "chrome/browser/ui/extensions:extensions" dep creates a cycle that deserves its own CL to solve it.

          File-level comment, Patchset 23 (Latest):
          Javier Fernandez . resolved

          Please @emiliapaz could you please take another look at the Extension Dialog related changes ? The translation are still pending, but I'd like to get an agreement regarding the dialog and the text messages before sending the screenshots.

          Open in Gerrit

          Related details

          Attention is currently required from:
          • Emilia Paz
          • Javier Fernandez
          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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
          Gerrit-Change-Number: 7031939
          Gerrit-PatchSet: 23
          Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
          Gerrit-Reviewer: Emilia Paz <emil...@chromium.org>
          Gerrit-Reviewer: Javier Fernandez <jfern...@igalia.com>
          Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
          Gerrit-CC: Peter Beverloo <pe...@chromium.org>
          Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
          Gerrit-Attention: Emilia Paz <emil...@chromium.org>
          Gerrit-Attention: Javier Fernandez <jfern...@igalia.com>
          Gerrit-Comment-Date: Wed, 19 Nov 2025 08:22:54 +0000
          Gerrit-HasComments: Yes
          Gerrit-Has-Labels: Yes
          satisfied_requirement
          unsatisfied_requirement
          open
          diffy

          Emilia Paz (Gerrit)

          unread,
          Nov 20, 2025, 12:38:07 PMNov 20
          to Javier Fernandez, Chromium LUCI CQ, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
          Attention needed from Javier Fernandez

          Emilia Paz voted and added 4 comments

          Votes added by Emilia Paz

          Code-Review+1

          4 comments

          Patchset-level comments
          File-level comment, Patchset 23 (Latest):
          Emilia Paz . resolved

          Thanks Javier! c/b/ui/extensions lgtm. You are going to need [translation screenshots](https://chromium.googlesource.com/chromium/src/+/lkgr/docs/translation_screenshots.md) for the new strings. Unfortunately, this can only be done by a Googler. If you provide them on the description, I can help (although I'll be OOO until Nov 30 -- so may need to ask another reviewer)

          Commit Message
          Line 18, Patchset 23 (Latest):
          Emilia Paz . unresolved

          recommendation: for UI changes, it's nice to add a screenshot to make sure it looks as intended and for future reference

          File chrome/browser/ui/extensions/BUILD.gn
          Line 132, Patchset 23 (Latest): "confirm_protocol_handler_dialog.cc",
          Emilia Paz . unresolved

          lets move this to line 168. `enable_extensions` is used for non desktop android

          File tools/metrics/actions/actions.xml
          Line 9302, Patchset 23 (Latest):<action name="ConfirmProtocolHandler.Infobar_Accept">
          <owner>Please list the metric's owners. Add more owner tags as needed.</owner>
          <description>Please enter the description of the metric.</description>
          </action>

          <action name="ConfirmProtocolHandler.InfoBar_Deny">
          <owner>Please list the metric's owners. Add more owner tags as needed.</owner>
          <description>Please enter the description of the metric.</description>
          </action>
          Emilia Paz . unresolved

          This is not used on this CL. Remove?

          Open in Gerrit

          Related details

          Attention is currently required from:
          • Javier Fernandez
          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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
            Gerrit-Change-Number: 7031939
            Gerrit-PatchSet: 23
            Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
            Gerrit-Reviewer: Emilia Paz <emil...@chromium.org>
            Gerrit-Reviewer: Javier Fernandez <jfern...@igalia.com>
            Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
            Gerrit-CC: Peter Beverloo <pe...@chromium.org>
            Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
            Gerrit-Attention: Javier Fernandez <jfern...@igalia.com>
            Gerrit-Comment-Date: Thu, 20 Nov 2025 17:37:58 +0000
            Gerrit-HasComments: Yes
            Gerrit-Has-Labels: Yes
            satisfied_requirement
            unsatisfied_requirement
            open
            diffy

            Javier Fernandez (Gerrit)

            unread,
            Nov 24, 2025, 5:02:56 PMNov 24
            to Emilia Paz, Chromium LUCI CQ, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
            Attention needed from Emilia Paz

            Javier Fernandez added 2 comments

            File chrome/browser/ui/extensions/BUILD.gn
            Line 132, Patchset 23: "confirm_protocol_handler_dialog.cc",
            Emilia Paz . resolved

            lets move this to line 168. `enable_extensions` is used for non desktop android

            Javier Fernandez

            Done

            File tools/metrics/actions/actions.xml
            Line 9302, Patchset 23:<action name="ConfirmProtocolHandler.Infobar_Accept">

            <owner>Please list the metric's owners. Add more owner tags as needed.</owner>
            <description>Please enter the description of the metric.</description>
            </action>

            <action name="ConfirmProtocolHandler.InfoBar_Deny">
            <owner>Please list the metric's owners. Add more owner tags as needed.</owner>
            <description>Please enter the description of the metric.</description>
            </action>
            Emilia Paz . resolved

            This is not used on this CL. Remove?

            Javier Fernandez

            No, not any more. They were used in a previous version of this CL.
            Thanls.

            Open in Gerrit

            Related details

            Attention is currently required from:
            • Emilia Paz
            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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
              Gerrit-Change-Number: 7031939
              Gerrit-PatchSet: 24
              Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
              Gerrit-Reviewer: Emilia Paz <emil...@chromium.org>
              Gerrit-Reviewer: Javier Fernandez <jfern...@igalia.com>
              Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
              Gerrit-CC: Peter Beverloo <pe...@chromium.org>
              Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
              Gerrit-Attention: Emilia Paz <emil...@chromium.org>
              Gerrit-Comment-Date: Mon, 24 Nov 2025 22:02:32 +0000
              satisfied_requirement
              unsatisfied_requirement
              open
              diffy

              Javier Fernandez (Gerrit)

              unread,
              Nov 26, 2025, 6:47:09 PMNov 26
              to Devlin Cronin, Chromium LUCI CQ, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
              Attention needed from Devlin Cronin

              Javier Fernandez added 1 comment

              Patchset-level comments
              File-level comment, Patchset 24 (Latest):
              Javier Fernandez . resolved

              Hi @rdevlin.cronin

              Emilia already reviewed the UI logic of the the new prompt dialog.
              Could you please do a final review ?
              Thanks.

              Open in Gerrit

              Related details

              Attention is currently required from:
              • Devlin Cronin
              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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
              Gerrit-Change-Number: 7031939
              Gerrit-PatchSet: 24
              Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
              Gerrit-Reviewer: Devlin Cronin <rdevlin...@chromium.org>
              Gerrit-Reviewer: Javier Fernandez <jfern...@igalia.com>
              Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
              Gerrit-CC: Peter Beverloo <pe...@chromium.org>
              Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
              Gerrit-Attention: Devlin Cronin <rdevlin...@chromium.org>
              Gerrit-Comment-Date: Wed, 26 Nov 2025 23:46:49 +0000
              Gerrit-HasComments: Yes
              Gerrit-Has-Labels: No
              satisfied_requirement
              unsatisfied_requirement
              open
              diffy

              Devlin Cronin (Gerrit)

              unread,
              Dec 8, 2025, 6:42:43 PM (11 days ago) Dec 8
              to Javier Fernandez, Devlin Cronin, Chromium LUCI CQ, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
              Attention needed from Javier Fernandez

              Devlin Cronin added 8 comments

              Patchset-level comments
              Devlin Cronin . unresolved

              Thanks, Javier! This generally looks pretty good. A few notes:

              • In general, it's best to not remove reviewers after they've reviewed (Gerrit removed Emilia's +1 since she's no longer a reviewer).
              • You'll still need a custom_handlers owner for these
              • Can we add tests? : )
              File chrome/browser/custom_handlers/chrome_protocol_handler_navigation_throttle.h
              Line 27, Patchset 24 (Latest): content::NavigationThrottleRegistry&,
              Devlin Cronin . unresolved

              nit: please name these (and below)

              Line 26, Patchset 24 (Latest): explicit ChromeProtocolHandlerNavigationThrottle(
              Devlin Cronin . unresolved

              nit: no need for `explicit` with multi-param ctors

              Line 23, Patchset 24 (Latest):class ChromeProtocolHandlerNavigationThrottle
              Devlin Cronin . unresolved

              nit: add a top-level comment describing what the class does

              File chrome/browser/custom_handlers/chrome_protocol_handler_navigation_throttle.cc
              Line 23, Patchset 24 (Latest): ProtocolHandlerRegistry* protocol_handler_registry,
              Devlin Cronin . unresolved

              nit: #include protocol handler registry

              File chrome/browser/ui/extensions/confirm_protocol_handler_dialog.cc
              Line 47, Patchset 24 (Latest): *handler.extension_id(), ExtensionRegistry::EVERYTHING);
              Devlin Cronin . unresolved

              should we also know at this point that the extension is enabled? (Would we ever show this for a disabled extension?)

              Line 60, Patchset 24 (Latest): base::OnceCallback<void(bool, bool)> callback)
              Devlin Cronin . unresolved

              nit: let's make this type an alias (we use it twice) and also document what the arguments are

              File components/protocol_handler_strings.grdp
              Line 36, Patchset 24 (Latest): Confirm protocol handler.
              Devlin Cronin . unresolved

              Have we consulted with the UX team at all, or do these mirror existing strings? I don't think we normally expose "protocol handler" as a concept to users, since it's pretty niche

              Open in Gerrit

              Related details

              Attention is currently required from:
              • Javier Fernandez
              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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
              Gerrit-Change-Number: 7031939
              Gerrit-PatchSet: 24
              Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
              Gerrit-Reviewer: Devlin Cronin <rdevlin...@chromium.org>
              Gerrit-Reviewer: Javier Fernandez <jfern...@igalia.com>
              Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
              Gerrit-CC: Peter Beverloo <pe...@chromium.org>
              Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
              Gerrit-Attention: Javier Fernandez <jfern...@igalia.com>
              Gerrit-Comment-Date: Mon, 08 Dec 2025 23:42:30 +0000
              Gerrit-HasComments: Yes
              Gerrit-Has-Labels: No
              satisfied_requirement
              unsatisfied_requirement
              open
              diffy

              Javier Fernandez (Gerrit)

              unread,
              Dec 9, 2025, 6:09:05 PM (10 days ago) Dec 9
              to Emilia Paz, Devlin Cronin, Chromium LUCI CQ, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
              Attention needed from Devlin Cronin and Emilia Paz

              Javier Fernandez added 9 comments

              Patchset-level comments
              Devlin Cronin . unresolved

              Thanks, Javier! This generally looks pretty good. A few notes:

              • In general, it's best to not remove reviewers after they've reviewed (Gerrit removed Emilia's +1 since she's no longer a reviewer).
              • You'll still need a custom_handlers owner for these
              • Can we add tests? : )
              Javier Fernandez

              Regarding the custom_handlers owner, I asked Solomon to review the CL with the NavigationThrottle logic, mainly because he has the context about the new extension feature being implemented here; I use to ask Colin Blundell for rubber-stamping these changes latter. I may do the same in this case.

              Regarding the tests, could you point me to an example of the kind of interactive tests these prompt dialog would need ? Perhaps it's a good opportunity to add Emilia again into the review loop.

              File-level comment, Patchset 25 (Latest):
              Javier Fernandez . resolved

              Thanks @rdevlin.cronin for the reviews.
              @emiliapaz, could you please point me an example of the kind of interactive tests these dialogs need ? Thanks.

              File chrome/browser/custom_handlers/chrome_protocol_handler_navigation_throttle.h
              Line 27, Patchset 24: content::NavigationThrottleRegistry&,
              Devlin Cronin . resolved

              nit: please name these (and below)

              Javier Fernandez

              Done

              Line 26, Patchset 24: explicit ChromeProtocolHandlerNavigationThrottle(
              Devlin Cronin . resolved

              nit: no need for `explicit` with multi-param ctors

              Javier Fernandez

              Done

              Line 23, Patchset 24:class ChromeProtocolHandlerNavigationThrottle
              Devlin Cronin . resolved

              nit: add a top-level comment describing what the class does

              Javier Fernandez

              Done

              File chrome/browser/custom_handlers/chrome_protocol_handler_navigation_throttle.cc
              Line 23, Patchset 24: ProtocolHandlerRegistry* protocol_handler_registry,
              Devlin Cronin . resolved

              nit: #include protocol handler registry

              Javier Fernandez

              Done

              File chrome/browser/ui/extensions/confirm_protocol_handler_dialog.cc
              Line 47, Patchset 24: *handler.extension_id(), ExtensionRegistry::EVERYTHING);
              Devlin Cronin . resolved

              should we also know at this point that the extension is enabled? (Would we ever show this for a disabled extension?)

              Javier Fernandez

              Yes, the protocol handler that is only in the registry if the extension is enabled. Hence, while running the prompt dialog we can assume that the extension id corresponds to an enabled extension, indeed.

              Line 60, Patchset 24: base::OnceCallback<void(bool, bool)> callback)
              Devlin Cronin . resolved

              nit: let's make this type an alias (we use it twice) and also document what the arguments are

              Javier Fernandez

              Done

              File components/protocol_handler_strings.grdp
              Line 36, Patchset 24: Confirm protocol handler.
              Devlin Cronin . unresolved

              Have we consulted with the UX team at all, or do these mirror existing strings? I don't think we normally expose "protocol handler" as a concept to users, since it's pretty niche

              Javier Fernandez

              I haven't consulted the UX team, and perhaps we should, indeed, even though these strings are used in the Web API (via the registerProtocolHandler JS method) when the user is prompt to grant the registration of a protocol handler.

              https://source.chromium.org/chromium/chromium/src/+/main:components/custom_handlers/register_protocol_handler_permission_request.cc;l=60;drc=c1b102f35ec290df46da5093c2ab90d6616134c6

              I agree that the protocol handlers concept is kind of niches, but it's already used as I said before. My main doubt is whether the sentence is clear enough for the user and whether it should be rephrased in a different way. I really wanted to check with someone before sending the PNGs for the translation.

              Open in Gerrit

              Related details

              Attention is currently required from:
              • Devlin Cronin
              • Emilia Paz
              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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
              Gerrit-Change-Number: 7031939
              Gerrit-PatchSet: 25
              Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
              Gerrit-Reviewer: Devlin Cronin <rdevlin...@chromium.org>
              Gerrit-Reviewer: Emilia Paz <emil...@chromium.org>
              Gerrit-Reviewer: Javier Fernandez <jfern...@igalia.com>
              Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
              Gerrit-CC: Peter Beverloo <pe...@chromium.org>
              Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
              Gerrit-Attention: Devlin Cronin <rdevlin...@chromium.org>
              Gerrit-Attention: Emilia Paz <emil...@chromium.org>
              Gerrit-Comment-Date: Tue, 09 Dec 2025 23:08:46 +0000
              Gerrit-HasComments: Yes
              Gerrit-Has-Labels: No
              Comment-In-Reply-To: Devlin Cronin <rdevlin...@chromium.org>
              satisfied_requirement
              unsatisfied_requirement
              open
              diffy

              Emilia Paz (Gerrit)

              unread,
              Dec 10, 2025, 1:24:09 PM (10 days ago) Dec 10
              to Javier Fernandez, Devlin Cronin, Chromium LUCI CQ, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
              Attention needed from Devlin Cronin and Javier Fernandez

              Emilia Paz added 1 comment

              Patchset-level comments
              Devlin Cronin . unresolved

              Thanks, Javier! This generally looks pretty good. A few notes:

              • In general, it's best to not remove reviewers after they've reviewed (Gerrit removed Emilia's +1 since she's no longer a reviewer).
              • You'll still need a custom_handlers owner for these
              • Can we add tests? : )
              Javier Fernandez

              Regarding the custom_handlers owner, I asked Solomon to review the CL with the NavigationThrottle logic, mainly because he has the context about the new extension feature being implemented here; I use to ask Colin Blundell for rubber-stamping these changes latter. I may do the same in this case.

              Regarding the tests, could you point me to an example of the kind of interactive tests these prompt dialog would need ? Perhaps it's a good opportunity to add Emilia again into the review loop.

              Attention is currently required from:
              • Devlin Cronin
              • Javier Fernandez
              Gerrit-Attention: Javier Fernandez <jfern...@igalia.com>
              Gerrit-Comment-Date: Wed, 10 Dec 2025 18:23:59 +0000
              Gerrit-HasComments: Yes
              Gerrit-Has-Labels: No
              Comment-In-Reply-To: Devlin Cronin <rdevlin...@chromium.org>
              Comment-In-Reply-To: Javier Fernandez <jfern...@igalia.com>
              satisfied_requirement
              unsatisfied_requirement
              open
              diffy

              Devlin Cronin (Gerrit)

              unread,
              Dec 12, 2025, 2:08:56 PM (8 days ago) Dec 12
              to Javier Fernandez, Devlin Cronin, Chromium LUCI CQ, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
              Attention needed from Javier Fernandez

              Devlin Cronin added 2 comments

              Patchset-level comments
              File-level comment, Patchset 25 (Latest):
              Devlin Cronin . resolved

              (just responding)

              File components/protocol_handler_strings.grdp
              Line 36, Patchset 24: Confirm protocol handler.
              Devlin Cronin . unresolved

              Have we consulted with the UX team at all, or do these mirror existing strings? I don't think we normally expose "protocol handler" as a concept to users, since it's pretty niche

              Javier Fernandez

              I haven't consulted the UX team, and perhaps we should, indeed, even though these strings are used in the Web API (via the registerProtocolHandler JS method) when the user is prompt to grant the registration of a protocol handler.

              https://source.chromium.org/chromium/chromium/src/+/main:components/custom_handlers/register_protocol_handler_permission_request.cc;l=60;drc=c1b102f35ec290df46da5093c2ab90d6616134c6

              I agree that the protocol handlers concept is kind of niches, but it's already used as I said before. My main doubt is whether the sentence is clear enough for the user and whether it should be rephrased in a different way. I really wanted to check with someone before sending the PNGs for the translation.

              Devlin Cronin

              I'm not sure I'm looking at the right strings. The one I see at the link you pasted is IDS_REGISTER_PROTOCOL_HANDLER_CONFIRM_FRAGMENT, which corresponds to [this string](https://source.chromium.org/chromium/chromium/src/+/main:components/protocol_handler_strings.grdp;l=20-22;drc=b1060a61978fdff6cc40a11e387ded44e8e108b4):

                  Open <ph name="PROTOCOL">$1<ex>search</ex></ph> links

              Which would be, e.g. "Open search links" (or "open web+burger links", since apparently that's an example [we like](https://developer.mozilla.org/en-US/docs/Web/API/Navigator/registerProtocolHandler#registering_a_handler_for_a_custom_protocol). That phrasing is much more inline with what I'd expect -- "open these links" rather than "registered a custom handler for this scheme".

              Maybe "The extension <name> would like to open <protocol> links", to match that? Or something similar? (Relatedly, mind including a screenshot in the CL description? I know there's one in the doc, but it's a bit buried)

              Open in Gerrit

              Related details

              Attention is currently required from:
              • Javier Fernandez
              Gerrit-Attention: Javier Fernandez <jfern...@igalia.com>
              Gerrit-Comment-Date: Fri, 12 Dec 2025 19:08:46 +0000
              satisfied_requirement
              unsatisfied_requirement
              open
              diffy

              Javier Fernandez (Gerrit)

              unread,
              Dec 17, 2025, 7:46:03 PM (2 days ago) Dec 17
              to Emilia Paz, Devlin Cronin, Chromium LUCI CQ, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
              Attention needed from Devlin Cronin and Emilia Paz

              Javier Fernandez voted and added 4 comments

              Votes added by Javier Fernandez

              Commit-Queue+1

              4 comments

              Patchset-level comments
              File-level comment, Patchset 24:
              Devlin Cronin . resolved

              Thanks, Javier! This generally looks pretty good. A few notes:

              • In general, it's best to not remove reviewers after they've reviewed (Gerrit removed Emilia's +1 since she's no longer a reviewer).
              • You'll still need a custom_handlers owner for these
              • Can we add tests? : )
              Javier Fernandez

              Regarding the custom_handlers owner, I asked Solomon to review the CL with the NavigationThrottle logic, mainly because he has the context about the new extension feature being implemented here; I use to ask Colin Blundell for rubber-stamping these changes latter. I may do the same in this case.

              Regarding the tests, could you point me to an example of the kind of interactive tests these prompt dialog would need ? Perhaps it's a good opportunity to add Emilia again into the review loop.

              Emilia Paz

              `InteractiveBrowserTest` is the best way to test dialogs interactively. For example:
              https://source.chromium.org/chromium/chromium/src/+/main:chrome/browser/ui/extensions/controlled_home_dialog_interactive_uitest.cc
              https://source.chromium.org/chromium/chromium/src/+/main:chrome/browser/ui/views/extensions/dialogs/extension_install_friction_dialog_interactive_uitest.cc?q=InteractiveBrowserTest&ss=chromium%2Fchromium%2Fsrc:chrome%2Fbrowser%2Fui%2Fviews%2Fextensions%2F

              Javier Fernandez

              Done

              File-level comment, Patchset 31 (Latest):
              Javier Fernandez . resolved

              Thanks for the reviews, Emilia and Devlin.

              I've updated the strings and added a few UI interaction tests.
              Could you please both take another look ?
              Thanks.

              Commit Message
              Line 18, Patchset 23:
              Emilia Paz . resolved

              recommendation: for UI changes, it's nice to add a screenshot to make sure it looks as intended and for future reference

              Javier Fernandez

              Done

              File components/protocol_handler_strings.grdp
              Line 36, Patchset 24: Confirm protocol handler.
              Devlin Cronin . unresolved

              Have we consulted with the UX team at all, or do these mirror existing strings? I don't think we normally expose "protocol handler" as a concept to users, since it's pretty niche

              Javier Fernandez

              I haven't consulted the UX team, and perhaps we should, indeed, even though these strings are used in the Web API (via the registerProtocolHandler JS method) when the user is prompt to grant the registration of a protocol handler.

              https://source.chromium.org/chromium/chromium/src/+/main:components/custom_handlers/register_protocol_handler_permission_request.cc;l=60;drc=c1b102f35ec290df46da5093c2ab90d6616134c6

              I agree that the protocol handlers concept is kind of niches, but it's already used as I said before. My main doubt is whether the sentence is clear enough for the user and whether it should be rephrased in a different way. I really wanted to check with someone before sending the PNGs for the translation.

              Devlin Cronin

              I'm not sure I'm looking at the right strings. The one I see at the link you pasted is IDS_REGISTER_PROTOCOL_HANDLER_CONFIRM_FRAGMENT, which corresponds to [this string](https://source.chromium.org/chromium/chromium/src/+/main:components/protocol_handler_strings.grdp;l=20-22;drc=b1060a61978fdff6cc40a11e387ded44e8e108b4):

                  Open <ph name="PROTOCOL">$1<ex>search</ex></ph> links

              Which would be, e.g. "Open search links" (or "open web+burger links", since apparently that's an example [we like](https://developer.mozilla.org/en-US/docs/Web/API/Navigator/registerProtocolHandler#registering_a_handler_for_a_custom_protocol). That phrasing is much more inline with what I'd expect -- "open these links" rather than "registered a custom handler for this scheme".

              Maybe "The extension <name> would like to open <protocol> links", to match that? Or something similar? (Relatedly, mind including a screenshot in the CL description? I know there's one in the doc, but it's a bit buried)

              Javier Fernandez

              Ah, yeah, I know what you mean now; the protocol handler is only mentioned in the description of those IDs, but the UI message just mention the intention to open links with "special" schemes, indeed.

              I've reworded the IDs to match those examples, but mentioning the extension that owns the protocol handler.

              Also, as requested, I've added a link in the CL description to the screenshot of the new dialog.

              Open in Gerrit

              Related details

              Attention is currently required from:
              • Devlin Cronin
              • Emilia Paz
              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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
              Gerrit-Change-Number: 7031939
              Gerrit-PatchSet: 31
              Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
              Gerrit-Reviewer: Devlin Cronin <rdevlin...@chromium.org>
              Gerrit-Reviewer: Emilia Paz <emil...@chromium.org>
              Gerrit-Reviewer: Javier Fernandez <jfern...@igalia.com>
              Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
              Gerrit-CC: Peter Beverloo <pe...@chromium.org>
              Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
              Gerrit-Attention: Devlin Cronin <rdevlin...@chromium.org>
              Gerrit-Attention: Emilia Paz <emil...@chromium.org>
              Gerrit-Comment-Date: Thu, 18 Dec 2025 00:45:44 +0000
              Gerrit-HasComments: Yes
              Gerrit-Has-Labels: Yes
              Comment-In-Reply-To: Devlin Cronin <rdevlin...@chromium.org>
              satisfied_requirement
              unsatisfied_requirement
              open
              diffy

              Devlin Cronin (Gerrit)

              unread,
              Dec 18, 2025, 2:12:47 PM (2 days ago) Dec 18
              to Javier Fernandez, Devlin Cronin, Emilia Paz, Chromium LUCI CQ, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
              Attention needed from Emilia Paz and Javier Fernandez

              Devlin Cronin voted and added 2 comments

              Votes added by Devlin Cronin

              Code-Review+1

              2 comments

              Patchset-level comments
              File-level comment, Patchset 31 (Latest):
              Devlin Cronin . resolved

              Thanks, Javier! High-level LGTM. Please wait for Emilia to take another pass at the UI code and the tests before landing.

              File components/protocol_handler_strings.grdp
              Line 36, Patchset 24: Confirm protocol handler.
              Devlin Cronin . resolved

              Have we consulted with the UX team at all, or do these mirror existing strings? I don't think we normally expose "protocol handler" as a concept to users, since it's pretty niche

              Javier Fernandez

              I haven't consulted the UX team, and perhaps we should, indeed, even though these strings are used in the Web API (via the registerProtocolHandler JS method) when the user is prompt to grant the registration of a protocol handler.

              https://source.chromium.org/chromium/chromium/src/+/main:components/custom_handlers/register_protocol_handler_permission_request.cc;l=60;drc=c1b102f35ec290df46da5093c2ab90d6616134c6

              I agree that the protocol handlers concept is kind of niches, but it's already used as I said before. My main doubt is whether the sentence is clear enough for the user and whether it should be rephrased in a different way. I really wanted to check with someone before sending the PNGs for the translation.

              Devlin Cronin

              I'm not sure I'm looking at the right strings. The one I see at the link you pasted is IDS_REGISTER_PROTOCOL_HANDLER_CONFIRM_FRAGMENT, which corresponds to [this string](https://source.chromium.org/chromium/chromium/src/+/main:components/protocol_handler_strings.grdp;l=20-22;drc=b1060a61978fdff6cc40a11e387ded44e8e108b4):

                  Open <ph name="PROTOCOL">$1<ex>search</ex></ph> links

              Which would be, e.g. "Open search links" (or "open web+burger links", since apparently that's an example [we like](https://developer.mozilla.org/en-US/docs/Web/API/Navigator/registerProtocolHandler#registering_a_handler_for_a_custom_protocol). That phrasing is much more inline with what I'd expect -- "open these links" rather than "registered a custom handler for this scheme".

              Maybe "The extension <name> would like to open <protocol> links", to match that? Or something similar? (Relatedly, mind including a screenshot in the CL description? I know there's one in the doc, but it's a bit buried)

              Javier Fernandez

              Ah, yeah, I know what you mean now; the protocol handler is only mentioned in the description of those IDs, but the UI message just mention the intention to open links with "special" schemes, indeed.

              I've reworded the IDs to match those examples, but mentioning the extension that owns the protocol handler.

              Also, as requested, I've added a link in the CL description to the screenshot of the new dialog.

              Devlin Cronin

              Thank you! This looks much better : )

              Open in Gerrit

              Related details

              Attention is currently required from:
              • Emilia Paz
              • Javier Fernandez
              Submit Requirements:
                • requirement satisfiedCode-Coverage
                • requirement is not 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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
                Gerrit-Change-Number: 7031939
                Gerrit-PatchSet: 31
                Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
                Gerrit-Reviewer: Devlin Cronin <rdevlin...@chromium.org>
                Gerrit-Reviewer: Emilia Paz <emil...@chromium.org>
                Gerrit-Reviewer: Javier Fernandez <jfern...@igalia.com>
                Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
                Gerrit-CC: Peter Beverloo <pe...@chromium.org>
                Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
                Gerrit-Attention: Emilia Paz <emil...@chromium.org>
                Gerrit-Attention: Javier Fernandez <jfern...@igalia.com>
                Gerrit-Comment-Date: Thu, 18 Dec 2025 19:12:32 +0000
                Gerrit-HasComments: Yes
                Gerrit-Has-Labels: Yes
                Comment-In-Reply-To: Devlin Cronin <rdevlin...@chromium.org>
                Comment-In-Reply-To: Javier Fernandez <jfern...@igalia.com>
                satisfied_requirement
                unsatisfied_requirement
                open
                diffy

                Emilia Paz (Gerrit)

                unread,
                Dec 18, 2025, 4:13:47 PM (2 days ago) Dec 18
                to Javier Fernandez, Devlin Cronin, Chromium LUCI CQ, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
                Attention needed from Javier Fernandez

                Emilia Paz added 10 comments

                Patchset-level comments
                Emilia Paz . resolved

                Thanks Javier! Overall LGTM, just a couple suggestions. If you update the screenshot in the description, I can generate the screenshot files for the CL

                File chrome/browser/ui/extensions/confirm_protocol_handler_dialog.cc
                Line 82, Patchset 31 (Latest): bool remember = dialog_model()
                ->GetCheckboxByUniqueId(kRememberMeCheckbox)
                ->is_checked();

                std::move(callback_).Run(false, remember);
                Emilia Paz . unresolved

                As a user, I would expect clicking on 'Cancel' to not have any effect.
                However, here we are passing back `remember`. Does that mean it will be allowed?

                Edit: after looking at components/custom_handlers/protocol_handler_navigation_throttle.cc, `remember` is not used when cancel is selected. However, this is not clear from here. What about:
                (a) Have different callbacks for accept and cancel. That way we don't need to pass back a boolean for that, and `remember` is only passed to the accept callback
                or
                (b) `OnDialogCancelled` returns `false` for `remember`, with a comment that explains why.
                Leaning towards (a) because it makes the calls easier to understand.

                File chrome/browser/ui/extensions/extensions_dialogs.h
                Line 61, Patchset 31 (Latest):DECLARE_ELEMENT_IDENTIFIER_VALUE(kRememberMeCheckbox);
                Emilia Paz . unresolved

                Let's add which dialog this belongs to, so it's not used by mistake on another dialog

                File chrome/browser/ui/views/extensions/dialogs/confirm_protocol_handler_dialog_interactive_uitest.cc
                Line 55, Patchset 31 (Latest): constexpr const char extension_manifest[] =
                R"({
                "name": "An Extension",
                "version": "1",
                "manifest_version": 3
                })";
                extensions::TestExtensionDir extension_dir;
                extension_dir.WriteManifest(extension_manifest);

                extensions::ChromeTestExtensionLoader extension_loader(profile);
                extension_loader.set_ignore_manifest_warnings(true);
                last_loaded_extension_id_ =
                extension_loader.LoadExtension(extension_dir.Pack())->id();
                Emilia Paz . unresolved
                nit: an easier way to install an extension is with the `ExtensionBuilder`
                ```
                scoped_refptr<const extensions::Extension> extension =
                extensions::ExtensionBuilder(extension_name)
                .Build();

                extension_registrar()->AddExtension(extension);
                ```
                unless load triggers something differently?

                Line 111, Patchset 31 (Latest):// invokescalls the callback with (granted=true, remember=true) and then closes
                Emilia Paz . unresolved

                Typo here, "invokescalls" should probably be "invokes" or "calls".

                Line 130, Patchset 31 (Latest):// Pressing the 'Deby' button invokes the callback with (granted=false,
                Emilia Paz . unresolved

                Typo: 'Deby' should be 'Deny'. Although, maybe change it to 'cancel' since that's the buton text and name?

                File components/custom_handlers/protocol_handler_navigation_throttle.cc
                Line 100, Patchset 31 (Latest): this, web_contents, handler, url,
                Emilia Paz . unresolved

                I think this could cause a crash: because PostTask is asynchronous, the NavigationThrottle might be destroyed (e.g., the user closes the tab) before the task runs. When the task finally runs, it could try to access this, causing a crash. We can use a weak ptr and check whether the throttle exists.

                Line 108, Patchset 31 (Latest): FROM_HERE, base::BindOnce(std::move(launch_callback)));
                Emilia Paz . unresolved

                hmm we have a double bind here. We may be able to avoid this by restructuring this method:

                ```
                ProtocolHandlerConfirmCallback permission_decided_callback =
                base::BindOnce(
                &ProtocolHandlerNavigationThrottle::OnProtocolHandlerPermissionDecided,
                weak_factory_.GetWeakPtr(), url);
                base::SingleThreadTaskRunner::GetCurrentDefault()->PostTask(
                FROM_HERE,
                base::BindOnce(
                [](...) {
                // Ensure the throttle still exists.
                if (!throttle)
                return;
                ...
                },
                weak_factory_.GetWeakPtr(), web_contents, handler, url,
                std::move(permission_decided_callback)));
                ```
                File components/protocol_handler_strings.grdp
                Line 36, Patchset 31 (Latest): The extension "<ph name="EXTENSION_NAME">$1<ex>Google Translate</ex></ph>" wants to
                Emilia Paz . unresolved

                I would change this to "<extension name>" wants to open <protocol> links through <host name>" to match other dialog strings like:

                • IDS_EXTENSIONS_PRINTING_API_PRINT_REQUEST_BUBBLE_HEADING
                • IDS_EXTENSIONS_DOCUMENT_SCAN_API_DISCOVERY_REQUEST_BUBBLE_HEADING

                It can be either the title, or have it be the description and a simpler title like "Open <protocol> links"

                And for the checkbox, checking it means "always allow" versus just "allow"? If so, I would change it to "Always allow <hot name> to open <protocol> links"

                In summary, options:

                (a)
                Title: "<extension name>" wants to open <protocol> links through <host name>
                Checkbox: Always allow <hot name> to open <protocol> links

                (b)
                Title: Open <protocol> links?
                Description: "<extension name>" wants to open <protocol> links through <host name>
                Checkbox: Always allow <hot name> to open <protocol> links

                Line 41, Patchset 31 (Latest): <message name="IDS_CONFIRM_PROTOCOL_HANDLER_MESSAGE_WITH_INITIATING_ORIGIN" desc="Warn the user about the navigation request rediction for a known initiator origin.">
                Emilia Paz . unresolved

                Typo: 'rediction' should be 'redirection'.

                Open in Gerrit

                Related details

                Attention is currently required from:
                • Javier Fernandez
                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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
                  Gerrit-Change-Number: 7031939
                  Gerrit-PatchSet: 31
                  Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
                  Gerrit-Reviewer: Devlin Cronin <rdevlin...@chromium.org>
                  Gerrit-Reviewer: Emilia Paz <emil...@chromium.org>
                  Gerrit-Reviewer: Javier Fernandez <jfern...@igalia.com>
                  Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
                  Gerrit-CC: Peter Beverloo <pe...@chromium.org>
                  Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
                  Gerrit-Attention: Javier Fernandez <jfern...@igalia.com>
                  Gerrit-Comment-Date: Thu, 18 Dec 2025 21:13:34 +0000
                  Gerrit-HasComments: Yes
                  Gerrit-Has-Labels: No
                  satisfied_requirement
                  unsatisfied_requirement
                  open
                  diffy

                  Javier Fernandez (Gerrit)

                  unread,
                  Dec 18, 2025, 8:52:22 PM (2 days ago) Dec 18
                  to Devlin Cronin, Emilia Paz, Chromium LUCI CQ, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
                  Attention needed from Devlin Cronin and Emilia Paz

                  Javier Fernandez added 9 comments

                  Patchset-level comments
                  File-level comment, Patchset 32 (Latest):
                  Javier Fernandez . resolved

                  Thank you Emilia for the review.
                  I have applied most of the changes, but left some questions inline.

                  File chrome/browser/ui/extensions/confirm_protocol_handler_dialog.cc
                  Line 82, Patchset 31: bool remember = dialog_model()

                  ->GetCheckboxByUniqueId(kRememberMeCheckbox)
                  ->is_checked();

                  std::move(callback_).Run(false, remember);
                  Emilia Paz . resolved

                  As a user, I would expect clicking on 'Cancel' to not have any effect.
                  However, here we are passing back `remember`. Does that mean it will be allowed?

                  Edit: after looking at components/custom_handlers/protocol_handler_navigation_throttle.cc, `remember` is not used when cancel is selected. However, this is not clear from here. What about:
                  (a) Have different callbacks for accept and cancel. That way we don't need to pass back a boolean for that, and `remember` is only passed to the accept callback
                  or
                  (b) `OnDialogCancelled` returns `false` for `remember`, with a comment that explains why.
                  Leaning towards (a) because it makes the calls easier to understand.

                  Javier Fernandez

                  I was tempted to implement b) because it was really simple, but I think you are right that the use of a single callback to handle the Permission's decision treats both boolean values in a very obscure way.

                  I have implemented a), although I had to update more files; I think it's much clearer now. Thanks for the suggestion,

                  File chrome/browser/ui/extensions/extensions_dialogs.h
                  Line 61, Patchset 31:DECLARE_ELEMENT_IDENTIFIER_VALUE(kRememberMeCheckbox);
                  Emilia Paz . resolved

                  Let's add which dialog this belongs to, so it's not used by mistake on another dialog

                  Javier Fernandez

                  Done

                  File chrome/browser/ui/views/extensions/dialogs/confirm_protocol_handler_dialog_interactive_uitest.cc
                  Line 55, Patchset 31: constexpr const char extension_manifest[] =

                  R"({
                  "name": "An Extension",
                  "version": "1",
                  "manifest_version": 3
                  })";
                  extensions::TestExtensionDir extension_dir;
                  extension_dir.WriteManifest(extension_manifest);

                  extensions::ChromeTestExtensionLoader extension_loader(profile);
                  extension_loader.set_ignore_manifest_warnings(true);
                  last_loaded_extension_id_ =
                  extension_loader.LoadExtension(extension_dir.Pack())->id();
                  Emilia Paz . resolved
                  nit: an easier way to install an extension is with the `ExtensionBuilder`
                  ```
                  scoped_refptr<const extensions::Extension> extension =
                  extensions::ExtensionBuilder(extension_name)
                  .Build();

                  extension_registrar()->AddExtension(extension);
                  ```
                  unless load triggers something differently?

                  Javier Fernandez

                  Nice suggestion !
                  Thanks,

                  Line 111, Patchset 31:// invokescalls the callback with (granted=true, remember=true) and then closes
                  Emilia Paz . resolved

                  Typo here, "invokescalls" should probably be "invokes" or "calls".

                  Javier Fernandez

                  Done

                  Line 130, Patchset 31:// Pressing the 'Deby' button invokes the callback with (granted=false,
                  Emilia Paz . resolved

                  Typo: 'Deby' should be 'Deny'. Although, maybe change it to 'cancel' since that's the buton text and name?

                  Javier Fernandez

                  Done

                  File components/custom_handlers/protocol_handler_navigation_throttle.cc
                  Line 108, Patchset 31: FROM_HERE, base::BindOnce(std::move(launch_callback)));
                  Emilia Paz . resolved

                  hmm we have a double bind here. We may be able to avoid this by restructuring this method:

                  ```
                  ProtocolHandlerConfirmCallback permission_decided_callback =
                  base::BindOnce(
                  &ProtocolHandlerNavigationThrottle::OnProtocolHandlerPermissionDecided,
                  weak_factory_.GetWeakPtr(), url);
                  base::SingleThreadTaskRunner::GetCurrentDefault()->PostTask(
                  FROM_HERE,
                  base::BindOnce(
                  [](...) {
                  // Ensure the throttle still exists.
                  if (!throttle)
                  return;
                  ...
                  },
                  weak_factory_.GetWeakPtr(), web_contents, handler, url,
                  std::move(permission_decided_callback)));
                  ```
                  Javier Fernandez

                  Done

                  File components/protocol_handler_strings.grdp
                  Line 36, Patchset 31: The extension "<ph name="EXTENSION_NAME">$1<ex>Google Translate</ex></ph>" wants to
                  Emilia Paz . unresolved

                  I would change this to "<extension name>" wants to open <protocol> links through <host name>" to match other dialog strings like:

                  • IDS_EXTENSIONS_PRINTING_API_PRINT_REQUEST_BUBBLE_HEADING
                  • IDS_EXTENSIONS_DOCUMENT_SCAN_API_DISCOVERY_REQUEST_BUBBLE_HEADING

                  It can be either the title, or have it be the description and a simpler title like "Open <protocol> links"

                  And for the checkbox, checking it means "always allow" versus just "allow"? If so, I would change it to "Always allow <hot name> to open <protocol> links"

                  In summary, options:

                  (a)
                  Title: "<extension name>" wants to open <protocol> links through <host name>
                  Checkbox: Always allow <hot name> to open <protocol> links

                  (b)
                  Title: Open <protocol> links?
                  Description: "<extension name>" wants to open <protocol> links through <host name>
                  Checkbox: Always allow <hot name> to open <protocol> links

                  Javier Fernandez

                  I think the option b) is clearer, and more similar to the PermissionRequest prompt used when registering protocol handlers using the Web API.

                  I have some doubts regarding the change in the Checkbox string. One one hand, that string is also used by the PermissionRequest prompt dialog launched when using the Web API, so this change would affect that use case as well. On the other side, the original message used the term "all" as a way to imply "always" or "from now on".

                  I don't have a strong opinion regarding the use of the "always" term, even in addition to the "all" term being used already. Is the change worth, considering it affects the Web API prompt dialog ?

                  Alternatively, I could define a new <message> item for this new dialog, although it'd be pretty similar to the one used by the Web API.

                  Line 41, Patchset 31: <message name="IDS_CONFIRM_PROTOCOL_HANDLER_MESSAGE_WITH_INITIATING_ORIGIN" desc="Warn the user about the navigation request rediction for a known initiator origin.">
                  Emilia Paz . resolved

                  Typo: 'rediction' should be 'redirection'.

                  Javier Fernandez

                  Done

                  Open in Gerrit

                  Related details

                  Attention is currently required from:
                  • Devlin Cronin
                  • Emilia Paz
                  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: Ice98f7453687d6b24c941d82ea6ad264b1de9d65
                    Gerrit-Change-Number: 7031939
                    Gerrit-PatchSet: 32
                    Gerrit-Owner: Javier Fernandez <jfern...@igalia.com>
                    Gerrit-Reviewer: Devlin Cronin <rdevlin...@chromium.org>
                    Gerrit-Reviewer: Emilia Paz <emil...@chromium.org>
                    Gerrit-Reviewer: Javier Fernandez <jfern...@igalia.com>
                    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
                    Gerrit-CC: Peter Beverloo <pe...@chromium.org>
                    Gerrit-CC: Solomon Kinard <solomo...@chromium.org>
                    Gerrit-Attention: Devlin Cronin <rdevlin...@chromium.org>
                    Gerrit-Attention: Emilia Paz <emil...@chromium.org>
                    Gerrit-Comment-Date: Fri, 19 Dec 2025 01:52:02 +0000
                    Gerrit-HasComments: Yes
                    Gerrit-Has-Labels: No
                    Comment-In-Reply-To: Emilia Paz <emil...@chromium.org>
                    satisfied_requirement
                    unsatisfied_requirement
                    open
                    diffy

                    Javier Fernandez (Gerrit)

                    unread,
                    Dec 18, 2025, 8:52:35 PM (2 days ago) Dec 18
                    to Devlin Cronin, Emilia Paz, Chromium LUCI CQ, Solomon Kinard, Chromium Metrics Reviews, AyeAye, chromium...@chromium.org, Peter Beverloo, chromium-a...@chromium.org, asvitkine...@chromium.org, extension...@chromium.org, blink-...@chromium.org, droger+w...@chromium.org, kinuko...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
                    Attention needed from Devlin Cronin and Emilia Paz

                    Javier Fernandez added 1 comment

                    File components/custom_handlers/protocol_handler_navigation_throttle.cc
                    Line 100, Patchset 31: this, web_contents, handler, url,
                    Emilia Paz . resolved

                    I think this could cause a crash: because PostTask is asynchronous, the NavigationThrottle might be destroyed (e.g., the user closes the tab) before the task runs. When the task finally runs, it could try to access this, causing a crash. We can use a weak ptr and check whether the throttle exists.

                    Javier Fernandez

                    Done

                    Gerrit-Comment-Date: Fri, 19 Dec 2025 01:52:18 +0000
                    satisfied_requirement
                    unsatisfied_requirement
                    open
                    diffy
                    Reply all
                    Reply to author
                    Forward
                    0 new messages