Skip to content

In-depth lesson · bug class

Leaked secrets and credentials

What every disclosed Leaked secrets report in the index teaches, put together: how it works, how it changed year by year, where it turns up, and things to try. Every point shows the reports it is seen in.

reports cited in this lesson
201

Learning Leaked secrets reading list Cloud and infrastructure, step 4Mobile apps, step 4

Overview

What it is and why programs pay for it.

Leaked secrets and credentials are sensitive values such as API keys, passwords, tokens or private keys that have been exposed through public repositories, client-side code, logs, configuration files or packaged applications. Programs care because these secrets can give attackers direct access to internal systems, customer data or infrastructure, often without needing to exploit a software flaw. The reports in this dataset show that such leaks are common and frequently lead to account takeover, data exposure or further compromise.

This class of issue usually arises from mistakes like hardcoding credentials in source code, committing secret files to public repositories, or failing to redact secrets from logs and build output. It is most often found in public GitHub repositories, JavaScript bundles served to browsers, mobile and desktop application packages, CI/CD logs, and publicly accessible configuration files on staging or production hosts. The evidence also includes leaks in smart contracts, chat channels, and web archives.

For a bug bounty hunter, leaked secrets are a high-value target because they can provide immediate access to systems and data, and demonstrating impact is often straightforward: show that the secret is live and what it can access. However, hunters must be careful to stay in scope and to avoid causing harm when validating credentials. The reports here include many examples where a leaked token or key was used to access repositories, cloud resources, admin panels or user data.

How it works

The mechanics, as the reports show them.

The process starts with reconnaissance: searching public sources for secrets. This includes scanning public repositories on platforms like GitHub for patterns that look like credentials, such as API keys, tokens, passwords or private keys. Hunters also examine client-side JavaScript files, mobile app packages, desktop applications, and publicly accessible configuration files. The evidence shows many cases where secrets were found in dotfiles, environment files, package registries, and even training PDFs.

Once a potential secret is found, the next step is to determine whether it is valid and what it can access. This often involves testing the secret against the relevant service's API or login endpoint, but carefully to avoid disruption. For example, a leaked GitHub token can be used to query the API for repository access; a cloud access key can be used to list permissions; a database credential can be tested for connectivity. The reports describe many such validation steps, such as checking a token's scope or using a vendor's key-check endpoint.

What makes this possible is that developers often embed secrets directly in code or configuration that is publicly accessible, or they fail to remove them from version control history, build logs, or packaged applications. Even when secrets are obfuscated or encoded, they can often be decoded. The evidence includes cases where secrets were Base64-encoded, hardcoded in firmware, or left in old commits. Additionally, some services do not enforce the same authentication controls (like MFA) on API access as they do on web login, making a leaked key more powerful.

The impact of a leaked secret depends on its privileges. A leaked API key might allow reading sensitive data, modifying resources, or sending messages on behalf of the application. A leaked cloud access key could lead to full cloud account takeover. A leaked session token could allow impersonating a user. The reports show impacts ranging from reading internal channels with a Slack token to full organisation takeover via a GitHub token, and from listing files in a cloud storage bucket to sending push notifications to all app users.

Hunters should also consider variations: secrets can leak through redirects that forward authentication headers to other hosts, through error messages that include connection strings, or through logs that print tokens. The evidence includes cases where credentials were leaked via HTTP redirects, API responses, and CI logs. Understanding these channels helps in finding leaks that are not just in source code.

Seen in these reports15

Show 5 moreShow fewer

Year by year

10 years

What each year's disclosed reports show, newest first. A year with few reports says less.

Reports per yearPeak 2025: 149
Reports per year
20121
20141
20151
20164
201712
20187
201911
202020
202123
202223
202332
202463
2025149
202680
  1. 2026

    80 reports

    Kept working3

    • Public GitHub repositories, dotfiles and package registries leaked credentials in the disclosed reports.
    • Hardcoded credentials in devices, appliances and enterprise products were reported across several reports in the disclosed reports.
    and 1 more

    Turned up less2

    • Testing credentials from breach dumps and bots on login pages is not repeated in the disclosed reports this year.
    • Searching public CI logs for unmasked tokens is not repeated in the disclosed reports this year.

    Reports from 20264

    Every point and report from 2026
  2. 2025

    149 reports · median $350

    New this year2

    • Testing credentials from breach dumps and bots on login pages first appears in the disclosed reports.
    • Public CI logs leaking tokens appear as a distinct pattern in the disclosed reports.

    Kept working2

    • Leaked secrets in public GitHub repositories and commit history appeared repeatedly in the disclosed reports.
    • Public repositories were searched for cloud access and secret keys and the privileges assessed in the disclosed reports.

    Turned up less2

    • Pulling public Docker images to search for cloud access keys is not repeated in the disclosed reports this year.
    • Scanning public JavaScript bundles for payment and media keys is not repeated in the disclosed reports this year.
  3. 2024

    63 reports · median $525

    New this year3

    • Pulling public Docker images to search for cloud access keys and database credentials first appears in the disclosed reports.
    • Scanning public JavaScript bundles with a secret scanner for payment and media keys first appears in the disclosed reports.
    • Looking for disused subdomains with dangling DNS records holding base64-encoded production secrets first appears in the disclosed reports.

    Kept working3

    • Hardcoded credentials in embedded and industrial devices recurred through the same vulnerability broker in the disclosed reports.
    • Leaked secrets in public GitHub repositories and commit history appeared repeatedly in the disclosed reports.
    and 1 more

    Turned up less2

    • Searching internal chat channels for pasted admin API tokens is not repeated in the disclosed reports this year.
    • Extracting a map provider token from client-side JavaScript and testing with a spoofed Referer is not repeated in the disclosed reports this year.
