Skip to content

Add device code flow when not brokered#270453

Merged
TylerLeonhardt merged 1 commit into
mainfrom
tyler/witty-kiwi
Oct 8, 2025
Merged

Add device code flow when not brokered#270453
TylerLeonhardt merged 1 commit into
mainfrom
tyler/witty-kiwi

Conversation

@TylerLeonhardt
Copy link
Copy Markdown
Member

fixes #270452

Copilot AI review requested due to automatic review settings October 8, 2025 23:34
@TylerLeonhardt TylerLeonhardt enabled auto-merge (squash) October 8, 2025 23:34
@TylerLeonhardt TylerLeonhardt self-assigned this Oct 8, 2025
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds device code flow authentication support when not brokered for the Microsoft Authentication extension. This provides an alternative authentication method for environments where traditional browser-based flows are not available or when broker authentication is not supported.

Key changes:

  • Added device code flow as a new authentication method with support for different extension host environments
  • Enhanced flow selection logic to consider client support and broker availability
  • Integrated device code flow UI with clipboard integration and progress notifications

Reviewed Changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
extensions/microsoft-authentication/src/node/flows.ts Adds DeviceCodeFlow class and updates flow selection logic to consider client support and broker availability
extensions/microsoft-authentication/src/node/cachedPublicClientApplication.ts Implements device code authentication with user interaction and progress handling
extensions/microsoft-authentication/src/node/authProvider.ts Updates authentication provider to determine client support and pass callback URI to flows
extensions/microsoft-authentication/src/common/publicClientCache.ts Adds device code method to the cached client interface
extensions/microsoft-authentication/src/common/loopbackClientAndOpener.ts Refactors to accept callback URI as constructor parameter instead of computing it
extensions/microsoft-authentication/src/node/test/flows.test.ts Adds comprehensive test coverage for the new flow selection logic
extensions/microsoft-authentication/src/common/test/loopbackClientAndOpener.test.ts Updates test to accommodate new constructor parameter and skips problematic test

Comment thread extensions/microsoft-authentication/src/node/flows.ts
@vs-code-engineering vs-code-engineering Bot added this to the October 2025 milestone Oct 8, 2025
@TylerLeonhardt TylerLeonhardt marked this pull request as draft October 8, 2025 23:44
@TylerLeonhardt TylerLeonhardt marked this pull request as ready for review October 8, 2025 23:48
@TylerLeonhardt TylerLeonhardt merged commit d751a3d into main Oct 8, 2025
28 checks passed
@TylerLeonhardt TylerLeonhardt deleted the tyler/witty-kiwi branch October 8, 2025 23:49
@vs-code-engineering vs-code-engineering Bot locked and limited conversation to collaborators Nov 23, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support device code flow when not brokered, Microsoft Auth

3 participants