Skip to content
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

AWS Session Key not being matched #2771

Open
domwhewell-sage opened this issue May 1, 2024 · 3 comments
Open

AWS Session Key not being matched #2771

domwhewell-sage opened this issue May 1, 2024 · 3 comments
Labels

Comments

@domwhewell-sage
Copy link

Please review the Community Note before submitting

TruffleHog Version

3.74.0

Trace Output

https://gist.github.com/domwhewell-sage/66c6ce77f372d958dbbae7fdde4e6a0f

Expected Behavior

Session Key is detected

Actual Behavior

No secrets are detected

Steps to Reproduce

  1. Paste a AWS session token into a .txt file
  2. Run trufflehog filesystem <path_to_file>.txt against it

Environment

  • OS: Kali
  • Version 2023.3

Additional Context

Looking at the regex in awssessionkey.go, the sessionPAT seems to not match the == from the session token

References

N/A

@domwhewell-sage
Copy link
Author

As suggested on slack I have run the commands mentioned here and cannot see any errors #2620 (comment)

I have added the result as a comment to my gist

@rgmz
Copy link
Contributor

rgmz commented May 1, 2024

As suggested on slack I have run the commands mentioned here and cannot see any errors #2620 (comment)

The lack of those print statements mean that it's not being picked up by the detector at all. This indicates that there's an error with the keywords, pattern, or perhaps the verification overlap change (#2356, #2515 (comment)).

@domwhewell-sage
Copy link
Author

If it helps the regex here works for session tokens obtained via aws sts get-session-token but does not work for session tokens obtained from aws sts assume-role

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

No branches or pull requests

2 participants