scan_secrets
Scan files and directories for leaked secrets, API keys, and credentials using gitleaks or trufflehog to identify hardcoded secrets before they become exploitable.
Instructions
Scan a filesystem path for leaked secrets.
Uses gitleaks (default) or trufflehog to scan a directory or file for hardcoded secrets, API keys, tokens, and credentials.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"path": "<path>",
"target_id": "<target_id>"
},
"name": "scan_secrets"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | Directory or file path to scan. | |
| backend | No | "gitleaks" (default) or "trufflehog". | gitleaks |
| target_id | Yes | Identifier for the target. | |
| scope_exclude | No | Scope denylist patterns (glob). | |
| scope_include | No | Scope allowlist patterns (glob). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||