Skip to content
Connectors

Scanner deep dive

GitHub

SourceGAOpen source + Enterprise · Hosted or self-hosted

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

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 scope

Federal 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 matrix

What 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

  1. In 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.
  2. For 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

  1. Web setup offers public and private sources, public-only (no auth), or a GitHub Action.
  2. 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
GitHub configuration options
FieldWhat it doesType
endpointGitHub API endpoint; omit for GitHub Cloud.string
repositoriesExplicit repos to scan; omit to enumerate accessible repos.list
organizationsExplicit orgs to scan; omit to enumerate.list
scanUsersEnumerate org members and scan their public repos.boolean
includeForksInclude forked repositories.Default false.boolean
headHead branch for a diff-range scan.string
baseBase branch for a diff-range scan.string
ignoreReposRepositories to skip.list
includeReposRepositories to explicitly include.list
excludeArchivedExclude archived repositories.boolean
includePullRequestCommentsInclude pull request comments.boolean
scanAllInstallationsGitHub App: scan all installations instead of one installationId.boolean
includeIssueCommentsInclude issue comments.boolean
ignoreGistsSkip gist scanning entirely.boolean
includeGistCommentsInclude gist comments.boolean
skipBinariesSkip binary files.boolean
skipArchivesSkip archive files.boolean
includeWikisInclude repository wikis.boolean
clonePathScanner directory where repos are cloned.Default /tmp.string

Check the options in your installed version with trufflehog github --help.

  1. Select an approved repository with --repo. Anonymous public reads are rate limited. Prepare a token for private access or authenticated API use.
  2. Review 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

$ trufflehog github

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
trufflehog github flags
FlagWhat it doesType
--endpointGitHub endpoint.Default https://api.github.com.string
--repoGitHub repository to scan. You can repeat this flag. Example: "https://github.com/dustin-decker/secretsandstuff"strings
--orgGitHub organization to scan. You can repeat this flag. Example: "trufflesecurity"strings
--tokenGitHub token. Can be provided with environment variable GITHUB_TOKEN.string
--include-forksInclude forks in scan.bool
--include-membersInclude organization member repositories in scan.bool
--include-reposRepositories 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-wikisInclude repository wikis in scan.bool
--exclude-reposRepositories 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-pathsPath to file with newline separated regexes for files to include in scan.string
--exclude-pathsPath to file with newline separated regexes for files to exclude in scan.string
--issue-commentsInclude issue descriptions and comments in scan.bool
--pr-commentsInclude pull request descriptions and comments in scan.bool
--gist-commentsInclude gist comments in scan.bool
--comments-timeframeNumber of days in the past to review when scanning issue, PR, and gist comments.value
--use-graphqlUse 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-urlEmbed authentication credentials in repository URLs instead of using secure HTTP headersbool
--clone-pathCustom path where the repository should be cloned (default: temp dir).string
--no-cleanupDo 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-gistsIgnore all gists in scan.bool
--exclude-archivedExclude 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 permissions
  • reporead repository contents
  • gistread gists
  • read:orgread org membership

GitHub App

7 permissions · 1 write
  • Repository ContentsRead-only
  • Repository MetadataRead-only
  • Repository WebhooksRead and write
  • Repository IssuesRead-only
  • Repository Pull requestsRead-only
  • Organization MembersRead-only
  • Account 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

Docs OSS codeReviewed· 2026-12-01Version control systems · CI / CD pipelines

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.

GitHub (experimental CLI)