1

I've a script to start a Search task on Content Search, of Compliance.

If I use my own user account to login, I am able to run it, but if I use an unattended login through an App, like the one of App-only authentication in Exchange Online PowerShell and Security & Compliance PowerShell | Microsoft Learn, I receive the following error:

enter image description here

From compliance perspective I got this, an empty search:

enter image description here

I've given a Global Admin role to the App. From app only authentication/login, there is no issue with that.

ExchangeOnlineManagement version that Iam using is 2.0.6-Preview7.

Anyone knows how can I solve this?

Thank you in advance!

marafado88
  • 412
  • 2
  • 9
  • 31
  • 1
    Have a read here https://www.codetwo.com/admins-blog/new-compliancesearch-new-version-of-search-mailbox/, may be that Global Admin doesn't have the 'Compliance' permissions for the necessary modules needed. I've not used apps to do this sort of thing, but for ediscovery and compliance cmdlets, you might need to assign the app those roles talked about in that post. I read a different post that eluded to the account doing the search not having an Exchange mailbox and getting a similar error, but not 100% the same. Consider figuring out he necessary roles and removing Global Admin to further test – Pimp Juice IT Oct 24 '22 at 02:46

0 Answers0