-
Notifications
You must be signed in to change notification settings - Fork 807
Fix fake user addition to the config because of Mimikatz #1902
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
before adding to the config since we don't want to add users created by the Monkey
…g because of Mimikatz
Codecov Report
@@ Coverage Diff @@
## develop #1902 +/- ##
========================================
Coverage 54.93% 54.94%
========================================
Files 446 447 +1
Lines 12624 12626 +2
========================================
+ Hits 6935 6937 +2
Misses 5689 5689
Continue to review full report at Codecov.
|
monkey/infection_monkey/consts.py
Outdated
@@ -0,0 +1 @@ | |||
USERNAME_PREFIX = "somenewuser" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think it's worth creating a new file just for this. I suppose mimikatz credential collector should just import from PBA, since that's the source of users we don't want to add.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't couple the mimikatz collector to the PBAs!
|
||
# Mimikatz picks up users created by the Monkey even if they're successfully deleted | ||
# since it picks up creds from the registry. The newly created users are not removed | ||
# from the registry until a reboot of the system, hence this check. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Have you checked? We need to make sure these users aren't left there forever
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, checked
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Small changes/tests
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm concerned about the coupling this introduces between the PBAs and CredentialsCollectors. We may not be able to properly solve this issue without some more infrastructure in place. Ideally, both the PBA and the MimikatzCollector would be configurable so that the user can configure which users MimikatzCollector ignores.
At this time, I don't know that this issue is a significant enough nuisance to warrant coupling the PBAs and the CredentialsCollectors.
This const is used by PBA and mimikatz collectors as describes the username prefix for users created by IM
What does this PR do?
Fixes #1860
PR Checklist
Was the documentation framework updated to reflect the changes?Have you checked that you haven't introduced any duplicate code?Testing Checklist
Added relevant unit tests?If applicable, add screenshots or log transcripts of the feature working