Skip to content

Commit

Permalink
Merge pull request #68 from spyr0-sec/update-laps-schema
Browse files Browse the repository at this point in the history
Update LAPS schema
  • Loading branch information
rvazarkar authored Aug 16, 2023
2 parents 3fe17d5 + 1f2089b commit 4ddf1b2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
5 changes: 3 additions & 2 deletions src/CommonLib/LDAPProperties.cs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ public class LDAPProperties
public const string OperatingSystem = "operatingsystem";
public const string ServicePack = "operatingsystemservicepack";
public const string DNSHostName = "dnshostname";
public const string LAPSExpirationTime = "ms-mcs-admpwdexpirationtime";
public const string LAPSExpirationTime = "mslaps-passwordexpirationtime";
public const string LegacyLAPSExpirationTime = "ms-mcs-admpwdexpirationtime";
public const string Members = "member";
public const string SecurityDescriptor = "ntsecuritydescriptor";
public const string SecurityIdentifier = "securityidentifier";
Expand All @@ -48,4 +49,4 @@ public class LDAPProperties
public const string ScriptPath = "scriptpath";
public const string HostServiceAccount = "msds-hostserviceaccount";
}
}
}
4 changes: 2 additions & 2 deletions src/CommonLib/SearchResultEntryWrapper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -247,12 +247,12 @@ public bool IsGMSA()

public bool HasLAPS()
{
return GetProperty(LDAPProperties.LAPSExpirationTime) != null;
return GetProperty(LDAPProperties.LAPSExpirationTime) != null || GetProperty(LDAPProperties.LegacyLAPSExpirationTime) != null;
}

public SearchResultEntry GetEntry()
{
return _entry;
}
}
}
}

0 comments on commit 4ddf1b2

Please sign in to comment.