Unable to login via device code -> code_expired #22252
Labels
Account
az login/account
Auto-Assign
Auto assign by bot
customer-reported
Issues that are reported by GitHub users external to the Azure organization.
Installation
Milestone
Describe the bug
Currently I'm unable to login via the device code. It doesn't matter if i use the az cli or the Powershell implementation i get the following error message:
$az login --use-device-code
Unexpected polling state code_expired
Or if i use Lense:
E0503 10:47:43.944162 95942 azure.go:154] Failed to acquire a token: failed acquiring new token: waiting for device code authentication to complete: autorest/adal/devicetoken: Error while retrieving OAuth token: Code Expired
Or if i use Powershell
Connect-AzAccount -UseDeviceAuthentication
WARNING: Unable to acquire token for tenant 'organizations' with error 'DeviceCodeCredential authentication failed: AADSTS70020: The provided value for the input parameter 'device_code' is not valid. This device code has expired.
Trace ID: XXXX
Correlation ID: XXXX
Timestamp: XXXX
Connect-AzAccount: DeviceCodeCredential authentication failed: AADSTS70020: The provided value for the input parameter 'device_code' is not valid. This device code has expired.
To Reproduce
Use one of the above described scripts
Expected behavior
Would be nice to have a working login again
Environment summary
Tested on MacOS with Bash & Windows with Bash & Windows with Powershell
az cli version: 2.36.0
Additional context
I tested this with multiple Tenants and Subscriptions all had the same issue
The text was updated successfully, but these errors were encountered: