-
Notifications
You must be signed in to change notification settings - Fork 56
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
Fix harcoded password rds rule #79
Conversation
from cfripper.model.result import Result | ||
from cfripper.model.utils import convert_json_or_yaml_to_dict |
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.
these imports have been imported in but don't seem to be used in the test file
if master_user_password == Parameter.NO_ECHO_WITH_DEFAULT: | ||
self.add_failure(type(self).__name__, self.REASON_DEFAULT.format(resource_type, logical_id)) | ||
return True | ||
elif master_user_password not in (Parameter.NO_ECHO_NO_DEFAULT, Parameter.NO_ECHO_WITH_VALUE,): |
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.
comma at end of line here
@@ -19,29 +19,22 @@ | |||
|
|||
class HardcodedRDSPasswordRule(Rule): | |||
|
|||
REASON = "Default RDS {} password parameter or missing NoEcho for {}." | |||
REASON_DEFAULT = "Default RDS {} password parameter (readable in plain-text) {}." |
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 would change to (readable in plain-text) for {}.
:)
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.
nice stuff Oscar :)
Changed
HardcodedRDSPasswordRule
now reports two different messages when there is a missing echo or a readable password.Fixes
HardcodedRDSPasswordRule
was wrongly adding an error when a value is provided.