T05 · Unauthorized Access and Privilege Escalation
- Location
start-simple.py:76- Finding
Unauthenticated network access to memory, persona, and administrative APIs
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This is a real memory/persona server, but it exposes persistent memory and persona controls without authentication by default.
Review before installing or running. Only run this bound to localhost or behind strong authentication, avoid storing secrets or sensitive personal data, add real deletion/redaction and retention controls, and pin dependencies/model revisions before using it with real agent memory.
start-simple.py:76Unauthenticated network access to memory, persona, and administrative APIs
app/services/memory_service.py:65Unauthenticated persistent poisoning of Agent long-term memory
app/services/event_detector.py:48Sensitive-data detection does not prevent plaintext storage and retrieval
app/models.py:117Unbounded API input permits memory, CPU, and disk denial of service
pyproject.toml:26Unpinned dependencies and mutable runtime model retrieval create supply-chain risk
Skill modifies its own code, configuration, or behavior at runtime. Self-modification enables an agent to escalate privileges, disable safety constraints, or install persistent backdoors.
Traditional AI assistants rely on static "character settings" — they play roles but lack true selves. DreamMoon-MemProcessor enables AI to:
- 🌱 **Grow Naturally** - Learn from experiences like a living organism
- 🔄 **Self-Evolve** - Continuously cognize and improve through reflection
- ⚖️ **Maintain Consistency** - Stay stable while keeping core values
This is not role-playing. This is **true digital personality**.
Skill modifies its own code, configuration, or behavior at runtime. Self-modification enables an agent to escalate privileges, disable safety constraints, or install persistent backdoors.
Unlike traditional static character settings, it enables AI to:
- 🌱 Grow naturally from experiences
- 🔄 Self-evolve through reflection
- ⚖️ Maintain stability while evolving
**中文**:
Skill manipulates agent memory, state, or stored context. Memory corruption can alter personality, override safety rules, or cause unpredictable behavior.
"""删除记忆"""
try:
# TODO: 实现删除逻辑
logger.info(f"Delete memory requested for key: {key}")
return {"success": True, "key": key, "note": "Delete logic not fully implemented"}
except Exception as e:
logger.exception(f"Error in delete_memory: {e}")
Skill manipulates agent memory, state, or stored context. Memory corruption can alter personality, override safety rules, or cause unpredictable behavior.
logger.exception(f"Error in delete_memory: {e}")
raise HTTPException(
status_code=status.HTTP_500_INTERNAL_SERVER_ERROR,
detail="Failed to delete memory"
)
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
ALLOWED_ORIGINS: List[str] = ["*"]
class Config:
env_file = ".env"
env_file_encoding = "utf-8"
case_sensitive = True
YARA rule matched a hack tool or exploit indicator (offensive tools, reconnaissance, privilege escalation, or exploit frameworks).
erences.get("traits", {})
# 3. 生成核心维度评分
dimensions = self._generate_dimension_scores(seed_traits, user_traits)
# 4. 构建价值观系统
value_system = self._generate_value_system(
request.user_preferences.get("values", []),
request.constraints
)
# 5. 生成自我描述
self_description = self._generate_self_description(dimensions, value_system)
# 6. 构建人格档案
persona = PersonaProfile(
name=request.user_preferences.get("name", "DreamMoon"),
title=request.user_preferences.get("title", "AI Assistant"),
dimensions=dimensions,
value_system=value_system,
self_description=self_description,
origin_story=self._generate_origin_story(request.base_seed),
consistency_rules=request.constraints
)
# 7. 存储到 L3 (人格是重要长期�
Package name closely resembles a popular package, suggesting possible typosquatting. Attackers publish malicious packages with similar names to trick developers into installing them.
Package name closely resembles a popular package, suggesting possible typosquatting. Attackers publish malicious packages with similar names to trick developers into installing them.
The README encourages storing and evolving persona data using memories, recent experiences, and user feedback, but it provides no warning about handling potentially sensitive personal data. In a memory/persona system, these examples normalize collection and retention of behavioral and preference data without mentioning consent, minimization, retention limits, or access controls, which increases privacy and compliance risk.
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
# Generate Persona | 生成人格
curl -X POST http://localhost:9090/api/v1/persona/generate \
-H "Content-Type: application/json" \
-d '{
"base_seed": "curious, friendly, good at problem solving | 好奇、友善、善于解决问题",
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
}'
# Evolve Persona | 演进人格
curl -X POST http://localhost:9090/api/v1/persona/evolve \
-d '{
"persona_id": "xxx",
"recent_experiences": ["memory_1", "memory_2"],
The skill advertises automatic persistence and semantic search across layered memory, but the description does not clearly warn users that their inputs or user-related data may be stored and later retrieved. In a memory/persona system, this omission can lead to unexpected retention of sensitive information and privacy harms, especially if users assume interactions are ephemeral.
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
python start-simple.py
curl -X POST http://localhost:9090/api/v1/persona/generate
-d '{"base_seed":"curious and friendly | 好奇友善","user_preferences":{"name":"AI Assistant | AI助手"}}'
The DELETE endpoint reports success without actually deleting anything, creating a semantic integrity issue where clients believe sensitive memory has been removed when it has not. In a memory-storage API, this can lead to unintended retention of data, compliance failures, and continued availability of records that users or operators expected to be erased.
The /analyze endpoint accepts arbitrary content and context, then explicitly determines whether the material is sensitive via detector.analyze(...). Although the code has internal logging for errors, there is no user-facing disclosure in the function docstring or nearby comments warning that submitted content may be processed for sensitivity analysis.
The module docstrings and inline documentation are entirely in Chinese, which indicates a fixed language assumption for the skill's natural-language interface and maintenance guidance. Under the stated policy, language-specific behavior should offer opt-in or clearly justify the locale restriction, neither of which appears in this file.
Untrusted data is passed to an insecure deserializer (pickle, marshal, dill, jsonpickle, joblib, yaml.load without a safe Loader, or torch.load without weights_only). These deserializers reconstruct arbitrary objects and invoke callables during loading, so deserializing attacker-controlled bytes is equivalent to arbitrary code execution.
import pickle
try:
item_dict = pickle.loads(item["data"])
return MemoryItem(**item_dict)
except Exception:
return None
This code embeds Chinese-only natural-language descriptions such as "L3 冷存储" and related comments/docstrings throughout the file, indicating a fixed locale expectation. Under the language/locale policy, forcing a specific language without opt-in or documented justification is a policy concern.
The module docstring at L001 and class docstring at L017 present this component as archive storage centered on a FAISS vector index and file compression. However, the implementation later performs destructive lifecycle actions by packaging L3 files into tar archives and then deleting the originals, which is a materially different operational effect than the storage-oriented documentation suggests.
The code removes source memory files after creating the tar.gz archive, which is a destructive operation. Although there is a later print statement announcing archive creation, there is no prior confirmation, warning comment, or user-facing disclosure around the deletion behavior in this file.
This code file contains natural-language descriptions entirely in Chinese, including the primary module documentation and inline model descriptions, with no indication that language is configurable or limited to a China-specific use case. Under the policy rule, forcing a specific language without user opt-in is a locale/language policy concern.
The module-level and class docstrings are written only in Chinese, and all user-facing scheduler labels and status messages in this file also use Chinese. This imposes a specific language/locale in natural-language outputs without any visible opt-in or documented locale constraint.
The file’s user-facing natural-language strings and documentation are entirely in Chinese, including the module and class descriptions, with no indication that users can opt into another language or locale. Under the stated policy, forcing a specific language without user choice is a locale-policy concern.
The service persists user-provided memory content across multiple storage tiers (L1-L4), including long-lived summary and vector storage, without any visible consent, disclosure, or data minimization control in this code path. If sensitive user content is stored or replicated unexpectedly, it increases privacy risk, retention scope, and blast radius in the event of compromise or misuse.
Search queries are embedded via the embedding service, which may transmit or process potentially sensitive user queries outside the immediate search logic without disclosure or user choice. Queries often contain personal or confidential information, so silent embedding can create privacy exposure, logging risk, or third-party data handling concerns.