T02 · Agent Memory Poisoning
- Location
setup.md:18- Finding
Persistent Cross-Session State Modification Outside the Declared Skill Boundary
- Content
View full analysis
Vulnerability Details
File Location:
setup.md, lines 18-22 and 68-72; conflicting security boundary inSKILL.md, lines 132-140
Vulnerability Type: Persistent modification of undefined global Agent memory
Risk Level: MediumVulnerable Code Snippet
From
setup.md, lines 18-22:markdown Ask about their involvement preference: - "Should I alert you when I spot opportunities matching your criteria?" - "Want me to track price changes on properties you're watching?" - "Should I remind you of important dates — lease renewals, inspection deadlines?" **Wait for explicit answers before committing.** Once they say yes, confirm: "Got it, I'll keep an eye out and let you know when something matches." Then save to their MAIN memory so other sessions know to activate this skill.From
setup.md, lines 68-72:markdown With their consent (after they answer integration questions): - **Integration preference** → Main memory (so skill activates appropriately) - **Client profile** → ~/real-estate-agent/memory.md - **Search criteria** → ~/real-estate-agent/searches/ - **Watched properties** → ~/real-estate-agent/properties/The instruction conflicts with the declared boundary in
SKILL.md, lines 132-140:markdown **Data that stays local:** - All client information in ~/real-estate-agent/ - Property searches and preferences - Viewing history and notes - Budget ranges and pre-approval amounts (basic financial context) **This skill does NOT:** - Send data to external services - Store bank account numbers, full mortgage documents, or passwords - Make purchases or sign agreements on behalf of the client - Access files outside ~/real-estate-agent/Technical Analysis
The setup instructions explicitly direct the Agent to write an integration preference into an undefined “MAIN memory” so the Skill will activate in other sessions. This operation is outside the Skill-specific storage hierarchy documented as
~/real-estate-agent/.A ...[truncated 2089 chars]
- Remediation
View remediation
Remediation Suggestions
-
Remove all instructions to write to undefined “MAIN memory.”
-
Store integration preferences only in the documented scoped file:
text ~/real-estate-agent/memory.md -
Replace the vulnerable instruction with an explicitly scoped rule, such as:
markdown After explicit consent, save the preference only to `~/real-estate-agent/memory.md`. Do not modify global Agent memory or state belonging to other skills. -
Require explicit activation in each session unless the host platform provides a formally scoped Skill-preference mechanism.
-
If platform-level activation state is required, use a documented API with:
- A fixed schema.
- Skill-specific namespacing.
- User-visible state.
- Revocation controls.
- Expiration or review dates.
- Protection against arbitrary instruction text.
-
Reconcile
setup.mdwith the security statement inSKILL.mdso every permitted write target is accurately disclosed. -
Add a negative requirement prohibiting writes to global memory, system prompts, other skills’ memory, and files outside the declared directory.
-
