Physical location of Service Pricipals in Azure Portal?

171 views Asked by At

Everytime I go to create a Service Principal in azure, I go through the steps of creating an Application. Which I understand, cool. My application has authentication rights.

When I create an Automation Run As account, it creates a service principal and and stores a certificate. Where is the certificate or whatever other THINGS make this a service principal? I want to find out what subscriptions my service principal has rights to by list in PowerShell, but some app ID doesn't seem like its the right path.

cool I can get the name of the service principal of the app. ONLY shows me how to do this in powershell. WHAT is the SP ?? WHERE is it

2

There are 2 answers

1
4c74356b41 On BEST ANSWER
2
axfd On

According to my understanding, you want to get Azure AD service principal with PowerShell. You can use PowerShell command "Get-AzureRmADServicePrincipal". The script is as below.

Login-AzureRmAccount
Get-AzureRmSubscription
Select-AzureRmSubscription -SubscriptionName "<yourSubscriptionName>"
Get-AzureRmADServicePrincipal

Besides,in order to access resources that are secured by an Azure AD tenant, the entity that requires access must be represented by a security principal. This is true for both users (user principal) and applications (service principal). For more details, please refer to the document.