Jump to content

ginger8990

Members
  • Posts

    3
  • Joined

  • Last visited

Reputation

0 Neutral

About ginger8990

  1. I used icacls to generate share permissions. I can add a user or a group to the share permissions but I cannot add multiple users or groups to a share at the same time in vbs or icalcls. @echo offset /p username=Enter username:echo Select permissions :echo N - no accessecho F - full accessecho M - modify accessecho RX - read and exeecho R - read-only accecho W - write-only acecho D - delete accessecho.set /p perm=Enter permissions:if %perm%==Ficacls "C:\Users\%username%" /grant:r "%username%:(OI)(CI)F"
  2. Can you send me scripts forum link? icalcls and calcls can be used to add multiple groups to tons of network share folders ?
  3. Is a script around to list network share permissions ? This script can add permissions to a folder but not add permissions to the sub folder: Anyone know how to teak it to set permissions to the folder and sub folders and files. Option Explicit Dim strHomeFolder, strHome, strUser Dim intRunError, objShell, objFSO strHomeFolder = "\\grand\home\user" Set objShell = CreateObject("Wscript.Shell") Set objFSO = CreateObject("Scripting.FileSystemObject") If objFSO.FolderExists(strHomeFolder) Then ' Assign user permission to home folder. intRunError = objShell.Run("%COMSPEC% /c Echo Y| cacls " _ & strHomeFolder & " /e /c /g Administrators:F ", 2, True) If intRunError <> 0 Then Wscript.Echo "Error assigning permissions for user " _ & strUser & " to home folder " & strHomeFolder End If End If WScript.Quit
×
×
  • Create New...