Open Issues Need Help
View All on GitHubAI Summary: The `Connect-AzAccount` cmdlet does not correctly update the `Environment.Name` property in the current PowerShell context when switching between different Azure environments. While the `ResourceManagerUrl` updates as expected, the environment name displayed in the context remains that of the previously connected environment, leading to a misleading state. This issue occurs when switching from a custom environment to a standard one, and vice-versa.
Microsoft Azure PowerShell
Microsoft Azure PowerShell
AI Summary: The task is to debug and fix a bug in the Azure PowerShell `Get-AzAccessToken` cmdlet. The bug causes the cmdlet to fail when retrieving an access token for the resource 'https://management.azure.com/' after using the `Connect-AzAccount -AccessToken` method, while succeeding with other authentication methods or for the resource 'https://management.core.windows.net/'. The solution likely involves investigating the `AccessTokenAuthenticator` within the `Az.Accounts` module and ensuring it correctly handles access tokens obtained via the specified method.
Microsoft Azure PowerShell