T02 · Agent Memory Poisoning
- Location
scripts/memory.py:30- Finding
Persistent Untrusted Content Can Poison Future Agent Context
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This is a disclosed persistent memory skill, but it gives agents durable identity and memory mutation power without enough trust-boundary and retention safeguards.
Install only if you want durable agent memory on this machine. Avoid storing secrets, credentials, regulated personal data, or untrusted instruction-like text; review and prune ~/.amarin/agent.db regularly; and prefer a pinned, reviewed amarin-memory dependency before using it in sensitive workflows.
scripts/memory.py:30Persistent Untrusted Content Can Poison Future Agent Context
SKILL.md:11Unpinned Third-Party Package Controls Core Memory Operations
The skill invokes Python scripts and depends on environment configuration (for example OLLAMA_URL) but does not declare any explicit tool scope, permissions, or allowed-tools boundaries. That makes the skill's operational capabilities less transparent to the agent runtime and reviewer, increasing the chance of unintended environment access or execution in broader contexts than expected.
The skill is explicitly designed to persist user preferences, identity information, and cross-session memories, but it does not provide a clear privacy notice, retention policy, consent guidance, or deletion expectations. This can lead to unintended long-term storage of sensitive personal data and creates privacy and compliance risks, especially because the database is persistent across sessions.
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.
def get_engine():
"""Get or create the MemoryEngine."""
try:
from amarin_memory import MemoryEngine
except ImportError:
The manifest describes persistent adaptive memory with storage, decay, deduplication, semantic search, identity blocks, and isolation, but it does not mention operator-facing mutation features for revising existing memories or soft-deleting them. This file adds commands to alter or deactivate stored memories, which expands behavior beyond the described memory-preservation and retrieval focus.
No suspicious patterns detected.