OSINTverse

otinstaller · Secrets and cloud

Install TruffleHog on Windows, macOS, or Linux in one command

TruffleHog finds leaked credentials and then tests them. For hundreds of credential types it asks the service whether the key still works, so you know which findings matter. It scans git history, GitHub organisations, file systems, S3 buckets and more.

TruffleHog in three lines

curl -fsSL https://otinstaller.com/install.sh | sh
ot install trufflehog
ot run trufflehog git https://github.com/example/repo --results=verified

On Windows, replace the first line with irm https://otinstaller.com/install.ps1 | iex in PowerShell.

Runs trufflesecurity/trufflehog (AGPL-3.0, ★ 30k, otinstaller 0.3.0). otinstaller installs it as a release binary, pinned to version 3.100.1; it does not change or audit the tool itself.

What TruffleHog is for

  • Finding credentials in git history and telling which still work.
  • Scanning a whole GitHub organisation.
  • Checking a folder or an S3 bucket before it is shared.

Run TruffleHog with ot

ot run trufflehog passes everything after the tool's name to TruffleHog unchanged, with input and output passed through, so the project's own documentation applies and tools pipe into each other.

Scan a repository and show only credentials that still work.
ot run trufflehog git https://github.com/example/repo --results=verified
Scan every repository of a GitHub organisation.
ot run trufflehog github --org=example
Scan a folder and print JSON.
ot run trufflehog filesystem ./project --json

Where the results go

ot run saves nothing itself: TruffleHog's output goes to your terminal, a pipe, or wherever its own output option writes it. Results can hold personal data, so store and share them accordingly.

Before you run it

  • Verification sends each found key to the service it belongs to. That is a login attempt with someone's credential, so scan only what you are authorised to.
  • --results=verified hides unverified findings, which may still be real.

Update, remove, inspect

ot info trufflehog              # details, and how it installs on this system
ot update trufflehog            # move to the version the registry pins
ot update trufflehog --latest   # take the newest upstream release instead
ot remove trufflehog            # remove it

Full reference: the otinstaller docs, TruffleHog on otinstaller.com, and the tool's own project page.

Pairs with

gitleaks scans a git repository's whole history, or any directory, for passwords, API keys and tokens.
cariddi crawls the URLs you give it and looks at what it passes on the way: endpoints with interesting parameters, API keys and tokens left in pages, error messages, and files with extensions worth a second look.
S3Scanner checks whether storage buckets exist and what an anonymous visitor may do with them: list, read or write.

When open-source isn't enough

TruffleHog finds secrets in code you can read. SearchIn's breach providers show where an organisation's credentials already appear in leaks.

Breach intelligence
Breach intelligence

FAQ

TruffleHog with otinstaller, answered

How do I install TruffleHog on Windows, macOS, or Linux?

Install ot once with the one-line script on the otinstaller page, then run ot install trufflehog. Ot downloads the project's release binary for your system and checks its SHA-256 hash before it installs anything, at version 3.100.1. ot itself needs no administrator rights, and ot doctor checks that every installed tool starts.

How do I run TruffleHog through ot?

With ot run trufflehog followed by TruffleHog's own arguments, for example: ot run trufflehog git https://github.com/example/repo --results=verified. ot passes everything after the tool's name straight through and exits with the tool's exit code, so the project's own documentation applies unchanged. Add ~/.ot/bin to your PATH to call the tool by its own name.

Is TruffleHog part of ot scan?

No. ot scan takes a username, an email address, a domain, or a phone number and runs the tools the registry assigns to that kind of target. Run TruffleHog on its own with ot run trufflehog.

Does TruffleHog need an API key or a login?

ot stores no key for it. Verification sends each found key to the service it belongs to. That is a login attempt with someone's credential, so scan only what you are authorised to.

Does TruffleHog send traffic to the target?

The registry lists TruffleHog as passive: it does not probe the target's own systems. Options that do contact the target, where the tool has them, are named under "Before you run it".