-
Notifications
You must be signed in to change notification settings - Fork 786
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
Check for empty result in Modify shell files #1510
Conversation
d4b7dc0
to
156fe97
Compare
Codecov Report
@@ Coverage Diff @@
## develop #1510 +/- ##
===========================================
- Coverage 43.00% 42.98% -0.02%
===========================================
Files 477 477
Lines 14171 14176 +5
===========================================
Hits 6094 6094
- Misses 8077 8082 +5
Continue to review full report at Codecov.
|
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.
Approved, provided you tested this and actually get this output in the report
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.
Minor rewording
monkey/infection_monkey/post_breach/actions/modify_shell_startup_files.py
Outdated
Show resolved
Hide resolved
019219b
to
6f51b4c
Compare
CHANGELOG.md
Outdated
@@ -46,7 +46,7 @@ Changelog](https://keepachangelog.com/en/1.0.0/). | |||
- Some of the gathered credentials no longer appear in database plaintext. #1454 | |||
- Encryptor breaking with UTF-8 characters. (Passwords in different languages can be submitted in | |||
the config successfully now.) #1490 | |||
|
|||
- Malfunctioning Modify shell startup files PBA on Docker. #1507 |
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.
Changelog entries should be meaningful to the user of the changed component. "Malfunction" is a little bit broad, and the issue isn't specifically docker related.
- Malfunctioning Modify shell startup files PBA on Docker. #1507 | |
- Unhandled error when "modify shell startup files PBA" is unable to find regular users. #1507 |
6f51b4c
to
1883ecd
Compare
1883ecd
to
dc1735e
Compare
What does this PR do?
Fixes #1507 and #1055 .
In docker container
/etc/passwd
doesn't have any regular users. The modify shell script searches for those kind of users and if it doesn't find it return empty list which then we send telemetry without any result making the post breach action to fail.Here we check if we have empty result from the running of command and send failed result with explanation.
PR Checklist
Testing Checklist
Explain Changes