claude-hook-writer

Pass

Audited by Gen Agent Trust Hub on Sep 15, 2026

Risk Level: SAFECOMMAND_EXECUTIONINDIRECT_PROMPT_INJECTIONDYNAMIC_EXECUTION
Full Analysis
  • [INDIRECT_PROMPT_INJECTION]: The skill documents the creation of prompt-based hooks that analyze potentially untrusted file content, creating an attack surface for indirect prompt injection.
  • Ingestion points: Hook input received via stdin during tool execution events.
  • Boundary markers: The skill recommends using JSON schema validation to constrain hook outputs.
  • Capability inventory: Hooks can trigger shell commands, modify files, and block tool operations using specific exit codes.
  • Sanitization: The documentation provides extensive advice on validating JSON fields and sanitizing file paths using jq and bash patterns.
  • [COMMAND_EXECUTION]: The skill provides templates for executing shell commands and local CLI utilities within a hook environment.
  • Evidence: Templates in references/code-templates.md demonstrate the use of prettier, black, gofmt, and git.
  • Safety context: The skill explicitly instructs on the use of variable quoting and absolute paths to prevent common execution vulnerabilities.
  • [DYNAMIC_EXECUTION]: The skill provides a pattern for using the eval command to process multiple JSON fields simultaneously.
  • Evidence: The references/quick-reference.md file contains a snippet using eval with jq's @sh filter.
  • Safety context: The use of the @sh filter ensures that values are properly escaped for shell evaluation, mitigating injection risks.
Audit Metadata
Risk Level
SAFE
Analyzed
Sep 15, 2026, 12:00 AM