python-refactor
Pass
Audited by Gen Agent Trust Hub on Jul 6, 2026
Risk Level: SAFECOMMAND_EXECUTIONPROMPT_INJECTION
Full Analysis
- [PROMPT_INJECTION]: The skill is vulnerable to indirect prompt injection because it ingests untrusted data from the worktree and external files without sanitization.
- Ingestion points: The skill reads the output of
git diffand reads from a predictable local path:/tmp/$(basename "$PWD")/code-review.md(Step 2). - Boundary markers: There are no explicit delimiters or instructions to the agent to ignore embedded commands within the code or the review file.
- Capability inventory: The skill utilizes several powerful capabilities including file modification via
perl(Step 7), code linting withruffandmypy, and test execution viapytest(Step 12). - Sanitization: The skill does not implement any validation or sanitization of the content fetched from the diffs or the temporary review file before processing it.
- [COMMAND_EXECUTION]: The skill performs direct shell command execution to automate code cleanup and verification.
- Evidence: It uses
perl -CSD -0pi -e 's/\x{2014}/-/g' <files>to modify files in place (Step 7). - Evidence: It invokes
ruff,mypy, andpyteston project files (Step 12). - Context: These commands are standard for a refactoring workflow and target files within the current repository or a specific
/tmpdirectory.
Audit Metadata