Azure / Azure/azure-cli

Auth Failed when using Azure CLI on Dev Box

Open
#31,827 4 comments 0 reactions 1 assignee Claimed by @jiasli View on GitHub
Account act-identity-squad Auto-Assign Auto-Resolve Azure CLI Team customer-reported Possible-Solution question Similar-Issue
Dominant language
Python
Stars
4.6k
Forks
3.5k
Avg merge
3d 2h
Merged PRs (30d)
60

Description

### Describe the bug

Cannot login using Azure CLI on dev box. I am getting the popup to login and then getting the below error message. I've tried logging in using a specific tenant id and tried `az login --allow-no-subscriptions` nothing works.

### Related command

az login

### Errors

PowerShell 7.5.2
PS C:\Users\ksenialuu> az login
Select the account you want to log in with. For more information on login with Azure CLI, see https://go.microsoft.com/fwlink/?linkid=2271136

Retrieving tenants and subscriptions for the selection...
Authentication failed against tenant 1a092f68-5741-455a-8057-2acdb897a850 'HMGAdmin': SubError: message_only V2Error: invalid_grant AADSTS53003: Access has been blocked by Conditional Access policies. The access policy does not allow token issuance. Trace ID: 232a7820-9157-4bb8-8223-4d773a0d6100 Correlation ID: ad8c14db-b243-4e7c-af1c-9d8cb97384d1 Timestamp: 2025-07-16 18:22:01Z. Status: Response_Status.Status_InteractionRequired, Error code: 3399614476, Tag: 557973645
The following tenants don't contain accessible subscriptions. Use `az login --allow-no-subscriptions` to have tenant level access.
13e541f2-35b1-4081-98e5-add1545acf00 'Contoso'
If you need to access subscriptions in the following tenants, please use `az login --tenant TENANT_ID`.
1a092f68-5741-455a-8057-2acdb897a850 'HMGAdmin'

### Issue script & Debug output

n/a

### Expected behavior

Being able to log in

### Environment Summary

{
"azure-cli": "2.73.0",
"azure-cli-core": "2.73.0",
"azure-cli-telemetry": "1.1.0",
"extensions": {
"account": "0.2.5"
}
}

### Additional context

_No response_

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.