Archiv für den Monat: Februar 2017

Windows change access permissions from the command line

CACLS files /e /p {USERNAME}:{PERMISSION}

Where,

  • /p : Set new permission
  • /e : Edit permission and kept old permission as it is i.e. edit ACL instead of replacing it.
  • {USERNAME} : Name of user
  • {PERMISSION} : Permission can be:
    • R – Read
    • W – Write
    • C – Change (write)
    • F – Full control

For example grant Rocky Full (F) control with following command (type at Windows command prompt):

C:> CACLS files /e /p rocky:f

Read complete help by typing following command:

C:> cacls /?

Quelle: Windows change access permissions from the command line

Konten im Active Directory entsperren oder aktivieren mit PowerShell | WindowsPro

Ein Tipp von meinem lieben Kollegen Rainer:

Search-ADAccount -LockedOut -UsersOnly -SearchBase „OU=IT,DC=contoso,DC=com“

Search-ADAccount -AccountExpired -UsersOnly

Search-ADAccount -AccountExpiring -TimeSpan „10“7

Unlock-ADAccount -Identity amueller

Set-ADAccountExpiration -DateTime 30.04.2017

Quelle: Konten im Active Directory entsperren oder aktivieren mit PowerShell | WindowsPro