Every point, year by year

Where it is found

4

The features and places the reports found it in, most-reported first.

  1. Public GitHub repositories, dotfiles and package registries can leak credentials.

    Seen in 7 reports
  2. Client-side JavaScript bundles and configuration files can expose secrets.

    Seen in 5 reports
  3. A publicly reachable environment file on a staging subdomain held sensitive values in cleartext.

    Seen in 1 report
  4. Android application packages can contain embedded secrets.

    Seen in 1 report

Root causes

13

The mistakes in the code or configuration behind the reports.

  1. Developers hardcoded API keys and secrets directly into client-side JavaScript instead of keeping them server-side.

    Seen in 4 reports
  2. Employees committed credential files and dotfiles to public repositories.

    Seen in 4 reports
  3. Build scripts printed command output without redacting secrets, so tokens ended up in public CI build logs.

    Seen in 2 reports
  4. A live admin token was pasted into a team chat channel instead of being stored as a secret.

    Seen in 2 reports
  5. Credentials were exposed outside the company through reuse or third-party breaches rather than a flaw in its own systems.

    Seen in 2 reports
View all 13

Things to try

The most-reported tests in the largest contexts. Tick what you have tried; ticks stay in this browser and carry over to the full checklist. Test only what a program's scope allows.

ticked in this lesson

Public repository secret hunting

of 3 ticked
More in Public repository secret hunting

Client-side JavaScript and web bundles

of 3 ticked
More in Client-side JavaScript and web bundles

Mobile app binaries

of 3 ticked
More in Mobile app binaries

Configuration and environment files

of 3 ticked
More in Configuration and environment files
View more things to try

Bypasses and variations

1

How reports got past filters, encoders and other defences.

  1. A patch for hardcoded credentials can be bypassed with a variant attack.

    Seen in 1 report

Payouts

38 paid

Public bounties in US dollars, from the data. 38 of 490 reports show an amount.

a quarter paid up to
$500
median
$1,250
three quarters paid up to
$4,750
highest
$50k

One in ten paid reports was paid $6,950 or more.

SeverityReportsPaidMedianHighest
Critical 39 5 $5,000 $50k
High 38 5 $1,000 $6,500
Medium 46 9 $500 $2,000
Low 14 1 $250 $250
Informational 19 0 None paid None
Unrated 334 18 $2,500 $25k

Highest-paid reports5

Tips for beginners

14

Advice for a first hunt, drawn from the reports.

  1. Start by searching public repositories for common secret patterns. Use GitHub's code search or dedicated tools to look for strings like 'api_key', 'password', 'token', or file names like '.env', 'config.json', or 'id_rsa'. Focus on repositories belonging to the target organisation or its employees. The evidence shows many leaks in dotfiles, environment files, and configuration files.

    Seen in 3 reports
  2. Check client-side JavaScript bundles for hardcoded secrets. Modern web apps often include API keys for third-party services in their JavaScript. Look for strings that resemble keys, and test whether they are live and what they allow. Be aware that some keys are meant to be public (like some map tokens) but may still have insufficient restrictions.

    Seen in 3 reports
  3. Inspect mobile and desktop applications. Decompile Android APKs or unpack Electron apps to search for embedded credentials. The evidence includes many cases where API keys, tokens, and even private keys were found in app packages. Pay attention to third-party service credentials, which can sometimes be used to access data or send messages.

    Seen in 3 reports
  4. When you find a secret, validate it responsibly. Use the least intrusive method to confirm it is live, such as a read-only API call or a request to a key-check endpoint. Avoid actions that could modify or delete data, send messages, or disrupt services. Document exactly what you did and what access you gained.

    Seen in 3 reports
  5. Assess the full impact of the secret. Determine what permissions it has and what data it can access. For example, a cloud access key might allow listing buckets or reading objects; a GitHub token might allow accessing private repositories or modifying code. The more sensitive the access, the higher the severity.

    Seen in 3 reports
View all 14

Guides and techniques

View all

The best explainers, cheat sheets and technique posts on Leaked secrets, from around the web.

Keep learning

Where this lesson fits, and what to read next.

How this is made: our model read every listed Leaked secrets report in the index (our own summary where we have one, otherwise the title and the platform's label), listed the patterns, and merged them. Each point was kept only if the reports it cites exist, are listed and belong here; payouts are computed from the data, not written by the model. Read the originals before relying on a point. Generated 27 Nov 2026 from 286 reports. All Leaked secrets reports.