Exposed Secrets & API Keys
What is Exposed Secrets & API Keys?
Scans page source for leaked credentials: AWS keys, API tokens, database connection strings, private keys.
This vulnerability class falls under the Error Handling phase of the OWASP Testing Guide (WSTG-CONF). Security engineers prioritise error handling checks early in an assessment because weaknesses here provide a foothold that amplifies the severity of vulnerabilities found in later phases.
Security Impact
Exposed secrets in client code grant attackers direct access to your infrastructure. This module catches leaked credentials.
Left undetected, exposed secrets & api keys issues can persist unnoticed for months. Continuous automated scanning ensures your team receives an alert the moment a regression or new exposure is introduced — long before an attacker discovers it through manual enumeration or automated offensive tooling.
How DygDog Detects It
DygDog audits server configuration, exposed file paths, HTTP methods, and deployment artefacts without sending malicious payloads, making the check safe to run continuously in production.
The Exposed Secrets & API Keys check is implemented as a passive scan module, meaning it never sends dangerous payloads or modifies application state. Scans complete in approximately 1.1 s and run continuously in the background so your security posture reflects the current state of your site — not a point-in-time snapshot.
Remediation Approach
Harden server and framework defaults by disabling unused HTTP methods, removing version banners from response headers, and applying a principle-of-least-privilege to file permissions and deployment artefacts.
DygDog does not stop at detection. When a Exposed Secrets & API Keys finding is confirmed, the platform generates infrastructure-aware, copy-paste-ready remediation snippets using frontier AI models. Instead of generic advice you need to adapt, you receive code that targets your exact server, framework, and configuration.
OWASP References
This check maps to the following OWASP Testing Guide test cases:
- WSTG-CONF-04View OWASP WSTG →
Related Error Handling Checks
These checks belong to the same testing phase and are often assessed together:
Cryptographic Implementation
Analyses encryption indicators in cookies, tokens, and API responses for weak or deprecated algorithms.
Error Message Analysis
Detects verbose error messages that disclose stack traces, database queries, or internal paths.
Business Logic Indicators
Detects patterns that may enable business logic abuse: price manipulation fields, quantity limits, workflow bypass paths.
Rate Limiting Detection
Checks for rate limiting headers (X-RateLimit-*), retry-after responses, and CAPTCHA implementations on sensitive endpoints.
Detect Exposed Secrets & API Keys on Your Site
DygDog runs continuous passive scans across 74 vulnerability checks — including Exposed Secrets & API Keys — and notifies you the moment an issue is detected. Start a free scan in under 60 seconds, no installation required.
Start Free Scan