- Access exclusive content
- Connect with peers
- Share your expertise
- Find support resources
Our community just got stronger! Explore new identity security resources, connect with experts, and discover more ways to learn and collaborate.
How to verify Azure accounts outside of Idira using Azure API calls?
In this guide, we will use BRUNO.
Download BRUNO and place it in the CPM server.
https://www.usebruno.com/
To access using Reconcile account(Application Account)
POST
https://login.microsoftonline.com/<Active Directory ID>/oauth2/token? ---> This information can get in debug logs
Body
grant_type=client_credentials
client_id=<Application ID>
client_secret=<application secret>
scope=https://graph.microsoft.com/.default
Once you successfully send the above API to Azure, you will get an access token. Copy the access token and update it to the below Patch API call in Headers Authorization.
To access using Target account (Azure AD)
POST
https://login.microsoftonline.com/<Active Directory ID>/oauth2/token? ---> This information can get in debug logs
Body
grant_type=password
client_id=<Application ID>
scope=https://graph.microsoft.com/.default
username=<target account username in PVWA>
password=<target account password>
Once you successfully send the above API to Azure, you will get an access token. Copy the access token and update it to the below Patch API call in Headers Authorization.
**Please take note that the API will not handle MFA. You will need to disable the AAD account's MFA for this to authenticate successfully to get the token.
REST API Call to update target account password.
PATCH
https://graph.microsoft.com/v1.0/users/<Target Account ID>? ---> This information can get in debug logs
Headers
Authorization=<access_token>
Content-Type=application/json
Body
{
"passwordProfile":
{
"forceChangePasswordNextSignIn": false,
"password": "Cyberark123"
}
}
In the PATCH API call, nothing will get returned in the body below as soon as the Status shows HTTP 200, which means the password has been successfully updated.