adal - Can You Grant Admin Access to an Azure Application through PowerShell -
is there way grant administrative consent application using powershell? imagine have done connect-msolservice , provided credentials of account tenant admin; there way provide tenant-wide consent based on application client id?
to clarify, mean granting application ability access directory admin?
if case, can this:
# using windows azure active directory module windows powershell # # connect tenant modify connect-msolservice # => login # service principal add role $serviceprincipal = get-msolserviceprincipal -serviceprincipalname principal.name # role object id # alternatively, can list roles (in order different role name) using `get-msolrole` $roleid = (get-msolrole -rolename "directory readers").objectid # add role service principal add-msolrolemember -roleobjectid $roleid -rolememberobjectid $serviceprincipal.objectid -rolemembertype serviceprincipal # check our work get-msolrolemember -roleobjectid $roleid # => should include principal.name in list
consenting permissions requested application (through requiredresourceaccess) can done via adal during authorization process.
Comments
Post a Comment