Home

Awesome

Leaky Repo 🚿

Table of contents

FAQ

What is this?

This is a repo full of mistakes. I will include several of the secrets I've seen commonly leaking from real projects. It will be useful for testing scanning tools such as github-dorks and truffleHog.

Where did you get these?

It's worth noting that none of the secrets here are real. They are all things I've seen before, but I've randomized or redacted all of the actual data. The vast majority of secrets will likely be taken from patterns created for github-dorks, which are primarily taken from config files for popular services. I've also worked on several scanning tools in the past. Most notably, github-dorks, PasteHunter, github-dorks, as well as GHScraper, and several other non-public or unreleased scanners. Essentially, I've seen a lot of whoopsies on git, which will also be included.

Why did you make this repo?

This repo was made to serve as a benchmark for secrets scanners. Repo scanning tools have varying levels of coverage, and so far the go-to option has been "slam a bunch together". This repo is also partially to test my theory that this technique still isn't really sufficient. Regardless, you can't just scan for high entropy, and you can't just scan for patterns, you need to do both!

How can I avoid uploading these secrets?

I've written a blog post on Why We Fail at Keeping Git Secrets. If you truly want to keep your secrets safe, seperate them from your repo. If that's a config file, that's fine. If it's a secrets management/storage system, that's even better. As long as you can stop git from adding that information by default, you're unlikely to hit any problems.

Secrets

FilenameDescription
.npmrcNPM registry authentication data
.dockercfgDocker registry authentication data
misc-keys/cert-key.pemPEM Private key
misc-keys/putty-example.ppkPuTTYgen private key
.ssh/id_rsaPrivate ssh key
.ssh/id_rsa.pubPublic ssh key (might still not be ideal)
db/dump.sqlMySQL dump w/ bcrypt hashes
cloud/.credentialsS3 Credentials file
cloud/.s3cfgS3 Credentials file
cloud/.tugboatDigital Ocean tugboat config
cloud/heroku.jsonHeroku config
web/var/www/public_html/wp-config.phpWordPress config file
web/var/www/public_html/.htpasswdhtpasswd file
web/var/www/public_html/config.phpPHP application config file
web/var/www/.envLaravel .env (CI, various ruby based frameworks too)
.git-credentialsGit credentials store
.bashrc.bashrc file (contains several secrets as environment variables)
.bash_profile.bash_profile file (contains several secrets as environment variables)
db/robomongo.jsonMongolab credentials for robomongo
db/mongoid.ymlMongoid config file
web/js/salesforce.jsSalesforce credentials in a nodejs project
.netrcnetrc with SMTP credentials
hubHub config that stores github tokens
filezilla/filezilla.xmlFilezilla config file
filezilla/recentservers.xmlFilezilla recent servers file
.docker/config.jsonDocker registry authentication file
configIRC config
db/.pgpassPostgreSQL file which contains passwords
/proftpdpasswdUsernames and passwords of proftpd created by cpanel
ventrilo_srv.iniVentrilo configuration
etc/shadowLinux /etc/shadow file
db/dbeaver-data-sources.xmlDBeaver config containing MySQL Credentials
/.esmtprcesmtp configuration
.mozilla/firefox/logins.jsonFirefox saved password collection (can be decrypted using keys4.db)
web/django/settings.pyDjango setup.py, contains valid secret key
web/ruby/secrets.ymlRuby on rails secrets.yml file (contains passwords)
ruby/config/master.keyRails master key (used for decrypting credentials.yml.enc for Rails 5.2+)
deployment-config.jsonCreated by sftp-deployment for Atom, contains server details and credentials
.ftpconfigCreated by remote-ssh for Atom, contains SFTP/SSH server details and credentials
.remote-sync.jsonCreated by remote-sync for Atom, contains FTP and/or SCP/SFTP/SSH server details and credentials
.vscode/sftp.jsonCreated by vscode-sftp for VSCode, contains SFTP/SSH server details and credentials
sftp-config.jsonCreated by SFTP for Sublime Text, contains FTP/FTPS or SFTP/SSH server details and credentials
.idea/WebServers.xmlCreated by Jetbrains IDEs, contains webserver credentials with encoded passwords (not encrypted!)
high-entropy-misc.txtMisc high entropy strings (HES1 is plain, HES2 is base64)

Results

We've tested a few tools and generated metrics for it. You can see how the tools tested so far stack up in Benchmarking
If there's a tool you'd like tested, please file an issue with details on it or create a PR. We are focused primarily on command-line based tools, but are also happy to accept results from web or GUI-based tools, as long as you include the full results and details about the tool.

Changelog

You can see recent changes made in our CHANGELOG.md file or under Releases. We use semantic versioning for releases.

Contact

Got a question? Found something worth adding?
File an issue
Have another reason to contact me? You can find me on Twitter:
@Plazmaz

It's also worth noting that many of the original patterns used to find the filenames and examples of several secrets came from github-dorks, which is under tha Apache 2.0 License. Also, for the sake of full disclosure, I am a maintainer on that project.