vbscript to extract shares, share permissions, folder permissions from Windows 2008 server and others
Command on server: "Shares&Permission.vbs" access_test.log My example output: https://docs.google.com/spreadsheets/d/15h3xZJmAB7lVhqRT-1t5lSAB0JQhhqgRl8bTulMgeSc/edit?usp=sharing Vb script code, file name "Shares&Permission.vbs" : strComputer = "." StrReportFile = Trim(WScript.Arguments(0)) Set ObjFSO = CreateObject("Scripting.FileSystemObject") Set WriteHandle = ObjFSO.OpenTextFile(StrReportFile, 2, True, 0) Set ObjWMI = GetObject("WinMgmts:{impersonationLevel=impersonate}!\\" & StrComputer & "\Root\CIMV2") Set ColShares = ObjWMI.ExecQuery("Select Name, Type, Path From Win32_Share", "WQL", &h10 + &h20) WriteHandle.WriteLine "Permission;ShareName;Path;Domain;Name;Type" & ShareName For Each Share In ColShares str="Folder;" If Share.Type = 0 Then ShareName = Share.Name SharePath = Share.Path ...