diff --git a/.gitignore b/.gitignore index ff2bd54..269e520 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ .*/ __pycache__ SlackPirate_*/ +.DS_Store diff --git a/SlackPirate.py b/SlackPirate.py index f1a0359..1e4fac8 100755 --- a/SlackPirate.py +++ b/SlackPirate.py @@ -88,12 +88,12 @@ r"|s3-[a-zA-Z0-9-\.\_\/]+" \ r"|s3.amazonaws.com/[a-zA-Z0-9-\.\_]+" \ r"|s3.console.aws.amazon.com/s3/buckets/[a-zA-Z0-9-\.\_]+)" -# https://regex101.com/r/DoPV1M/1 +# https://regex101.com/r/DoPV1M/3 CREDENTIALS_REGEX = r"(?i)(" \ - r"password\s*[`=:\"]+\s*[^\s]+" \ - r"|password is\s*[`=:\"]+\s*[^\s]+" \ - r"|pwd\s*[`=:\"]+\s*[^\s]+" \ - r"|passwd\s*[`=:\"]+\s*[^\s]+)" + r"password\s*[`=:\"]+\s*[^\s]+|" \ + r"password is\s*[`=:\"]*\s*[^\s]+|" \ + r"pwd\s*[`=:\"]*\s*[^\s]+|" \ + r"passwd\s*[`=:\"]+\s*[^\s]+)" # https://regex101.com/r/IEq5nU/4 AWS_KEYS_REGEX = r"((?