Modify Permissions on Existing Files and Folder

Frequent Contributor

We used the SharePoint migration tool to migrate 250Gb of data.  These files are within 25 folder then subfolders. The permissions on each folder was updated using the migration tool which is great.


However, I now need to modify the permissions from the View Only to Edit.  I've changed the permissions on the Site and the Library, however, the permissions are not being overridden or updated to the subfolders and files so users still cannot edit.


If I select all the folders, the Manage Access is not enabled so I can't do it there.  I've found the only way to do this is to select 1 folder > Manage Access > Change to Edit but this will take forever.


Is there no way to reapply the security to existing folders and files when I change the Library permissions?

1 Reply
Best Response confirmed by Juan Carlos González Martín (MVP)

@Mercedes Green  only way I found to do this was to run a powershell script. However this took forever and I was not sure if it has actually worked. Here is the script using pnp: - 



$Log = 0
$items = Get-PnPListItem -List Companies -PageSize 1000  | where {$_.HasUniqueRoleAssignments}
foreach($item in $items)
$Log =  $Log + 1
Write-Host $log
Write-Host “error”



I broke it into chunks of 1000 items as returning the list of files was taking too long. 

I have not run that in a while so no guarantees it will work.  The other thing you may try is reapply the permissions to the library but tick the box " Share everything in this folder, even items with unique permissions."  Sometimes that works sometimes it says you are over the list threshold.