List Windows AD active users



Get-ADUser -LDAPFilter "(&(sAMAccountName=*)(!userAccountControl:1.2.840.113556.1.4.803:=2))" ` -Properties sAMAccountName, givenName, sn, mail, enabled | Select sAMAccountName, givenName, sn, mail, enabled | ` Export-Csv -Path c:\Users.csv -NoTypeInformation


DIsable LAPS

  Turn all items to disabled in LAPS GPO    Remove LAPS passwords Get-ADComputer -Filter * -SearchBase “OU=Servers,DC=mydomain,DC=com” | Se...

Mais vistos