8. LAPS

Finding Presence

If it's applied to a machine that you have access to, AdmPwd.dll will be on disk.

ls C:\\Program Files\\LAPS\\CSE

 Size     Type    Last Modified         Name
 ----     ----    -------------         ----
 179kb    fil     05/05/2021 07:04:14   AdmPwd.dll

We could also search for GPOs that have "LAPS" or some other descriptive term in the name.

powershell Get-DomainGPO | ? { $_.DisplayName -like "*laps*" } | select DisplayName, Name, GPCFileSysPath | fl

usncreated               : 25966
displayname              : LAPS
gpcmachineextensionnames : [{35378EAC-683F-11D2-A89A-00C04FBBCFA2}{D02B1F72-3407-48AE-BA88-E8213C6761F1}][{C6DC5466-785
                           A-11D2-84D0-00C04FB169F7}{942A8E4F-A261-11D1-A760-00C04FB9603F}][{D76B9641-3288-4F75-942D-08
                           7DE603E3EA}{D02B1F72-3407-48AE-BA88-E8213C6761F1}]
whenchanged              : 8/16/2022 12:39:45 PM
objectclass              : {top, container, groupPolicyContainer}
gpcfunctionalityversion  : 2
showinadvancedviewonly   : True
usnchanged               : 26068
dscorepropagationdata    : {9/7/2022 1:05:58 PM, 1/1/1601 12:00:00 AM}
name                     : {2BE4337D-D231-4D23-A029-7B999885E659} # GPO ID

As well as computer objects where the ms-Mcs-AdmPwdExpirationTime property is not null

Downloading Info

If we locate the correct GPO, we can download the LAPS configuration from the gpcfilesyspath.

Parse-PolFile to convert this file into human-readable format.

Impersonating users who can access LAPS

Discover which principals are allowed to read the ms-Mcs-AdmPwd attribute

Users in Developers group and Support Engineers group can read the LAPS password

Create a TGT using the LAPS credentials and pass the ticket

Last updated