From 474a39d91e863ee4aeefdf20b9e04c8168ff8996 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 6 Jul 2026 03:19:23 +0000 Subject: [PATCH 1/3] Initial plan From 544b8c7ff17e0158f3f04b225c7208744f47a17e Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 6 Jul 2026 03:24:21 +0000 Subject: [PATCH 2/3] Add WAM broker recommendation to browser login success page --- .../azure/cli/core/auth/identity.py | 6 +++- .../cli/core/auth/landing_pages/success.html | 9 ++++++ .../azure/cli/core/auth/tests/test_util.py | 19 ++++++++++++- .../azure/cli/core/auth/util.py | 28 +++++++++++++++++-- 4 files changed, 58 insertions(+), 4 deletions(-) diff --git a/src/azure-cli-core/azure/cli/core/auth/identity.py b/src/azure-cli-core/azure/cli/core/auth/identity.py index 91629e89441..dc4573d1c27 100644 --- a/src/azure-cli-core/azure/cli/core/auth/identity.py +++ b/src/azure-cli-core/azure/cli/core/auth/identity.py @@ -159,7 +159,11 @@ def _prompt_launching_ui(ui=None, **_): logger.warning(WAM_PROMPT) from .util import read_response_templates - success_template, error_template = read_response_templates() + # Recommend enabling the Windows broker (WAM) on the browser login success page only when + # the broker is disabled on a WAM-capable Windows platform, i.e. the user is falling back + # to browser-based login on Windows. + show_wam_prompt = sys.platform == 'win32' and not self._enable_broker_on_windows + success_template, error_template = read_response_templates(show_wam_prompt=show_wam_prompt) # For AAD, use port 0 to let the system choose arbitrary unused ephemeral port to avoid port collision # on port 8400 from the old design. However, ADFS only allows port 8400. diff --git a/src/azure-cli-core/azure/cli/core/auth/landing_pages/success.html b/src/azure-cli-core/azure/cli/core/auth/landing_pages/success.html index a4eb5069a79..323f0a49ef6 100644 --- a/src/azure-cli-core/azure/cli/core/auth/landing_pages/success.html +++ b/src/azure-cli-core/azure/cli/core/auth/landing_pages/success.html @@ -16,10 +16,19 @@ padding: 12px 16px; margin: 8px 0px; } + + .wam-prompt { + background-color: rgb(242, 242, 242); + border-left: 4px solid rgb(0, 120, 212); + padding: 12px 16px; + margin: 16px 0px; + max-width: 640px; + }
You can close this window, or we will redirect you to the Azure CLI documentation in 1 minute.
+ {{wam_prompt}}