Back to skill

Security audit

Cross Agent Mailbox

Security checks for vulnerabilities and agentic risk

Overview

The skill has a coherent purpose, but it sets up a persistent shared mailbox for agents without enough safety guidance around trust, permissions, or automatic processing.

Install only for mutually trusted local agents. Use a private mailbox directory with restrictive permissions, avoid putting secrets in messages, treat every mailbox file as untrusted data, require user approval before acting on message requests, sanitize filenames and subjects, and avoid cron or watchdog polling unless you intentionally want persistent background processing and know how to disable it.

Vulnerability Patterns
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • 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 (2)

T01 · Skill Instruction Hijacking

Warning
Location
SKILL_EN.md:174
Finding

Untrusted Mailbox Content Can Hijack the Receiving Agent's Instructions

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
SKILL_EN.md:82
Finding

Unchecked Path Components Permit Directory Traversal, Overwrite, and Symlink Attacks

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Rogue AgentSelf-Modification, Session Persistence
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (13)

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The README instructs users to create a shared mailbox under the home directory and exchange messages by creating, reading, and moving files, but it provides no guidance on filesystem permissions, trust boundaries, or tamper risks. In a cross-agent setting, any process with access to that directory may read, alter, inject, or delete messages, which can leak data or cause one agent to act on forged instructions.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
60% confidence
Finding

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.

Content

Scanner excerpt · README.md (reported line 14)May include surrounding context.

1. 创建信箱目录

bash
mkdir -p ~/.shared-mailbox/{agent-a-to-b,agent-b-to-a}/{archive}

2. 创建通信协议文件

Session Persistence

Medium
Category
Rogue Agent
Confidence
78% confidence
Finding

The Quick Start directs creation of a long-lived shared mailbox directory in the user's home folder, establishing persistent on-disk state for cross-agent communication. In security-sensitive environments, this persistent shared channel can outlive the session, retain sensitive data, and be reused by other agents or processes without sufficient visibility or access controls.

Content

Scanner excerpt · README_EN.md (reported line 11)May include surrounding context.

Quick Start

1. Create Mailbox Directory

bash
mkdir -p ~/.shared-mailbox/{agent-a-to-b,agent-b-to-a}/{archive}

Session Persistence

Medium
Category
Rogue Agent
Confidence
80% confidence
Finding

The cron example establishes a persistent scheduled task that repeatedly executes a script, which is a form of session persistence on the host. Even though presented as convenience, persistence mechanisms increase risk because they continue operating after the initial session and may process untrusted mailbox contents indefinitely or unexpectedly consume resources.

Content

Scanner excerpt · README_EN.md (reported line 111)May include surrounding context.

Option A: Scheduled Polling (Simple)

Create cron task to check mailbox every 5-10 minutes:

bash
# Check every 5 minutes

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill's natural-language description and instructions are entirely in Chinese, with no indication that the user can choose another language or that the locale restriction is required for a region-specific purpose. Under SQP-3, forcing a specific language without opt-in is a policy concern.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
85% confidence
Finding

The skill introduces session persistence by storing inter-agent messages and read-state under ~/.shared-mailbox, creating a durable local message store that may contain sensitive prompts, outputs, or agent-to-agent coordination data. In a multi-user or weakly permissioned environment, these files can be read, modified, replayed, or poisoned by other local processes, and the persisted history increases the blast radius of prompt injection or data leakage over time.

Content

Scanner excerpt · SKILL.md (reported line 33)May include surrounding context.

1. 创建信箱目录

bash
mkdir -p ~/.shared-mailbox/{agent-a-to-b,agent-b-to-a}/{archive}

2. 创建通信协议文件

Session Persistence

Medium
Category
Rogue Agent
Confidence
72% confidence
Finding

The skill's core design introduces cross-session message persistence through a shared mailbox directory, allowing one agent to leave content for later automatic consumption by another. Persistent inter-agent state is risky because untrusted files can survive across runs, be replayed, or be planted by other local processes with directory access, potentially influencing later agent behavior.

Content

Scanner excerpt · SKILL_EN.md (reported line 24)May include surrounding context.

How It Works

text
Agent A → Write to → shared-mailbox/a-to-b/ → Agent B reads
Agent B → Write to → shared-mailbox/b-to-a/ → Agent A reads

Session Persistence

Medium
Category
Rogue Agent
Confidence
83% confidence
Finding

The cron-based polling option establishes persistent scheduled execution, which can continue running unattended and repeatedly process mailbox contents. In an agent context, this increases risk of unintended autonomous behavior, repeated processing loops, and prolonged exposure to malicious or malformed messages dropped into the watched directory.

Content

Scanner excerpt · SKILL_EN.md (reported line 130)May include surrounding context.

Option A: Scheduled Polling (Simple)

Create cron task to check mailbox every 5-10 minutes:

bash
# Check every 5 minutes

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
75% confidence
Finding

The README tells users to create a cron task that repeatedly runs a script every 5 minutes, which is a persistent system-level automation change. Although the behavior is shown, there is no explicit warning that this will continue running in the background and repeatedly access the mailbox until removed.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
92% confidence
Finding

The README instructs users to create, write to, and move files within a shared directory under the user's home folder, but it does not warn about the privacy, integrity, and multi-process risks of using a shared mailbox. In an agent context, silent file creation and movement can expose sensitive prompts or outputs to other local processes and may lead users to enable the pattern without understanding the security tradeoffs.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
82% confidence
Finding

This SKILL.md instructs users to create directories, write mailbox files, and move files into an archive as part of the workflow. Although these actions are central to the skill, the markdown does not explicitly warn that it will create and modify files under ~/.shared-mailbox, which is the kind of user-data/system-state impact SQP-2 asks to disclose in markdown descriptions.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
98% confidence
Finding

The documentation states that mailbox files should follow the format YYYY-MM-DD_NNN_简短主题.md with an example like 2026-04-15_001_打招呼.md (L168-L172), but send_letter actually generates filenames as %Y-%m-%d_%H%M_{subject}.md, using time-of-day rather than a sequence number. This is an active contradiction between the documented protocol and the code example implementing message creation.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
85% confidence
Finding

This markdown skill instructs the user to create and use ~/.shared-mailbox and later provides code that writes and archives message files there. While file operations are central to the skill, the document does not include a clear warning that using the skill will create, modify, and move files under the user's home directory.

Content

No source excerpt is available for this finding.