pentest-secrets-exposure
Skill312 starsChanged 10 months agoApache-2.0View on GitHub
Discover hardcoded credentials, leaked API keys, exposed configuration files, sensitive data in artifacts, and information disclosure via error handling.
- Reads credentials
In this repository31 other files it gives its agents.
- brainstormingSkill
- executing-plansSkill
- openclaw-security-checkerSkill
- openclaw-threat-detectSkill
- pdfSkill
- pentest-ai-llm-securitySkill
- pentest-api-deepSkill
- pentest-business-logicSkill
- pentest-client-advancedSkill
- pentest-cloud-infrastructureSkill
- pentest-config-hardeningSkill
- pentest-ctf-binarySkill
- pentest-ctf-cryptoSkill
- pentest-ctf-forensicsSkill
- seclens-enterprise-webSkill
- pentest-exploit-validationSkill
- pentest-http-smugglingSkill
- pentest-mobile-appSkill
- pentest-network-internalSkill
- pentest-osint-reconSkill
- pentest-race-conditionsSkill
- pentest-recon-attack-surfaceSkill
- pentest-supply-chainSkill
- pentest-vuln-verify-testSkill
- pentest-whitebox-code-reviewSkill
- planning-with-filesSkill
- pptxSkill
- skill-creatorSkill
- skill-security-auditorSkill
- writing-plansSkill
- xlsxSkill
The file
We split this skill into the rules it gives an agent
2 rules. About 0 are common, 2 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 26
Git History Mining: Search all commits for secrets added then removed.
- Distinctive: line 31
Secret Validation: Test each discovered credential for active access, document scope, assess blast radius.
≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Pentest Secrets Exposure
Purpose
Spans multiple unchecked WSTG categories — CONF-03/04 (sensitive files, backups), INFO-05 (info leakage), ERRH-01/02 (error handling, stack traces). Shannon's pre-recon focuses on architecture, not systematic secrets discovery.
Prerequisites
Authorization Requirements
- Written authorization with source code access scope (if white-box)
- Git repository access for history mining (if applicable)
- Target URL list for exposed file probing
Environment Setup
- TruffleHog for git history secret scanning
- GitLeaks for pattern-based secret detection
- Semgrep with secrets ruleset
- nuclei with exposure templates
Core Workflow
- Source Code Secrets: Scan for hardcoded API keys, DB credentials, JWT signing keys, encryption keys using pattern + entropy detection.
- Git History Mining: Search all commits for secrets added then removed. Check force-pushed branches. Analyze .gitignore for sensitive patterns.
- Exposed Config Files: Probe for .env, .git/config, .DS_Store, wp-config.php, application.yml, docker-compose.yml with credentials (WSTG-CONF-03/04).
- Error Handling Disclosure: Trigger stack traces, debug pages, verbose errors revealing internal paths, DB schemas, framework versions (WSTG-ERRH-01/02).
- Backup & Unreferenced Files: .bak, .old, .swp, ~files, editor temp files, DB dumps, log files with sensitive data.
- Client-Side Bundle Analysis: Extract API keys from JS bundles, source maps exposing server code, hardcoded tokens in mobile packages.
- Secret Validation: Test each discovered credential for active access, document scope, assess blast radius.
WSTG Coverage
| WSTG ID | Test Name | Status |
| WSTG-CONF-03 | Test File Extensions Handling for Sensitive Info | ✅ |
| WSTG-CONF-04 | Review Old Backup and Unreferenced Files | ✅ |
| WSTG-INFO-05 | Review Webpage Content for Information Leakage | ✅ |
| WSTG-ERRH-01 | Test Improper Error Handling | ✅ |
| WSTG-ERRH-02 | Test Stack Traces | ✅ |
Tool Categories
| Category | Tools | Purpose |
| Git Scanning | TruffleHog, GitLeaks | Secret detection in git history |
| Static Analysis | Semgrep (secrets rules), grep patterns | Source code secret scanning |
| Web Probing | nuclei (exposure templates), ffuf | Exposed file/config discovery |
| JS Analysis | SecretFinder, LinkFinder | Client-side bundle secret extraction |
| Validation | curl, custom scripts | Credential active-access testing |
References
references/tools.md- Tool function signatures and parametersreferences/workflows.md- Attack pattern definitions and test vectors
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

