Verify if domain account can access 100s of file shares.

Hi All

Does anyone have a Powershell script to share that would do the following ?

1) gets the path form a text file .. example below .. with 100s  of paths
\\server1\share1
\\server2\share2
\\server9912\share99
2) checks if a set of domain credentials can access each share.
3) output CSV with each path and if the account was able to access the share or not .
LVL 2
MilesLoganAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Lee W, MVPTechnology and Business Process AdvisorCommented:
Are you assigning permissions directly to the account or are you assigning the account to groups which should have access... I'm trying to picture a scenario where a system is setup properly and this must be done...
0
MilesLoganAuthor Commented:
so basically , I want to test if the account which is not added to any groups can access any of those shares.
Some of those shares are incorrectly configured and open to everyone , so if the account can access it , then its set up incorrect .

similar to

Test-Path \\share\folder1
when it returns True or False
0
Shaun VermaakTechnical Specialist IVCommented:
You can do a efficetive permission report via the Get-PacEffectiveAccess function
Get-PacEffectiveAccess c:\folder -Principal Username

Open in new window

https://social.technet.microsoft.com/Forums/windowsserver/en-US/ad80d5df-5a34-4db5-996f-59a61855a105/how-to-programmatically-get-effective-permissions-from-share-and-ntfs?forum=winserverpowershell
https://gallery.technet.microsoft.com/scriptcenter/PowerShellAccessControl-d3be7b83
1

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
MilesLoganAuthor Commented:
Thank you for the link
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Powershell

From novice to tech pro — start learning today.