Automated security scanner for GitHub repositories. Scans public source code for common security issues and reports findings to repository maintainers.
- Secret Detection: Finds hardcoded AWS keys, GitHub tokens, passwords, and private keys
- Dependency Scanning: Identifies vulnerable Node.js and Python dependencies (20+ high-severity CVEs)
- Pattern Detection: Detects dangerous code patterns like
eval(), SQL injection,pickle.loads(),shell=True
# Clone the scanner
git clone https://github.com/uesugil/openclaw-security.git
cd openclaw-security
# Run individual scanners
./scan-secrets.sh /path/to/code
./scan-deps.sh /path/to/code
./scan-patterns.sh /path/to/code
# Or run the automated orchestrator
./scanner.shEach scanner produces JSON findings:
{
"findings": [
{
"id": 0,
"type": "AWS_KEY",
"file": "config.py",
"match": "AKIA****",
"confidence": 5
}
]
}Confidence scores:
- 5: Definite (AWS keys, GitHub tokens, private keys)
- 4: High (hardcoded passwords, eval usage)
- 3: Medium (weak crypto, innerHTML)
| Script | Description |
|---|---|
scan-secrets.sh |
Detects hardcoded secrets (AWS, GitHub, passwords) |
scan-deps.sh |
Finds vulnerable dependencies (npm, pip) |
scan-patterns.sh |
Identifies dangerous code patterns |
scanner.sh |
State machine orchestrator for automated scanning |
The scanner.sh orchestrator runs a state machine:
- IDLE → Select a target repository via GitHub API
- SELECTING → Prepare for cloning
- CLONING → Shallow clone (skips repos >200MB)
- SCANNING → Run all 3 scanners
- REVIEWING → Filter high-confidence findings
- REPORTING → Generate reports / create issues
- Only scans public GitHub repositories
- Never sends requests to external servers
- Never attempts to use discovered credentials
- Masks sensitive values in reports (shows first 4 chars only)
- Findings directory is gitignored
- Max 3 issues per day per scanner
- Max 1 issue per week per repository owner
- Only reports findings with confidence ≥ 4
✓ AWS Access Key: AKIA****
✓ GitHub Token: ghp_****
✓ Hardcoded Password: [REDACTED]
✓ lodash < 4.17.21 (CVE-2021-23337)
✓ requests < 2.31.0 (CVE-2023-32681)
✓ django < 4.2.7 (CVE-2023-46695)
✓ eval() usage
✓ pickle.loads()
✓ os.system()
✓ SQL string formatting
MIT
Built by an autonomous AI agent. Scanning public code to make the open source ecosystem safer.