Updated Jul 14, 2026

Static Code Analysis

Hunt leaked secrets across GitHub orgs and URL responses

Scan GitHub orgs and URL responses for leaked secrets.

Agent

overview

What leakos does

leakos runs gitleaks and trufflehog against GitHub orgs, users, repos, and HTTP response bodies, then merges the findings. Scope with --github-orgs, --github-repos, --github-users, or feed --urls-file for response scanning.

Pass --github-token to cover org members and ease API limits. --only-verified keeps trufflehog-confirmed hits. Cap web work with --max-urls; extend patterns via --rex-regex-path. Skip an engine with --not-gitleaks or --not-trufflehog.

Use it when you need org-wide or response-wide secret hunting in one pass. For a single cloned repo history scan, run gitleaks or trufflehog alone. Trickest runs leakos as a managed node and writes FILE plus FOLDER output.

source github.com/carlospolop/leakos

use cases

Where leakos fits

Scan a GitHub org for leaked API keys

Give leakos an org name with --github-orgs and a token so it checks the org's and its members' repositories for exposed keys and credentials in one run.

Find secrets in web responses

Feed a file of URLs with --urls-file so leakos scans each response body for leaked tokens, useful against a surface a crawler mapped moments ago.

Keep findings to verified only

Enable --only-verified so leakos returns trufflehog-confirmed secrets, cutting noise when you need actionable results from a large scan.

Monitor an org for new leaks

Schedule the leakos node so each run re-scans the org and its members, surfacing secrets that landed in a commit since the last pass.

Extend detection with custom regexes

Supply your own regex file with --rex-regex-path so leakos matches organization-specific token formats alongside the built-in gitleaks and trufflehog checks.

reference

leakos inputs and flags

24 inputs
NameTypeFlagDescription
github-orgsSTRING--github-orgsGitHub org names to search (comma separated). Members are searched too.
github-reposSTRING--github-reposGitHub repos to search (comma separated).
github-tokenSTRING--github-tokenToken to access the GitHub API (no permissions required).
urls-fileFILE--urls-fileFile of URLs whose responses are searched for leaks.
only-verifiedBOOLEAN--only-verifiedReturn only verified leaks (uses trufflehog).
rex-regexesFILE--rex-regex-pathCustom regexes file for the rex engine.
max-urlsSTRING--max-urlsMaximum number of URLs to check.
threadsSTRING--threadsNumber of threads to use.

Showing key inputs. leakos exposes 24 inputs in total.

Full flag reference (24 inputs)
NameTypeFlagDescription
debugBOOLEAN--debugEnable debug output.
not-rexBOOLEAN--not-rexDo not run the rex regex checks.
threadsSTRING--threadsNumber of threads to use.
timeoutSTRING--tools-timeoutCustom timeout while executing the underlying tools.
max-urlsSTRING--max-urlsMaximum number of URLs to check.
not-extsSTRING--not-extsSkip URLs with these extensions (comma separated).
urls-fileFILE--urls-fileFile of URLs whose responses are searched for leaks.
github-orgsSTRING--github-orgsGitHub org names to search (comma separated). Members are searched too.
rex-regexesFILE--rex-regex-pathCustom regexes file for the rex engine.
github-reposSTRING--github-reposGitHub repos to search (comma separated).
github-tokenSTRING--github-tokenToken to access the GitHub API (requires no permissions).
github-usersSTRING--github-usersGitHub user names to search (comma separated).
not-gitleaksBOOLEAN--not-gitleaksDo not run the gitleaks checks.
avoid-sourcesSTRING--avoid-sourcesLowercase comma-separated list of trufflehog and gitleaks sources to skip.
only-verifiedBOOLEAN--only-verifiedReturn only verified leaks (uses trufflehog).
not-trufflehogBOOLEAN--not-trufflehogDo not run the trufflehog checks.
github-orgs-fileFILE--github-orgs-fileFile of GitHub org names to search.
github-repos-fileFILE--github-repos-fileFile of GitHub repos to search.
github-users-fileFILE--github-users-fileFile of GitHub user names to search.
max-secret-lengthSTRING--max-secret-lengthMaximum length of a valid secret.
add-org-repos-forksBOOLEAN--add-org-repos-forksCheck an org repo even if it is a fork.
generic-leak-in-webBOOLEAN--generic-leak-in-webAccept generic leaks in web responses (disabled by default).
add-user-repos-forksBOOLEAN--add-user-repos-forksCheck a user repo even if it is a fork.
from-trufflehog-only-verifiedBOOLEAN--from-trufflehog-only-verifiedFrom trufflehog, keep only verified leaks.

example

Run leakos

leakos · command
# scan a GitHub org and its members for verified secretsleakos --github-orgs example-org --github-token $GITHUB_TOKEN --only-verified --threads 10
sample output
[  {"source": "gitleaks", "repo": "example-org/payments-api", "file": "config/settings.py", "line": 42, "rule": "aws-access-token", "secret": "AKIA****************", "verified": false},  {"source": "trufflehog", "repo": "example-org/mobile-app", "file": ".env.staging", "line": 7, "rule": "SlackWebhook", "secret": "xoxb-****************", "verified": true},  {"source": "trufflehog", "url": "https://staging.example.com/static/app.js", "rule": "StripeApiKey", "secret": "sk_live_****************", "verified": true},  {"source": "gitleaks", "repo": "example-org/infra-scripts", "file": "deploy/backup.sh", "line": 15, "rule": "private-key", "secret": "-----BEGIN RSA PRIVATE KEY-----", "verified": false}]# 4 leaks (2 verified) across 3 repos and 1 URL

guidance

Choosing leakos

Use leakos to sweep a GitHub org or a set of web responses for leaked secrets in one pass, since it wraps both gitleaks and trufflehog. For scanning a single cloned repository's history directly, use gitleaks or trufflehog on their own.

gitleaks

Secret scanner for git repos. leakos drives it across whole orgs and merges findings with trufflehog.

trufflehog

Verified-secret scanner. leakos uses it as one engine; run it alone for a single source.

noseyparker

Fast secret and regex matcher over large inputs. Alternate engine for the same secret-hunting job.

faq

leakos questions

Set --github-orgs to the org name and pass --github-token. leakos checks the org's repositories and member repositories with gitleaks and trufflehog. Add --github-repos or --github-users to narrow the scope.

Run leakos yourself

A GitHub org feeds leakos, which scans its repositories with gitleaks and trufflehog and writes the discovered secrets as a queryable output.

Facts on this page come from the live Trickest tool library.