appsec.fyi

Secrets & Credential Leaks Resources

Post Share

A curated AppSec resource library covering XSS, SQLi, SSRF, IDOR, RCE, XXE, OSINT, and more.

Secrets & Credential Leaks

Secrets management and credential leak prevention address one of the most common and impactful security failures in modern software development. Hardcoded API keys, database passwords, cloud credentials, and private keys regularly appear in source code repositories, CI/CD configurations, container images, client-side JavaScript, and log files. Tools like TruffleHog, GitLeaks, and GitHub Secret Scanning detect exposed credentials in repositories, while vault solutions like HashiCorp Vault, AWS Secrets Manager, and cloud KMS services provide secure runtime secret injection. The impact of leaked credentials can be devastating — exposed AWS keys can lead to full cloud account compromise within minutes, and leaked database credentials can result in complete data breaches. Prevention requires secrets scanning in CI/CD pipelines, pre-commit hooks, environment-based secret injection, and credential rotation policies.

Date Added Link Excerpt
2026-05-08 NEW 2026How to mitigate secrets risk and prevent future breaches intermediateLibrary for detecting and managing secrets risk in code. It details how leaks of credentials, tokens, and signing keys in open source and proprietary repositories are a growing concern, with millions exposed on platforms like GitHub and npm. The library aids in situational awareness by identifying exposed secrets, understanding their purpose, and assessing their potential impact. It emphasizes investing in advanced tooling to filter false positives and prioritize active tokens, alongside evolving development practices to mitigate risks from the design stage forward, ultimately aiming to prevent future breaches. → reversinglabs.com
2026-05-06 NEW 2026Secrets security: The why the how and what to do about it beginnerReport detailing the epidemic of secrets exposed in software repositories, explaining how attackers exploit exposed environment variables, tokens, and keys on platforms like PyPI, npm, and GitHub, and offering guidance on mitigation strategies. It highlights the speed at which attackers find these secrets, often within seconds, and the long discovery times for security teams, referencing examples of exposed AWS credentials and discussions of defense-in-depth approaches to software supply chain security. → reversinglabs.com
2026-05-05 NEW 2026Secrets leaks increase and expand beyond the codebase newsLibrary for detecting secrets leaks, focusing on increased risks beyond codebases in collaboration and project management tools like Slack, Jira, and Confluence. It highlights that secrets found in these platforms are often more critical and harder to detect than those in source code, as these tools typically lack integrated scanning capabilities. The library aims to address this gap by providing solutions for monitoring these unstructured data streams, acknowledging that traditional scanning methods optimized for code repositories are insufficient. → reversinglabs.com
2026-05-04 2026Local Guardrails for Secrets Security in the Age of AI Coding Assistants beginner AI Supply ChainLibrary for local secrets security scanning, ggshield, enables developers to detect and prevent accidental credential exposure directly within their workflows. It addresses the shifting attack surface towards developer workstations, encompassing AI coding assistants, local caches, and environment files. The tool scans project workspaces, dotfiles, build output, and agent folders to catch sensitive data before it propagates to repositories or pipelines, mitigating risks like those seen in npm, PyPI, and Docker Hub campaigns. → blog.gitguardian.com
2026-05-02 2026Cursor AI Flaw Lets Hackers Steal API Keys and Run Code Silently news API Sec RCELibrary for securing AI-powered development tools, addressing critical vulnerabilities in Cursor AI where extensions can steal API keys and session tokens from an unencrypted SQLite database, and CVE-2026-26268 allows silent code execution via Git hooks and AI agent interactions. Researchers from LayerX and Novee discovered these flaws, emphasizing risks of financial loss, code exposure, and unauthorized access to cloud systems due to inadequate extension isolation and insecure credential storage, leaving developers at ongoing risk without a full architectural fix.
2026-05-02 2026Shai-Hulud Hits SAP: Stolen Credentials Found in 1200 GitHub Repos news Supply ChainLibrary variant of the Shai-Hulud worm targets SAP npm packages, exfiltrating developer credentials, tokens, and cloud configurations from over 2.2 million monthly downloads. The malware silently uploads this sensitive data, encrypted via AES-256-GCM and RSA-OAEP, to over 1,200 public GitHub repositories. Affected users are advised to immediately rotate keys, enforce two-factor authentication, upgrade packages, and treat compromised machines as fully breached. → ox.security
2026-05-01 2026New software supply chain attack uses sleeper packages for credential theft and CI tampering news Supply ChainLibrary for detecting sleeper packages in software supply chains that steal credentials, tamper with GitHub Actions, and establish SSH persistence. These malicious Ruby gems and Go modules, observed in campaigns attributed to "BufferZoneCorp," operate through init functions, manipulate environment variables, and place fake executables in cache directories to intercept commands and exfiltrate sensitive data like SSH keys and configuration secrets to attacker-controlled endpoints. → scworld.com
2026-05-01 2026Supply chain attack against SAP npm packages facilitates credential theft news Supply ChainLibrary that identifies a supply chain attack targeting SAP npm packages, including compromised versions like @cap-js/db-service, @cap-js/postgres, and @cap-js/sqlite. The attack, noted by Aikido Security and others, involved a pre-install script exfiltrating developer credentials, GitHub and npm tokens, cloud secrets, and Kubernetes secrets via AES-256-CGM. The payload also auto-commits to accessible GitHub repositories. → scworld.com
2026-04-29 2026Supply Chain Campaign Targets SAP npm Packages with Credential-Stealing Malware news Supply ChainLibrary that installs malicious preinstall scripts in SAP-related npm packages, such as `@cap-js/sqlite` and `@cap-js/postgres`, to steal developer and CI/CD secrets. The "Mini Shai Hulud" campaign, attributed to TeamPCP, uses a multi-stage payload to harvest credentials from GitHub, npm, and cloud providers, exfiltrating data via GitHub repositories. It also features browser credential theft and propagation logic. → wiz.io
2026-04-28 2026FIRESIDE CHAT: Leaked secrets are now the go-to attack vector and AI is accelerating exposures news AISurvey of escalating leaked secrets as attack vectors, exacerbated by AI. GitGuardian reports a 34% year-over-year jump in exposed credentials in 2025, with AI infrastructure driving the fastest-growing categories, including OpenRouter and DeepSeek API keys. The rise of AI-assisted coding, where commits co-signed by AI show significantly higher secret exposure rates, necessitates a governance-first approach to remediate this growing threat. → securityboulevard.com
2026-04-28 2026ClickUp is leaking customer data via hardcoded API key researcher claims news API SecA researcher claims ClickUp is leaking customer data due to a hardcoded API key. This vulnerability could expose sensitive information. The article does not mention any specific bug bounty payout amount. → cybernews.com
2026-04-28 2026ClickUp Hardcoded API Key Exposes 959 Emails from Fortune 500 Giants news API SecA hardcoded API key in ClickUp, a popular project management tool used by Fortune 500 companies, led to the exposure of 959 client email addresses. The vulnerability, discovered by security researcher Gavin Wray, allowed unauthorized access to this sensitive data. While the content doesn't specify a bounty amount, the incident highlights the critical importance of secure coding practices and API key management, especially for platforms handling data from major corporations. → cyberpress.org
2026-04-28 2026An open-source package with over 1 million monthly downloads has a vulnerability that has been exploited to distribute malware-infected versions and steal user credentials. news Supply ChainWriteup of a supply chain attack on Elementary Open Source Python CLI v0.23.3, an open-source package with over one million monthly downloads. An attacker exploited a vulnerability in a developer account to distribute a malware-infected version, leading to the theft of user credentials, API tokens, and SSH keys. The affected version was quickly removed, and the developers recommend immediate uninstallation, cache clearing, credential rotation, and security team contact for affected users.
2026-04-27 2026Claude Code is leaking API keys into public package registries news Supply ChainWriteup on Claude Code API token leak, detailing how the AI assistant caches approved terminal commands containing sensitive credentials in `.claude/settings.local.json`. This hidden file, if not excluded from package builds, can expose API keys to public registries like npm. The vulnerability impacts various packaging ecosystems and bypasses traditional secret scanning tools, necessitating manual exclusion from `.npmignore` and `.gitignore`, or automated pipeline checks for enterprises.
2026-04-22 2026UNC6426 Exploits nx npm Supply-Chain Attack to Gain AWS Admin Access in 72 Hours newsWriteup of UNC6426's nx npm supply-chain attack, detailing how a compromised GitHub token and an overly permissive AWS OIDC trust were exploited to gain full AWS administrator access within 72 hours. The attack involved leveraging the `nx` package, the `pull_request_target` vulnerability, and the QUIETVAULT credential stealer, with reconnaissance aided by the Nord Stream tool. Recommendations include sandboxing package managers, applying least privilege to CI/CD roles, and enforcing fine-grained PATs. → thehackernews.com
2026-04-22 2026The State of Non-Human Identity Security (CSA Survey Report) beginnerSurvey report detailing the state of non-human identity (NHI) security, including bots, API keys, and service accounts. It reveals that only 15% of organizations are highly confident in preventing NHI attacks, with major pain points in managing service accounts, auditing, and access management. The report highlights that 20% of organizations have formal processes for API key offboarding, and many use tools not purpose-built for NHIs, though investment in NHI security capabilities is increasing.
2026-04-22 2026Secrets Management in 2026: Vault, AWS Secrets Manager, and Beyond beginnerLibrary for understanding 2026 secrets management trends, comparing HashiCorp Vault, AWS Secrets Manager, Doppler, and Infisical. It highlights the shift from static to dynamic secrets, the importance of identity-based access, and the role of Kubernetes operators like External Secrets Operator. The library guides selection based on factors like multi-cloud needs, AWS dependency, developer experience priorities, and self-hosting requirements.
2026-04-22 2026GitHub Secret Scanning 2026: New Patterns, Push Protection beginnerLibrary for GitHub Secret Protection offers enhanced detection of leaked secrets with 28 new patterns across 15 providers, expanded push protection for 39 token types, and AI-powered generic password detection via Copilot. Available to GitHub Team plan customers at $19 per month per active committer, it includes validity checks and improved API visibility. This solution aims to prevent credential-related breaches, which cost an average of $4.88 million, by blocking pushes of sensitive information like Supabase service keys and Vercel API tokens before they reach repositories.
2026-04-22 2026Top 10 Non-Human Identity Security Tools and Platforms for 2026 beginnerLibrary for detecting and preventing non-human identity (NHI) security risks, specifically addressing hardcoded API keys, overprivileged service accounts, stale OAuth tokens, and misconfigured workload identities. It offers comprehensive discovery, exposure detection across git history and CI/CD pipelines, lifecycle management, authorization and least privilege enforcement, and governance features to aid compliance with standards like SOC 2 and ISO 27001. This tool targets large DevSecOps organizations to secure complex, multi-cloud, and ephemeral workloads. → blog.gitguardian.com
2026-04-22 2026CVE-2026-5807: HashiCorp Vault DoS via Unauthenticated Root Token Generation newsAdvisory on CVE-2026-5807 detailing a denial-of-service vulnerability in HashiCorp Vault. Unauthenticated attackers can exploit this by repeatedly initiating or canceling root token generation or rekey operations, preventing legitimate users from accessing these critical functions. This flaw is resolved in Vault Community Edition 2.0.0 and Vault Enterprise 2.0.0. GitLab Dependency Scanning can detect and mitigate this specific vulnerability. → advisories.gitlab.com
2026-04-22 2026CVE-2026-3605: HashiCorp Vault KVv2 Metadata Policy Bypass (DoS) newsAdvisory for CVE-2026-3605 details a HashiCorp Vault KVv2 metadata policy bypass vulnerability. Authenticated users with specific glob policies can delete secrets outside their authorized scope, leading to a denial-of-service condition. The vulnerability does not permit cross-namespace deletion or unauthorized data reading. Patches are available in Vault Community Edition 2.0.0, Vault Enterprise 2.0.0, 1.21.5, 1.20.10, and 1.19.16. → advisories.gitlab.com
2026-04-22 2026AI Is Fueling Secrets Sprawl: GitGuardian Reports 81% Surge of AI-Service Leaks newsReport detailing GitGuardian's findings on secrets sprawl, highlighting an 81% surge in AI-service leaks and a 34% YoY increase in newly leaked secrets on GitHub due to AI adoption. The analysis covers increased risk from AI-assisted commits, emerging MCP configuration risks, expanded attack surfaces via collaboration tools and developer machines, and challenges in prioritizing and remediating long-lived secrets, underscoring the need for dedicated Non-Human Identity governance. → blog.gitguardian.com
2026-04-22 2026HCSEC-2026-08: Vault DoS via Unauthenticated Root Token Generation newsBulletin detailing CVE-2026-5807, a denial-of-service vulnerability in HashiCorp Vault Community and Enterprise editions up to v1.21.4. Unauthenticated attackers can exploit the `sys/rekey`, `sys/generate-root`, and `sys/rekey-recovery-key` endpoints to repeatedly initiate or cancel root token generation or rekey operations, locking out legitimate users. This issue is resolved in Vault 2.0.0.
2026-04-22 2026HCSEC-2026-05: Vault KVv2 Metadata Policy Bypass DoS newsWriteup of CVE-2026-3605, a denial-of-service vulnerability in HashiCorp Vault KVv2. An authenticated user with specific policy configurations could delete secrets they weren't authorized for, leading to potential service disruption. This issue affected versions up to 1.21.4 and was fixed in Vault Community Edition 2.0.0 and various Vault Enterprise versions.
2026-04-19 2026Compromised IAM Credentials Power Large AWS Crypto Mining Campaign newsAnalysis of an AWS crypto mining campaign details how attackers use compromised IAM credentials, including admin-like privileges, to gain access. The multi-stage attack involves credential validation via `RunInstances` with `DryRun`, role creation for ECS and Lambda, and deployment of malicious Docker images like `yenik65958/secret:user`. Persistence is achieved using `ModifyInstanceAttribute` to disable API termination and by creating Lambda functions. This campaign highlights the sophisticated use of AWS services for illicit cryptocurrency mining and the importance of strong IAM controls, temporary credentials, MFA, and least privilege. → thehackernews.com
2026-04-19 2026Pre-Commit Hooks for Secret Detection: Setup in 10 Minutes intermediateLibrary for implementing pre-commit hooks to prevent secrets from entering Git history. It details the setup process for tools like gitleaks, detect-secrets, and TruffleHog, offering solutions for immediate detection and blocking of credential leaks. The library emphasizes catching secrets at the cheapest point in the lifecycle, preventing the need for costly history rewrites and incident response by integrating these tools seamlessly into the Git commit workflow.
2026-04-19 2026Understanding Your Organization's Exposure to Secret Leaks — GitHub beginnerLibrary for assessing an organization's exposure to secret leaks, highlighting that over 39 million secrets were detected on GitHub in 2024 alone. This resource details how secrets like API keys and passwords are leaked through repository commits or misconfigurations, referencing the $4.88 million average cost of credential compromise breaches and the 2022 LastPass breach. It provides methods for quantifying risk, including inventory audits and benchmarking against OWASP ASVS and NIST guidelines, and mentions GitHub's secret risk assessment tool for enterprise customers.
2026-04-19 2026Exposed Developer Secrets Surge: AI Drives 34% Increase in 2025 newsReport detailing a 34% surge in exposed developer secrets during 2025, fueled by AI-assisted coding and expanded use of tools like Claude Code. GitGuardian's analysis highlights significant increases in leaked AI service credentials, including DeepSeek API keys, and identifies internal repositories as a six-fold greater risk. The report also notes that 28% of exposures occur outside code in platforms like Slack and Jira, with 64% of discovered secrets remaining unrevoked.
2026-04-19 2026GitHub Found 39M Secret Leaks in 2024 — The GitHub Blog newsLibrary for GitHub Advanced Security, featuring Secret Protection and Code Security, addresses the pervasive issue of exposed secrets, which led to 39 million leaks on GitHub in 2024. It emphasizes built-in push protection for public repositories and introduces affordable standalone products and a free point-in-time scan for organizations to identify and manage secret exposures effectively, partnering with vendors like AWS and Google Cloud Platform to enhance detection accuracy. → github.blog
2026-04-18 2026Product showcase: Stop secrets from leaking through AI coding tools with GitGuardian beginnerLibrary extending ggshield with hook-based secret scanning for AI coding tools like Cursor and GitHub Copilot. This solution detects secrets in prompts and AI agent actions before they are sent to models or executed, providing real-time, preventive control for organizations to mitigate sensitive data exposure in AI workflows, addressing a critical blind spot in current security programs and complementing existing repository and CI pipeline scanning efforts. → helpnetsecurity.com
2026-04-17 2026Non-human identities: What they are and how to secure them (Netwrix) beginnerGuide to non-human identities (NHIs) and their security, detailing service accounts, API keys, managed identities, OAuth tokens, and cloud workload identities. The article highlights how these entities, lacking human oversight, MFA, and clear ownership, pose significant security risks, contributing to account compromises. It discusses authentication methods like token-based, key-based, certificate-based, and workload identity federation, emphasizing the absence of MFA as a critical vulnerability. Best practices, such as migrating to gMSAs for service accounts and addressing challenges with vendor-managed NHIs and token lifespans, are also covered, referencing the Netwrix 2025 Cybersecurity Trends Report.
2026-04-17 2026What Are Non-Human Identities? Complete NHI Security Guide 2025 beginnerGuide to Non-Human Identities (NHIs) covering their distinction from human accounts, their proliferation in modern organizations, and the five core characteristics that define them: built for automation, identity encoded in names, purpose-built design, operating in networks, and persistence without oversight. It details common NHI types including service accounts, API keys and tokens, machine identities and certificates, bots and automated agents, and application identities, emphasizing their critical role in security due to high privileges and continuous operation.
2026-04-17 2026TruffleHog: Deep Dive on Secret Management (Jit) intermediateLibrary for detecting hardcoded secrets in code. TruffleHog uses hundreds of patterns and strings to identify exposed credentials for services like AWS, GCP, and Azure, and integrates with tools like Slack and Stripe. It offers automation via pre-commit hooks and GitHub Actions, remote scanning capabilities, customizable rules, and secret verification by making API calls. The library also assists in remediating exposed secrets by providing guidance on rotating credentials and cleaning Git history using tools like BFG Repo-Cleaner.
2026-04-17 2026TruffleHog Open Source v3 vs GitGuardian beginnerLibrary comparing TruffleHog Open Source v3 and GitGuardian's code security platform for secrets detection. TruffleHog is a CLI tool for finding hardcoded secrets in repositories, while GitGuardian offers an integrated platform with automated detection, Honeytoken capabilities, alerting, incident prioritization, and remediation workflows across various version control systems. GitGuardian aims to reduce false positives through its detection engine and provides enhanced collaboration, enterprise-grade features, and dedicated support, contrasting with TruffleHog's open-source limitations in scalability and built-in functionality.
2026-04-17 2026git-secret-scanner: Find secrets with TruffleHog & Gitleaks beginnerTool for finding secrets in Git organizations and groups, combining TruffleHog's classification strengths with Gitleaks' broader detection capabilities. It supports GitHub and GitLab, utilizes specific tokens with required scopes, and offers features for ignoring secrets via annotations or fingerprint files, as well as baseline scanning to detect new secrets.
2026-04-17 2026Gitleaks vs TruffleHog 2026 Benchmarks (AppSec Santa) beginnerLibrary for open-source secret scanning, comparing Gitleaks and TruffleHog. Gitleaks excels as a fast, pre-commit hook using regex for rapid detection within git repositories. TruffleHog offers deeper scanning across git, S3 buckets, Docker images, and Slack, featuring credential verification to confirm active leaks, making it suitable for CI/CD pipelines. Most teams utilize both tools for comprehensive secret protection. → appsecsanta.com
2026-04-17 2026Rafter: detect-secrets vs gitleaks vs TruffleHog beginnerLibrary comparing `detect-secrets`, `git-secrets`, `gitleaks`, and `TruffleHog` for detecting leaked secrets. `git-secrets` is basic and AWS-focused. `detect-secrets` uses plugins and a baseline for brownfield repos, but has a higher false positive rate. `gitleaks` offers broad built-in coverage and fast scanning with 150+ rules. `TruffleHog` distinguishes itself by verifying found secrets via API calls, significantly reducing false positives by confirming active credentials.
2026-04-17 2026SEC02-BP03 Store and use secrets securely (AWS Well-Architected) beginnerReference detailing AWS best practices for managing application secrets, emphasizing credential removal, replacement with short-term alternatives (like IAM roles), and secure storage and rotation of remaining long-term secrets using AWS Secrets Manager. It highlights benefits such as encrypted storage, audited access, and on-demand secret distribution, while warning against common anti-patterns like embedding credentials in source code or configuration files. The document also mentions tools like Amazon CodeGuru for identifying hard-coded secrets and Lambda extensions for serverless secret retrieval.
2026-04-17 2026AWS Secrets Manager: Secure Credential Storage & Best Practices beginnerLibrary for securely storing and managing sensitive data like database passwords, API keys, and OAuth tokens within AWS. It offers automatic credential rotation, fine-grained access control via AWS IAM, integration with AWS CloudTrail for monitoring, and allows applications to retrieve secrets at runtime using AWS SDKs, reducing the risk of hard-coded credentials in code, CI/CD pipelines, or Kubernetes manifests.
2026-04-17 2026Practical steps to minimize key exposure using AWS Security (AWS) intermediateLibrary for minimizing AWS key exposure, this resource details practical steps for detecting exposed and unused access keys using Amazon Q Developer and AWS IAM Access Analyzer. It emphasizes implementing preventive guardrails with Service Control Policies (SCPs) and Resource Control Policies (RCPs) to establish data perimeters and restrict credential usage to expected networks. The guide also touches upon using AWS WAF and Amazon Inspector for network-level controls and automated secret rotation for ongoing security hygiene, addressing common threat actor entry points via compromised long-term credentials. → aws.amazon.com
2026-04-17 2026AWS API Keys / Secrets / Tokens Exposure Remediation intermediateGuide to remediating exposed AWS API keys, secrets, and tokens, emphasizing PCI-DSS compliance. The guide details using Cyera DSPM for AI-powered discovery across EC2, Lambda, and code repositories, followed by step-by-step remediation including disabling compromised keys, updating applications, and migrating secrets to AWS Secrets Manager or Systems Manager Parameter Store. It also covers long-term prevention through automated rotation, IAM roles, and least-privilege policies.
2026-04-17 2026Integrating HashiCorp Vault with Kubernetes for Secrets Mgmt intermediateLibrary for integrating HashiCorp Vault with Kubernetes for secure secrets management. This resource details deploying Vault using Helm in a Kubernetes cluster, enabling the Kubernetes authentication method, and configuring Vault to communicate with the Kubernetes API. It covers creating roles that map Kubernetes service accounts to Vault policies, enabling the Key/Value (kv) secrets engine, and storing secrets like database passwords. The integration leverages Vault's encryption at rest, dynamic secrets generation, and fine-grained access control to overcome limitations of native Kubernetes secrets.
2026-04-17 2026HashiCorp Vault Kubernetes: The Definitive Guide (Plural) beginnerGuide to integrating HashiCorp Vault with Kubernetes, focusing on replacing static secrets with dynamic, short-lived credentials for databases and PKI. It covers automating secret injection into pods using the Vault Agent Injector or Secrets Operator, and centralizing security policy and configuration. The guide highlights how Vault's dynamic secrets and centralized auditing significantly enhance security compared to native Kubernetes Secrets, with platforms like Plural aiding consistent deployment across fleets.
2026-04-17 2026A Hands-On Guide to Vault in Kubernetes beginnerA Hands-On Guide to Vault in Kubernetes
2026-04-17 2026Securing Kubernetes Secrets with HashiCorp Vault (InfraCloud) intermediateLibrary for securing Kubernetes secrets with HashiCorp Vault, this resource details how to configure Vault for high availability and implement automatic unsealing using Azure Key Vault. It covers creating Azure services like Key Vault and App Registration, then demonstrates deploying Vault with its Helm chart, specifying Azure Key Vault integration for unsealing and Raft for storage. The setup aims to overcome the limitations of Kubernetes native secrets by providing a centralized and robust secret management system.
2026-04-17 2026Manage Kubernetes native secrets with Vault Secrets Operator intermediateLibrary for managing Kubernetes native secrets with HashiCorp Vault. The Vault Secrets Operator (VSO) acts as a Kubernetes operator, syncing secrets between Vault and Kubernetes native secrets in specified namespaces. It supports kv-v1 and kv-v2, TLS certificates via PKI, and static and dynamic secrets. The tutorial demonstrates installation of Vault and VSO using Helm on minikube, configuring Kubernetes authentication, KV secrets engine, and a role for accessing a static secret.
2026-04-17 2026Secret detection (GitLab Docs) beginnerLibrary for detecting and preventing secrets in Git repositories. It offers "secret push protection" to block commits containing secrets, "pipeline secret detection" that scans branches within CI/CD, and "client-side secret detection" for issues and merge request comments. GitLab can automatically revoke exposed secrets and provides vulnerability reports for remediation. The "GitLab Duo" feature helps reduce false positives by analyzing findings.
2026-04-17 2026Find secrets with GitHub secret risk assessment beginnerTool for scanning GitHub organizations for secret leaks, providing insights into public exposures, private exposures, and token types. Available on GitHub Team and Enterprise plans starting April 1, 2025, this assessment helps identify affected repositories and the number of secrets leaked per type, offering a clear view of an organization's secret footprint without storing or sharing specific secrets. → github.blog
2026-04-17 2026About secret scanning (GitHub Docs) beginnerLibrary for automatically detecting credential leaks like API keys and passwords committed to repositories. It scans Git history, issue and pull request descriptions, wikis, and gists for exposed secrets. The library generates alerts upon detection, allowing for immediate credential rotation. It supports expanding detection with non-provider and custom patterns, and includes validity checks to prioritize remediation. GitHub also partners with service providers to notify them of detected partner secrets, and offers AI-powered scanning via Copilot.
2026-04-16 2026Do Not Use Secrets in Environment Variables beginnerReference detailing why secrets should not be stored in environment variables, explaining risks like poor management, difficulty in rotation and auditing, lack of encryption, and leaks through frontend/backend blurring in frameworks like Next.js and Nuxt, as well as `.env` files and Docker images. It highlights the ease of access via `/proc/PID/environ` and the exposure in process lists, proposing better secrets management solutions.

Frequently Asked Questions

How do secrets leak into code repositories?
Secrets commonly leak through developer mistakes: hardcoding API keys during development, committing .env files, leaving credentials in test fixtures, pasting tokens into comments, or including secrets in Docker build arguments. Even if removed in later commits, secrets persist in git history unless the repository is rewritten with tools like git-filter-repo or BFG Repo Cleaner.
What tools detect leaked secrets?
TruffleHog and GitLeaks scan git repositories for high-entropy strings and known credential patterns. GitHub Secret Scanning alerts on known token formats from partner services. Pre-commit hooks using detect-secrets or gitleaks can prevent commits containing secrets. For CI/CD, tools like talisman and SpectralOps provide pipeline-level scanning.
What should you do when a secret is leaked?
Immediately rotate the compromised credential — assume it has been captured. Revoke the old key, generate a new one, and update all systems using it. Then remove the secret from git history if it was committed. Review access logs for the compromised credential to assess if it was exploited. Finally, implement prevention measures to stop future leaks.

Weekly AppSec Digest

Get new resources delivered every Monday.