Skip to content

Add ENABLE_AUTH_TAB feature flag to CommonFlight, Fixes AB#3533537#2997

Draft
Copilot wants to merge 2 commits intodevfrom
copilot/add-enable-auth-tab-feature-flag
Draft

Add ENABLE_AUTH_TAB feature flag to CommonFlight, Fixes AB#3533537#2997
Copilot wants to merge 2 commits intodevfrom
copilot/add-enable-auth-tab-feature-flag

Conversation

Copy link
Contributor

Copilot AI commented Mar 4, 2026

Adds a new CommonFlight enum entry to gate Chrome 137+ AuthTab (AuthTabIntent) usage in browser-based auth flows. When enabled and the browser supports AuthTab, it replaces the standard CustomTabsIntent.

Changes

  • CommonFlight.java: Add ENABLE_AUTH_TAB("EnableAuthTab", false) with JavaDoc describing its purpose
/**
 * Flight to enable Chrome's AuthTab (AuthTabIntent) for browser-based authentication flows.
 * When enabled and the browser supports AuthTab, AuthTabIntent will be used instead of
 * the standard CustomTabsIntent for interactive authentication.
 */
ENABLE_AUTH_TAB("EnableAuthTab", false);

Flag defaults to false. Actual consumption of the flag (MSAL interactive flows, Broker Switch Browser/DUNA) is handled separately.

Original prompt

Fixes AB#3533537

Objective

Add a new ENABLE_AUTH_TAB feature flag to the CommonFlight enum in the common4j module. This flag will gate the usage of Chrome's AuthTab API (AuthTabIntent) for browser-based authentication flows. When enabled and the browser supports AuthTab, AuthTabIntent will be used instead of standard CustomTabsIntent for interactive authentication.

Target Repository

  • Repo: AzureAD/microsoft-authentication-library-common-for-android
  • Base Branch: dev
  • Module: common4j

Context

Chrome 137+ introduces AuthTab, a specialized Custom Tab designed for authentication that provides enhanced security (callback-based results instead of intent redirects), a streamlined UX, and simplified integration. This feature flag enables safe rollout across both MSAL interactive browser flows and Broker Switch Browser (DUNA) flows.

Feature Flag

This PBI creates the flag. The flag should follow the existing CommonFlight enum pattern with a default value of false.

Technical Requirements

  • Add a new enum value ENABLE_AUTH_TAB to CommonFlight.java with config key "EnableAuthTab" and default value false
  • Add JavaDoc describing the flag's purpose: enables Chrome AuthTab for browser-based auth flows
  • Follow the existing pattern (e.g., look at SWITCH_BROWSER_PROTOCOL_REQUIRES_STATE as a reference)

Scope

In scope:

  • Adding the ENABLE_AUTH_TAB enum value to CommonFlight

Out of scope:

  • Any code that reads/uses this flag (handled separately)
  • Browser dependency updates (handled separately)

Files to Modify

  • common4j/src/main/com/microsoft/identity/common/java/flighting/CommonFlight.java - Add ENABLE_AUTH_TAB("EnableAuthTab", false) enum value

Acceptance Criteria

  • CommonFlight.ENABLE_AUTH_TAB enum value exists with key "EnableAuthTab" and default false
  • JavaDoc comment on the enum value explains its purpose
  • No new lint warnings introduced
  • Compile check passes: ./gradlew :common4j:compileJava
  • Unit tests pass: ./gradlew :common4j:test

Dependencies

None - this PBI can be implemented independently.

Follow .github/copilot-instructions.md strictly.


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

@github-actions
Copy link

github-actions bot commented Mar 4, 2026

✅ Work item link check complete. Description contains link AB#3533537 to an Azure Boards work item.

@github-actions github-actions bot changed the title [WIP] Add ENABLE_AUTH_TAB feature flag to CommonFlight enum [WIP] Add ENABLE_AUTH_TAB feature flag to CommonFlight enum, Fixes AB#3533537 Mar 4, 2026
Co-authored-by: shahzaibj <37125644+shahzaibj@users.noreply.github.com>
Copilot AI changed the title [WIP] Add ENABLE_AUTH_TAB feature flag to CommonFlight enum, Fixes AB#3533537 Add ENABLE_AUTH_TAB feature flag to CommonFlight Mar 4, 2026
@github-actions github-actions bot changed the title Add ENABLE_AUTH_TAB feature flag to CommonFlight Add ENABLE_AUTH_TAB feature flag to CommonFlight, Fixes AB#3533537 Mar 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants