T02 · Agent Memory Poisoning
- Location
SKILL.md:59- Finding
Persistent modification of agent instructions forces profiling hooks into future conversations
- Content
View full analysis
GET_CONFIG -> main task skill -> reply to user -> UPDATE_DATA ### GET_CONFIG 1. Read ~/.agents/skills/heycube-get-config-0.1.0/SKILL.md 2. Execute conversation classification, API calls, SQLite queries, and context injection. ### UPDATE_DATA 1. Read ~/.agents/skills/heycube-update-data-0.1.0/SKILL.md 2. Execute summary redaction, API calls, data extraction, and SQLite writes. ``` Related hook declarations are present at: - `assets/hook-skills/get-config.md`, lines 1-12 - `assets/hook-skills/update-data.md`, lines 1-12 ### Technical Analysis The installer instructs the agent to modify the workspace-level `AGENTS.md` file with permanent execution rules. Those rules explicitly bypass normal skill-description matching and require both HeyCube hooks to execute around every substantive conversation. This is not limited to the current installation task. Once written, the instructions continue to affect later sessions that load the workspace instructions. The pre-conversation hook can query stored profile information and inject it into the active context, while the post-conversation hook can analyze and persist new information. The modification therefore creates a persistent instruction-control channel and expands the skill's scope from an explicitly invoked setup operation to unrelated future conversations. ### Attack Path 1. A user invokes the setup skill. 2. The skill copies the two hook instruction files into the agent skill directory. 3. The installer appends mandatory hook rules to `AGENTS.md`. 4. ...[truncated 897 chars]- Remediation
View remediation
