This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
title = "gitleaks aws secrets config" | |
[[rules]] | |
description = "AWS Key ID" | |
regex = '''(A3T[A-Z0-9]|AKIA|AGPA|AIDA|AROA|AIPA|ANPA|ANVA|ASIA)[A-Z0-9]{16}''' | |
tags = ["key", "AWS"] | |
[[rules]] | |
description = "AWS Secret Key2" | |
regex = '''(?i)aws_secret_key=''' | |
tags = ["key", "AWS"] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import nimcrypto | |
import winim/clr except `[]` # https://s3cur3th1ssh1t.github.io/Playing-with-OffensiveNim/ <-- thank you so much, 2 hours googling I almost went crazy | |
#[ | |
All credit goes to @byt3bl33d3r (OffensiveNim) and @s3cur3th1ssh1t | |
nimble install winim nimcrypto zippy | |
nim c -d:danger -d:strip --opt:size rsrcDecryptAssembly.nim | |
slurp = "staticRead" will read the file and store it in the variable (.rdata) on compile time. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Credit and props to Manoel Abreu @reefbr - Thank you man! | |
# This one-liner uses dockerized gitleaks to detect a custom toml file with AWS access keys and secret | |
wget https://gist.githubusercontent.com/iknowjason/64914c08c0512f7380dbe7240812d69d/raw/6044896415ba9adc02a055fe774f67e31ecddad0/aws_key.toml; docker run --rm -v "$PWD:/script" -v <GIT_DIRECTORY_FULL_PATH>/:/code/ --name=gitleaks zricethezav/gitleaks -v detect -c=/script/aws_key.toml -p=/code |
OlderNewer