SharePoint 2013 - how to show site or list's permissions by PowerShell?

Goo day.

How to show table of site's or list's permissions, as it visible in web-interface?

Get-SPWeb -site 'http://company.com' | Select Permissions - outputs something different as I think...

August 28th, 2015 11:53am

You can use SPWeb.RoleAssignments, e.g.:

$site = Get-SPSite http://siteUrl
$site.RootWeb.RoleAssignments

Same for a list:

$list = $site.RootWeb.List["ListTitle"]
$list.RoleAssignments

If you want to see what roles a user belongs to, you can use:

$site.RootWeb.SiteUsers | Select UserLogin,Roles,IsSiteAdmin

Free Windows Admin Tool Kit Click here and download it now
August 29th, 2015 12:15pm

Allen,

There's a lot of aspects to SharePoint security: users, groups, AD groups, permission levels, etc. Here's a collection of permissions scripts I put together a while back:

http://sharepointpromag.com/sharepoint-2013/exploring-sharepoint-users-groups-and-security-using-powershell

August 29th, 2015 4:03pm

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

Other recent topics Other recent topics