Getting Site and Subsite have Unique / Inheriting Permissions in SharePoint Online using PowerShell

I need a PowerShell script which will get me the List of All SharePoint Sites and Subsites in a Site Collection along with Permissions i.e Unique or Inherited from Parent using PowerShell.

I have tried 

http://sharepoint.stackexchange.com/questions/101176/powershell-to-list-all-sites-and-subsites-in-sharepoint-online

But getting 403 forbidden error. Any other help is appreciated.

August 18th, 2015 5:08pm

Hi,

As I understand, you get the 403 error when getting sites and subsites which have Unique / Inheriting permissions in SharePoint Online using PowerShell.

The PowerShell script below can pass the SharePointOnline credentials.

$ctx = New-Object Microsoft.SharePoint.Client.ClientContext($webUrl) 

$ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($username, $password)

For more detailed information, you could refer to the article below.

The article below is about using PowerShell and the .NET CSOM to Query SharePoint 2013 Online.

http://blog.blumenthalit.com/blog/Lists/Posts/Post.aspx?ID=171

More reference:

The article below is about PowerShell for SharePoint online under the hood.

http://jeffreypaarhuis.com/2012/06/14/powershell-for-sharepoint-online-under-the-hood/

Best regards,

Sa

Free Windows Admin Tool Kit Click here and download it now
August 19th, 2015 11:17pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics