rubrikinc / polaris-o365-powershell

PowerShell commands for managing Polaris M365 protection
MIT License
7 stars 13 forks source link

New-EnterpriseApplication.ps1 fails with insufficient privileges #29

Closed scottwtang closed 1 year ago

scottwtang commented 1 year ago

Expected Behavior

New-EnterpriseApplication.ps1 is able to run the cmdlet Get-MgOrganization without any issue

Current Behavior

New-EnterpriseApplication.ps1 connects to MS Graph with the scopes Application.ReadWrite.All,AppRoleAssignment.ReadWrite.All, and then later in the script calls the cmdlet Get-MgOrganization, which will give an error if the proper permissions aren't configured. The error given is "Insufficient privileges to complete the operation"

Failure Information

Steps to Reproduce

Context

Failure Logs