T06 · System Persistence
- Location
SKILL.md:67- Finding
Optional Crontab Creates Persistent Unattended Execution
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
The skill does what it says, but it stores Feishu contact data in a prompt-loaded file and can optionally keep rewriting it on a schedule, which needs careful review.
Install only if you trust the Feishu tenant data source and are comfortable placing a name-to-open_id directory into USER.md. Review the generated table before restarting the gateway, avoid the cron option unless you need it, and prefer adding validation or escaping for contact names and open_ids before using this in a shared or high-privilege agent environment.
SKILL.md:67Optional Crontab Creates Persistent Unattended Execution
scripts/sync_feishu_contacts.py:62Unescaped Feishu Contact Data Can Poison Persistent Agent Context
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
print(f"Available accounts: {list(cfg.get('channels', {}).get('feishu', {}).get('accounts', {}).keys())}")
sys.exit(1)
# 2. Get tenant access token
req = urllib.request.Request(
"https://open.feishu.cn/open-apis/auth/v3/tenant_access_token/internal",
data=json.dumps({
The skill instructs the user to run a script that reads credentials from a config file, makes network calls to Feishu, and writes data into USER.md, yet it declares no explicit tool scope or permission boundaries. This is dangerous because it hides the operational and trust surface of the skill, making it easier for an agent or user to invoke file and network actions without clear review or least-privilege controls.
The skill directs users to embed a full open_id-to-name contact table into USER.md, but it does not clearly warn that this modifies a prompt-injected file and stores sensitive identity mapping data there. This creates privacy and integrity risk because USER.md may be broadly exposed to the agent context, may persist stale or unauthorized personnel data, and may be overwritten or expanded without the user's informed consent.
The required USER.md format and the AGENTS.md startup instruction are provided as Chinese text and presented as content the user should add, with no opt-in or alternative language option. This creates a language-policy issue because the skill implicitly mandates a specific language rather than allowing the user's preferred locale.
Data from a source is assigned to a variable that is later passed to a sink, creating a variable-mediated taint flow.
}).encode(),
headers={"Content-Type": "application/json"}
)
resp = json.loads(urllib.request.urlopen(req).read())
if resp.get("code", 0) != 0:
print(f"Error getting token: {resp.get('msg', 'unknown error')}")
sys.exit(1)
Data from a source is assigned to a variable that is later passed to a sink, creating a variable-mediated taint flow.
"Authorization": f"Bearer {token}",
"Content-Type": "application/json"
})
data = json.loads(urllib.request.urlopen(req).read()).get("data", {})
for u in data.get("items", []):
name = u.get("name", "")
open_id = u.get("open_id", "")