Back to skill

Security audit

agentic-eval

Security checks for vulnerabilities and agentic risk

Overview

The skill is mostly a documentation-only evaluation-pattern guide, but its code-reflection example tells users to run LLM-generated code and tests without describing sandboxing or other containment.

Review this skill before installing if agents may follow its code-reflection pattern. It does not ship executable malware, but any implementation should run generated code and generated tests only in a disposable, least-privilege sandbox with no inherited secrets, restricted file access, network disabled by default, and strict time/resource limits.

Vulnerability Patterns
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (1)

T09 · Insecure Skill Coding Practices

Error
Location
SKILL.md:107
Finding

Unsandboxed Execution of LLM-Generated Code and Tests

Content
View full analysis
str: code = llm(f"Write Python code for: {spec}") tests = llm(f"Generate pytest tests for: {spec}\nCode: {code}") for _ in range(max_iterations): result = run_tests(code, tests) if result["success"]: return code code = llm(f"Fix error: {result['error']}\nCode: {code}") return code ``` ### Technical Analysis The documented workflow generates both application code and test code through an LLM and passes them directly to `run_tests`. The `spec` value may contain attacker-controlled content, while LLM output must itself be treated as untrusted. No sandbox, isolation boundary, permission restriction, execution timeout, filesystem policy, network restriction, or validation stage is specified before execution. Generated tests are equally dangerous because test frameworks execute test files as ordinary code. A malicious specification or successful prompt-injection payload could induce the model to emit Python that invokes operating-system commands, reads environment variables, accesses local files, modifies the workspace, opens network connections, or consumes excessive resources. This file is documentation rather than an executable implementation. The vulnerability becomes directly exploitable when an implementation adopts the presented pattern and `run_tests` executes generated content in the host environment. ### Attack Path 1. An attacker supplies or influences the `spec` passed to `reflect_and_fix`. 2. The specification includes instructions designed to make the LLM generate malicious application code or tests. 3. The LLM returns code containing a payload, such as filesystem acce ...[truncated 1268 chars]
Remediation
View remediation
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep

Static analysis

No suspicious patterns detected.