DonPAPI icon indicating copy to clipboard operation
DonPAPI copied to clipboard

Fix SAM dump error when remote registry is disabled OR EDR blocks it

Open Dfte opened this issue 1 year ago • 0 comments

This PR fixes the following error:

image

(see https://github.com/login-securite/DonPAPI/issues/79)

By adding the following line to core.py (line 267):

if hasattr(self.sam_dump, "items_found") and self.sam_dump.items_found is not None:
    self.logger.secret(f"Got {len(self.sam_dump.items_found)} accounts", "SAM")
else:
    self.logger.fail(f"No account found in SAM (maybe blocked by EDR)")

That way, we make sure that there is a items_found attribute and DonPAPI doesn't crash anymore.

Dfte avatar Oct 21 '24 08:10 Dfte