BloodHoundAD / SharpHoundCommon

Common library used by SharpHound.
GNU General Public License v3.0
73 stars 47 forks source link

Check if ResolveAccountName returns a value #90

Closed nurfed1 closed 6 months ago

nurfed1 commented 7 months ago

The GPOLocalGroup processor crashes when ResolveAccountName fails to resolve the member name and this stops processing for the GPO entirely. One such case I've seen is when the group name has a format like PT0-%ComputerName%-LocalAdmin.

Ideally it would be great if some process variables such as %ComputerName% and %DomainName% could be resolved by sharphound, but I don't see a clean way to implement this. But at least we can prevent a crash and print a warning.

rvazarkar commented 6 months ago

Thanks for the MR, I spent some time trying to track this down but couldn't repro it locally