Azure / Azure/azure-powershell

The Known Issues of Az.Accounts 3.0.0 and Their Workarounds

Open
#25,005 14 comments 3 reactions 0 assignees View on GitHub
Accounts Discuss WAM
Dominant language
C#
Stars
4.8k
Forks
4.3k
Avg merge
2d 17h
Merged PRs (30d)
51

Description

## 1. The interactive login method cannot popup window for WAM (Fixed)

Report an error **"User canceled authentication"** Refer to https://github.com/AzureAD/microsoft-authentication-library-for-python/issues/707
- Fixed in [Az.Accounts 3.0.1](https://github.com/Azure/azure-powershell/releases/tag/v12.1.0-July2024)

## 2. Azure PowerShell cmdlets are unable to run after login with DeviceCode and DeviceCode login methods will fail without `-Tenant` parameter (Mitigated)
- Fixed in [Az.Accounts 4.0.0](https://www.powershellgallery.com/packages/Az.Accounts/4.0.0)

## 3. Azure PowerShell cmdlets are unable to run after login with UserName+Password and UserName+Password login methods will fail without `-Tenant` parameter (Mitigated)
- Workaround of Az.Accounts 3.0.0
- Login interactively with the same account on the same machine
- If 1 is not applicable, disable WAM
```
Update-AzConfig -EnableLoginByWam $false
```
- Mitigated in [Az.Accounts 3.0.1](https://github.com/Azure/azure-powershell/releases/tag/v12.1.0-July2024)

## 4. WAM pop-up window to select an account is not easy to find
- Workaround: minimize other windows to look for the pop-up window carefully
### Root case
Fail to get the right console handle. See https://github.com/AzureAD/microsoft-authentication-library-for-dotnet/issues/4887

## 5 WAM pop-up window doesn't display "Work and school account" option
- Fixed in [Az.Accounts 4.0.0](https://www.powershellgallery.com/packages/Az.Accounts/4.0.0)

## 6. The interactive login method cannot popup window for WAM in Window PowerShell ISE Console
- Workaround
```
Update-AzConfig -EnableLoginByWam $false
```
> [!NOTE]
> Reported to MSAL team, see https://github.com/AzureAD/microsoft-authentication-library-for-dotnet/issues/4796

## 7. The `ExportAzSshConfig` and `EnterAzVMCommand` from Az.Ssh are not able to use when WAM is enabled.
- Fixed in [Az.Accounts 4.0.0](https://www.powershellgallery.com/packages/Az.Accounts/4.0.0)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.