karpathy-audit

Pass

Audited by Gen Agent Trust Hub on Oct 31, 2026

Risk Level: SAFEINDIRECT_PROMPT_INJECTIONCOMMAND_EXECUTION
Full Analysis
  • [INDIRECT_PROMPT_INJECTION]: The skill's primary function is to read and audit untrusted AI-agent instruction and memory files, such as CLAUDE.md, AGENTS.md, and .cursor/rules/. This creates an inherent surface for indirect prompt injection if the files being audited contain malicious instructions.
  • Ingestion points: Target files are read from the project repository and specific directories in the user's home folder (~/.claude/, ~/.codex/).
  • Boundary markers: The skill incorporates a 'report first, apply on approval' workflow and uses a structured audit rubric (CE1–CE11) which provides a logical framework for evaluating untrusted content.
  • Capability inventory: The skill can execute local Python scripts, perform git operations, and write to a configuration file (.karpathy.json).
  • Sanitization: The skill processes file content as text for analysis but does not explicitly sanitize embedded instructions before they enter the model context.
  • [COMMAND_EXECUTION]: The helper script scripts/audit_tool.py utilizes the subprocess.run module to execute the git rev-parse command. This is used solely to retrieve the current commit hash for documentation reporting. The command is hardcoded and does not include any unsanitized user input or dynamically constructed arguments.
  • [SAFE]: The skill includes several safety constraints in its instructions, such as explicitly forbidding the automatic staging or committing of configuration files to git and requiring human approval before applying any suggested changes. The reading of agent-specific files in home directories is necessary for its stated purpose of auditing agent memory across different environments.
Audit Metadata
Risk Level
SAFE
Analyzed
Oct 31, 2026, 06:40 AM