john pfeiffer
  • Home
  • Categories
  • Tags
  • Archives

cmdline change permissions

runas /user:ANDERS\johnpfeiffer cmd
    change permissions: 
    ECHO Y| CACLS /g <username>:<permission>

Add Read-Only permission to a single file CACLS myfile.txt /E /G "Power Users":R

Add Full Control permission to a second group of users CACLS myfile.txt /E /G "FinanceUsers":F

Now revoke the Read permissions from the first group CACLS myfile.txt /E /R "Power Users"

Now give the first group Full-control: CACLS myfile.txt /E /G "Power Users":F

Give the Finance group Full Control of a folder and all sub folders CACLS c:\docs\work /E /T /C /G "FinanceUsers":F


  • « command line find all files owned by a user
  • CMD WIN DOS usage »

Published

Feb 6, 2010

Category

research

~85 words

Tags

  • change 10
  • cmdline 4
  • permissions 8
  • research 199