Sites.Selected and Everyone except external users

christou 1 Reputation point
2021-09-16T07:21:46.403+00:00

Hi everyone,

I wanted to use the MS Graph to scan (through search essentially) content that might have been shared with everyone through the "Everyone except external users" group.

I was hoping to achieve this :
* Create an app registration with the Microsoft Graph Sites.Selected permission
* Not adding any additional permission on sites hoping that by default it would access content shared to everyone
* Invoke a search query with graph to retrieve items that were indeed shared to everyone

Unfortunately it seems that you need to explicitely add the permissions to the identity at some point to make it work.

Is this by design or will the Graph evolve to work in such cases ?
Do you think of a workaround on this ?

Thanks a lot

Chris

Microsoft Security | Microsoft Graph
{count} votes

1 answer

Sort by: Most helpful
  1. CarlZhao-MSFT 46,376 Reputation points
    2021-09-17T02:29:36.607+00:00

    According to the official doc, you should use Sites.Read.All permissions instead of Sites.Selected permissions.

    132925-303.png

    132927-image.png


    If an Answer is helpful, please click "Accept Answer" and upvote it.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.