Scanner deep dive
GitHub
The GitHub integration scans repositories, gists, issues, and pull requests on GitHub Cloud or GitHub Enterprise Server for credentials and other sensitive data.
Unauthenticated public-repository scans or authenticated scans of permitted repositories
Use cases and coverage
Scanning use cases
Review a private repository before making it public
Authenticate with access to the private repository and scan its history before changing visibility. Use the reported commit and path to locate credentials, including those in earlier file versions.
Check credentials pasted into a code review
Enable pull request and issue comment scanning for the repository. Include those conversations when reviewing copied commands or troubleshooting output.
Related incidentUber’s cloud access key in a private repository · Exposure location
2016 · Exposure location
Uber’s cloud access key in a private repository
The FTC’s revised complaint says an AWS key in Uber’s private GitHub repository was used to download files from S3.
How this relates to GitHub
The complaint places the key in repository code. Including private repositories in a source review addresses that exposure location.
Review GitHub scan scopeFederal Trade Commission report · 2016 Data Breach, paragraph 24
Source check
Atlas AI-assisted source check · 2026-11-22. The publisher describes the event or study. The Atlas explains its relevance to this connector. Detection depends on the scan scope and detectors in use.
What it covers
Compare in matrixWhat the docs page’s Capabilities table says, sorted into what the source reaches, how deep it reads and how it runs. Hatched segments and dashes are capabilities the page doesn’t mention. Select ⓘ for what each one means.
- repositories
- gists
- issues
- pull requests
What it reaches
5 supported · 1 not documented
- History✓
- Comments✓
- Archived repositories✓
- Gists✓
- Forks✓
- Attachments–
How deep it reads
3 supported · 1 not documented
- Archives✓
- Binaries✓
- Base64✓
- Office docs–
How it runs
3 supported · 2 qualified · 1 not documented
- Filters✓
- Pre-commitCLI hook
- Pre-receiveCLI hook
- In CI✓
- Auto-resume✓
- Real-time–
Limits
Caveats the docs page states, like size caps or content it skips.
- Diffs larger than 1 GB are not scanned.
- Scanning in GitHub Actions is supported with extra setup.
- Personal access tokens must be classic; fine-grained tokens aren't supported.
- Use GitHub Real-time for push events as they happen.
- Gists are scanned by default unless ignoreGists is true, an explicit repositories list is set, or organizations is set with scanUsers false.
- One GitHub App can cover several accounts: add one source per account, each with that account's installationId and a unique name.
What TruffleHog documents
- Integration guide
Public source accepts individual public repositories or organizations without authentication. For an installed GitHub App, empty repository filters include everything the installation can access.
Read the GitHub integration guide- Open-source CLI
Issue comments, pull request comments, gist comments and repository wikis have separate CLI options. A comment scan can also be limited to a recent time window.
Read the pinned README passage
Sources checked .
Other vendors
What GitHub documents its own secret scanning covering on this platform.
GitHub Secret Protection
- Git history on all branches✓
- Issue descriptions and comments✓
- Pull request titles, descriptions and comments✓
- GitHub Discussions✓
- Wikis✓
- Secret gists✓
- GitHub Actions workflow logspreview, opt-in
GitHub-hosted content only. Secret scanning is free for public repositories on GitHub.com. Organizations on GitHub Team or GitHub Enterprise Cloud can enable GitHub Secret Protection for private or internal repositories. Actions workflow log scanning is an opt-in public preview that only detects provider patterns.
Source: GitHub, about secret scanning.
Scan setup and permissions
Set it up
Pick how you’ll run it: each tab has its steps and its options. Enterprise paths come from Truffle’s public docs. The open-source CLI is read from the public TruffleHog code at a pinned commit; it’s a separate product from Enterprise.
Web interface or local configuration
- 1In the web setup, choose a public source to scan named public repositories without authentication. Choose public and private sources when access to private repositories is needed.
- 2For the authenticated route, agree on which repositories the GitHub App may access. The local configuration also documents a classic personal access token.
Suggested contact (Atlas suggestion) · GitHub organization owner or repository administrator
Suggested first check (Atlas suggestion) · Check the repository list against the GitHub App installation or the selected public scope.
Setup reference checked 2026-11-22 · Web Configuration
In the web UI
- Web setup offers public and private sources, public-only (no auth), or a GitHub Action.
- Hosted setup creates a GitHub App and lets you pick all or selected repositories.
Config file options (19)
Options for sources.GitHub in a local YAML config. Required fields come first.
All 19 config options0 required
| Field | What it does | Type |
|---|---|---|
endpoint | GitHub API endpoint; omit for GitHub Cloud. | string |
repositories | Explicit repos to scan; omit to enumerate accessible repos. | list |
organizations | Explicit orgs to scan; omit to enumerate. | list |
scanUsers | Enumerate org members and scan their public repos. | boolean |
includeForks | Include forked repositories.Default false. | boolean |
head | Head branch for a diff-range scan. | string |
base | Base branch for a diff-range scan. | string |
ignoreRepos | Repositories to skip. | list |
includeRepos | Repositories to explicitly include. | list |
excludeArchived | Exclude archived repositories. | boolean |
includePullRequestComments | Include pull request comments. | boolean |
scanAllInstallations | GitHub App: scan all installations instead of one installationId. | boolean |
includeIssueComments | Include issue comments. | boolean |
ignoreGists | Skip gist scanning entirely. | boolean |
includeGistComments | Include gist comments. | boolean |
skipBinaries | Skip binary files. | boolean |
skipArchives | Skip archive files. | boolean |
includeWikis | Include repository wikis. | boolean |
clonePath | Scanner directory where repos are cloned.Default /tmp. | string |
Check the options in your installed version with trufflehog github --help.
- 1Select an approved repository with --repo. Anonymous public reads are rate limited. Prepare a token for private access or authenticated API use.
- 2Review which optional comments or wikis you want included. The command has separate flags for those content types.
Suggested contact (Atlas suggestion) · GitHub repository or organization owner
Suggested first check (Atlas suggestion) · Check the pilot repository and the identity’s reach before enabling additional content.
Setup reference checked 2026-11-22 · github command declaration
Find credentials in GitHub repositories. pkg/sources/github · main.go line 121
Open-source TruffleHog, read from the public code at commit ffdee00 (v3.99.9-6-gffdee00a). Newer releases may differ.
All 21 CLI flagsNone required
| Flag | What it does | Type |
|---|---|---|
| --endpoint | GitHub endpoint.Default https://api.github.com. | string |
| --repo | GitHub repository to scan. You can repeat this flag. Example: "https://github.com/dustin-decker/secretsandstuff" | strings |
| --org | GitHub organization to scan. You can repeat this flag. Example: "trufflesecurity" | strings |
| --token | GitHub token. Can be provided with environment variable GITHUB_TOKEN. | string |
| --include-forks | Include forks in scan. | bool |
| --include-members | Include organization member repositories in scan. | bool |
| --include-repos | Repositories to include in an org scan. This can also be a glob pattern. You can repeat this flag. Must use Github repo full name. Example: "trufflesecurity/trufflehog", "trufflesecurity/t*" | strings |
| --include-wikis | Include repository wikis in scan. | bool |
| --exclude-repos | Repositories to exclude in an org scan. This can also be a glob pattern. You can repeat this flag. Must use Github repo full name. Example: "trufflesecurity/driftwood", "trufflesecurity/d*" | strings |
| --include-paths | Path to file with newline separated regexes for files to include in scan. | string |
| --exclude-paths | Path to file with newline separated regexes for files to exclude in scan. | string |
| --issue-comments | Include issue descriptions and comments in scan. | bool |
| --pr-comments | Include pull request descriptions and comments in scan. | bool |
| --gist-comments | Include gist comments in scan. | bool |
| --comments-timeframe | Number of days in the past to review when scanning issue, PR, and gist comments. | value |
| --use-graphql | Use the GitHub GraphQL API to scan issue and PR comments. Faster on large repositories. Needs a token and --issue-comments or --pr-comments. | bool |
| --auth-in-url | Embed authentication credentials in repository URLs instead of using secure HTTP headers | bool |
| --clone-path | Custom path where the repository should be cloned (default: temp dir). | string |
| --no-cleanup | Do not delete cloned repositories after scanning (can only be used with --clone-path). Each clone is kept in its own directory, so ensure sufficient disk space: usage grows with every repository scanned and every run. | bool |
| --ignore-gists | Ignore all gists in scan. | bool |
| --exclude-archived | Exclude archived repositories from scan. | bool |
Access
Choose how the scanner connects. The permission lists below apply to authenticated integration setup.
Scan access modes
- Unauthenticated
- Choose Public source in the web integration to review public repositories your team maintains. The open-source CLI also supports public repositories without a token. GitHub applies lower API rate limits to anonymous requests.
- Authenticated
- Use a GitHub App installation or a classic personal access token for the Enterprise integration. The CLI accepts a GitHub token. The identity can access public repositories and the private repositories its permissions allow.
GitHub integration access choicesGitHub CLI token handlingUnauthenticated GitHub scopeChecked 2026-11-22
1 write permission: Repository Webhooks (GitHub App).
Authenticated integration methods
- Bearer token
- GitHub App
Classic personal access token
3 permissionsreporead repository contentsgistread gistsread:orgread org membership
GitHub App
7 permissions · 1 writeRepository ContentsRead-onlyRepository MetadataRead-onlyRepository WebhooksRead and writeRepository IssuesRead-onlyRepository Pull requestsRead-onlyOrganization MembersRead-onlyAccount GistsRead-only
If GitHub keys leak
The credentials you give this connector are secrets too. These detectors find GitHub keys anywhere TruffleHog scans, not only inside GitHub.
Recent changes
From TruffleHog’s release notes, after review. Tags show whether each change is in Enterprise, open source, or both.
11 release-note items mention this connector. The Atlas hasn’t checked them yet, so they aren’t listed here. See all release notes
Sources and related tools
Evidence
Possible issue in Truffle’s docs
- The Capabilities table lists Pre-commit and Pre-receive. These are hooks run with the TruffleHog CLI in a Git workflow, not features of the Enterprise source integration.
Shown here as the docs state it. All docs issues.
Docs scraped 2026-11-17. Each docs page was fetched with Firecrawl twice (an overview pass and a detail pass for capabilities, options, permissions and notes) and read by an extraction prompt. Descriptions are short paraphrases. Open-source CLI facts are parsed from main.go at the pinned TruffleHog commit. Not reviewed by a person. Pinned commit ffdee00. Check the source before quoting a detail, or review this connector so the badge says so.
- Source docs pageUpdated 24 Nov 2026
- Open-source packagepkg/sources/github
- Sources indexStatus, edition, deployment
- Category grouping