SOLVED

Get-SMBShareAccess

%3CLINGO-SUB%20id%3D%22lingo-sub-2270005%22%20slang%3D%22en-US%22%3EGet-SMBShareAccess%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2270005%22%20slang%3D%22en-US%22%3E%3CP%3EHi%20Everyone%2C%20I%20am%20now%20to%20Powershell%20and%20just%20joined%20this%20Page%20today%20Excuse%20me%20for%20my%20questions%20if%20they%20don't%20make%20any%20Sense%20I%20am%20here%20to%20learn.%3C%2FP%3E%3CP%3EI%20was%20trying%20to%20use%20this%20Powershell%20%22%20Get-SmbShareAccess%22.%20My%20objective%20is%20to%20fetch%20all%20sms%20share%20an%20a%20server%20But%20this%20Permissions%20on%20it.%3C%2FP%3E%3CP%3Ethis%20cmdlets%20gives%20me%20Particular%20share%20Permission%20But%20I%20want%20All%20shares%20with%20All%20permission%20on%20it.%20I%20tried%20googling%20But%20didnot%20find%20anything.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ECan%20anybody%20help%20me%20with%20that%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThanks%20in%20Advance.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-2270005%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EWindows%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EWindows%20PowerShell%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EWindows%20Server%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E
New Contributor

Hi Everyone, I am now to Powershell and just joined this Page today Excuse me for my questions if they don't make any Sense I am here to learn.

I was trying to use this Powershell " Get-SmbShareAccess". My objective is to fetch all sms share an a server But this Permissions on it.

this cmdlets gives me Particular share Permission But I want All shares with All permission on it. I tried googling But didnot find anything.

 

Can anybody help me with that?

 

Thanks in Advance.

 

2 Replies

Hello @PRIME_FIRE,

From what I understand, first you need to get list of shares on the server using Get-FileShare cmdlet and then use Get-SMBShareAccess to get list of permissions.

Hope that helps.

best response confirmed by PRIME_FIRE (New Contributor)
Solution

@AndySvints 

Thank you. I kept on digging and found now to use to separate commands in one go.

Get.SmbShare I Get-SmbshareAccess >> c:/ sambshare.TXT

 

It gave me all what I wanted.

 

Thankyou.