Hooks Automation
Warn
Audited by Gen Agent Trust Hub on Sep 25, 2026
Risk Level: MEDIUMREMOTE_CODE_EXECUTIONCOMMAND_EXECUTIONPERSISTENCEDYNAMIC_EXECUTIONINDIRECT_PROMPT_INJECTION
Full Analysis
- [REMOTE_CODE_EXECUTION]: The skill instructs the user to install the
claude-flow@alphapackage globally and relies onnpx claude-flowfor its core functionality. This pattern involves downloading and executing code from a remote registry at runtime. - [COMMAND_EXECUTION]: The hook configuration examples in
.claude/settings.jsonutilize shell command interpolation to pass agent-provided parameters (such as${tool.params.command}and${tool.params.file_path}) directly into shell strings. This pattern is susceptible to command injection if the parameters contain shell metacharacters that are not strictly sanitized by the underlying CLI tool. - [DYNAMIC_EXECUTION]: The framework supports a
scripthook type that dynamically loads and executes local JavaScript files (e.g.,.claude/hooks/custom-quality-check.js) using Node.jsmodule.exportsandrequirepatterns. - [PERSISTENCE]: The skill provides documentation and examples for installing Git hooks (pre-commit, post-commit, pre-push) that execute automation commands. This establishes persistent execution of the skill's logic during standard version control operations.
- [INDIRECT_PROMPT_INJECTION]: The skill provides an attack surface for indirect prompt injection by processing untrusted data which is then used to influence automated decisions and shell commands.
- Ingestion points: Task descriptions in
pre-task, file paths inpre-edit, and search queries inpre-searchandpost-search. - Boundary markers: None identified in the configuration templates to separate data from instructions.
- Capability inventory: The skill has broad capabilities including shell command execution, file system access, and coordination of other agent tools through MCP.
- Sanitization: While the skill documentation mentions safety checks (e.g.,
--check-safety), the actual implementation and effectiveness of these checks on untrusted inputs are not defined in the skill content.
Audit Metadata