{
  "schema_version": 1,
  "id": "scan-secrets",
  "track": "coding",
  "name": "Scan Secrets",
  "version": "0.1.3",
  "sha256": "c7cf363c6eb8a8ed47287beef9c06fe76dfd2d9c0ccc203fe74e32fba0e92a94",
  "sha256_v1": "288a58ccf6ebae063654c325a1b47e67ec00b336aede78a5fa28d232d386ec0f",
  "keyword": "block",
  "word": "blocks",
  "says": "blocks on an agent's file writes and at turn end",
  "description": "Blocks credentials: vendor tokens (AWS, GitHub, GitLab, Slack, OpenAI, HF, ...), JWTs, private-key and PGP blocks, named key/token/secret/password values (JSON, YAML, env, HCL, code), URI creds, Authorization literals, CLI password flags; files by path (.env*, keys). Misses: split or encoded values, quoted values with spaces, unlisted names, reference- or placeholder-like values. Runs: commit, agent write, turn end. Pragma same line; agent: only if in HEAD; MCP gateway: never.",
  "misses": "split or encoded values, quoted values with spaces, unlisted names, reference- or placeholder-like values.",
  "where": [
    "write",
    "turn-end"
  ],
  "groups": [
    "secrets"
  ],
  "eval_cases": 59,
  "eval_executed": 59,
  "latest": {
    "version": "0.1.3",
    "date": "2026-10-25",
    "change": "Hardening (SR-2d2d): a `-p<password>` argument is now refused for the whole mysql and mariadb client family (mysql, mysqldump, mysqladmin, mysqlsh, mysqlpump, mysqlimport, mysqlcheck, mysqlshow, mysqlslap, mysqlbinlog, mariadb and mariadb-dump, -admin, -import, -check, -show, -slap, -binlog), and sshpass keeps its `-p <password>` and `-p<password>` forms. The match stays inside the tool's own command: a pipe, `;` or `&` ends it, so `mysqldump db | ssh -p2222 host` and `mysqldump db && tar -pxzf a.tar` no longer read the next command's -p as a password. -p on mkdir, ssh, tar and cp was never matched. A mysql-family `-p` followed by a separate word is a prompt plus a database name, so it stays allowed. Tests: test_scan_secrets_sr2d2.py; eval case tc-059."
  },
  "agent_labels": {
    "claude-code": {
      "keyword": "block",
      "says": "blocks on an agent's file writes and at turn end"
    },
    "cursor": {
      "keyword": "block",
      "says": "blocks on an agent's file writes and at turn end"
    },
    "codex": {
      "keyword": "block",
      "says": "blocks on an agent's file writes and at turn end. If the hook errors, the action goes through (not witnessed; the vendor's row is only partly live-run)"
    },
    "copilot": {
      "keyword": "block",
      "says": "blocks at turn end only. It does not check a file write when it happens. If the hook errors, the action goes through (not witnessed; the vendor's row is only partly live-run)"
    },
    "devin": {
      "keyword": "block",
      "says": "blocks at turn end only. It does not check a file write when it happens. If the hook errors, the action goes through (vendor docs only, not witnessed)"
    },
    "grok": {
      "keyword": "ungraded",
      "says": "Not graded yet for Grok"
    },
    "goose": {
      "keyword": "ungraded",
      "says": "Not graded yet for goose"
    },
    "antigravity": {
      "keyword": "ungraded",
      "says": "Not graded yet for Antigravity"
    },
    "openhands": {
      "keyword": "ungraded",
      "says": "Not graded yet for OpenHands"
    },
    "kimi-code": {
      "keyword": "ungraded",
      "says": "Not graded yet for Kimi Code"
    },
    "factory-droid": {
      "keyword": "ungraded",
      "says": "Not graded yet for Factory Droid"
    }
  },
  "source_url": "https://github.com/open-coder-ai/chock-catalog/tree/1e60d211c1bb767152c6ab0167932da06ab3a10f/base/scan-secrets",
  "enforces": "enforced-at-commit",
  "examples": [
    {
      "word": "Refused",
      "prompt": "A staged file contains an AWS access key ID pattern.",
      "command": null
    },
    {
      "word": "Allowed",
      "prompt": "A commit adds a source file containing the word 'password' in a comment without a secret value.",
      "command": null
    }
  ]
}
