Login Authentication Failure on 2.63.0: Error code: -2147221164
Describe the bug
When running az login -u $user -p $pass --tenant $tenant --allow-no-subscriptions we hit this error:
WARNING: Authentication with username and *** in the command line is strongly discouraged. Use one of the recommended authentication methods based on your requirements. For more details, see https://go.microsoft.com/fwlink/?linkid=2276314 ERROR: (pii). Status: Response_Status.Status_Unexpected, Error code: -2147221164, Tag: 557973639 Please explicitly log in with:
This is happening on CLI version 2.63.0 and not on 2.62.0
Related command
az login
Errors
WARNING: Authentication with username and *** in the command line is strongly discouraged. Use one of the recommended authentication methods based on your requirements. For more details, see https://go.microsoft.com/fwlink/?linkid=2276314 ERROR: (pii). Status: Response_Status.Status_Unexpected, Error code: -2147221164, Tag: 557973639 Please explicitly log in with:
Issue script & Debug output
N/A
Expected behavior
Should be able to login as normal
Environment Summary
{ "azure-cli": "2.63.0", "azure-cli-core": "2.63.0", "azure-cli-telemetry": "1.1.0", "extensions": {} }
Additional context
No response
Thank you for opening this issue, we will look into it.
Also happened to me. Also had to rollback to 2.62.0
Is there any interim solution for this apart from rollback to older version??
Our team is also currently having this issue. Is there an ETA for a fix?
Is there any interim solution for this apart from rollback to older version??
As a workaround, you may follow https://learn.microsoft.com/en-us/cli/azure/authenticate-azure-cli-interactively#sign-in-with-web-account-manager-wam-on-windows to turn off WAM:
az account clear
az config set core.enable_broker_on_windows=false
az login
We are still facing the issue in login process of az login and workaround doesn't seems to be working. FYI : login credentials is valid and works fine via azure portal. only problem with az cli
WARNING: Command group 'config' is experimental and under development. Reference and support levels: https://aka.ms/CLI_refstatus WARNING: Authentication with username and password in the command line is strongly discouraged. Use one of the recommended authentication methods based on your requirements. For more details, see https://go.microsoft.com/fwlink/?linkid=2276314
ERROR: AADSTS50126: Error validating credentials due to invalid username or password. Timestamp: 2024-09-16 10:26:12Z Interactive authentication is needed. Please run: az login ERROR: Please run 'az login' to setup account.
Hi @mchen727 , for the call related to WAM, could you help collect WAM logs described here: https://aka.ms/wamhot and we will be able to investigate further.
@mukeshinit , with the workaround, you disabled WAM and got the issue? Did you do the interactive authentication as instructed? Could you help collect the verbose logs?
Thank you very much.
Used the mentioned workaronud
I met the same error on 2.66.0
Any update on this issue ?we are still facing same error even with apply suggested workaround solution.
Authentication with username and password in the command line is strongly discouraged. Use one of the recommended authentication methods based on your requirements. For more details, see https://go.microsoft.com/fwlink/?linkid=2276314 (pii). Status: Response_Status.Status_InteractionRequired, Error code: 3399614467, Tag: 508609292