Hi there. I need to audit folder permissions, but just for a specific username, and possibly for specific permissions. I don’t know how to do the filtering part and the articles I’ve read about using where-object are still a little over my head. Here is the script I have so far:
Maybe I can use a filter something like | Where-Object -FilterScript {$Access.IdentityReference -LIKE 'IUSR'} but I don’t understand where to place it in the script. Please let me know if this is a workable route to take and where I should put it. Thanks for any advice you can offer!
Thanks for taking a look. I had looked at AccessChk earlier but it does not support wildcards, which took me down a rabbit hole before I decided to try PowerShell.
It’s definitely possible (and worth learning!) with PowerShell but I’m missing some fundamentals. I’d like to create an object and filter for a certain string in the user name, and a couple different permission types before I output it.
Ok, this is very helpful and the way it’s layed out helps me understand the flow. After replacing the path with my own it works just fine for checking FullControl. But for some reason it does not work when checking Modify permission. I’ll play around with it to see if I can get it to work.