mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-24 18:49:00 +01:00
Add support for Entra ID v1.0 authorization servers in VSCode MCP Client (#262603)
* Initial plan * Add v1.0 Entra ID support and optimize MCP discovery for Microsoft endpoints Co-authored-by: TylerLeonhardt <2644648+TylerLeonhardt@users.noreply.github.com> * Add tests for v1.0 authorization server support Co-authored-by: TylerLeonhardt <2644648+TylerLeonhardt@users.noreply.github.com> * Address code review feedback: remove redundant tests and Microsoft-specific logic Co-authored-by: TylerLeonhardt <2644648+TylerLeonhardt@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: TylerLeonhardt <2644648+TylerLeonhardt@users.noreply.github.com>
This commit is contained in:
@@ -102,4 +102,10 @@ suite('ScopeData', () => {
|
||||
const scopeData = new ScopeData(['custom_scope', 'VSCODE_TENANT:scope_tenant'], undefined, authorizationServer);
|
||||
assert.strictEqual(scopeData.tenant, 'url_tenant');
|
||||
});
|
||||
|
||||
test('should extract tenant from v1.0 authorization server URL path', () => {
|
||||
const authorizationServer = Uri.parse('https://login.microsoftonline.com/tenant123');
|
||||
const scopeData = new ScopeData(['custom_scope'], undefined, authorizationServer);
|
||||
assert.strictEqual(scopeData.tenant, 'tenant123');
|
||||
});
|
||||
});
|
||||
|
||||
@@ -171,6 +171,7 @@ export async function activate(context: vscode.ExtensionContext, telemetryReport
|
||||
{
|
||||
supportsMultipleAccounts: true,
|
||||
supportedAuthorizationServers: [
|
||||
vscode.Uri.parse('https://login.microsoftonline.com/*'),
|
||||
vscode.Uri.parse('https://login.microsoftonline.com/*/v2.0')
|
||||
]
|
||||
}
|
||||
|
||||
@@ -83,6 +83,7 @@ export async function activate(context: ExtensionContext, mainTelemetryReporter:
|
||||
supportsMultipleAccounts: true,
|
||||
supportsChallenges: true,
|
||||
supportedAuthorizationServers: [
|
||||
Uri.parse('https://login.microsoftonline.com/*'),
|
||||
Uri.parse('https://login.microsoftonline.com/*/v2.0')
|
||||
]
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user