0

I am trying to connect az by calling following command.

az login -u <username> -p <password>

WsTrust server returned error in RSTR: {'reason': 'MSIS7068: Access denied.', 'code': 'a:FailedAuthentication'}

Here we are getting errors as follow.

P:S: The user has no mfa and no conditional policies.I can able to login interactively.

Please help me to solve this.

Joji
  • 1
  • 1
  • 1

1 Answers1

0

Please note that you cannot login through azure cli by providing Microsoft account credentials inside the command.

I tried in my environment and got below results:

Initially I tried with my Microsoft account and I got an error like below :

Command:

    az login -u <username> -p <password>

Response:

enter image description here

When I used Azure AD account I can login successfully.

Command:

 az login -u <username> -p <password> --allow-no-subscriptions --only-show-errors

Response:

enter image description here

Please check the similar kind of issue in GitHub by yonzhan

Venkatesan
  • 3,748
  • 1
  • 3
  • 15