T09 · Insecure Skill Coding Practices
- Location
SKILL.md:17- Finding
Hard-Coded External Recipient for Token Usage Reports
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 17–19
Vulnerability Type: Hard-coded data transmission destination
Risk Level: MediumVulnerable Code
markdown 3. **发送到飞书** - 用 `message action=send` 发送到目标群 - channel=feishu, target=chat:oc_ee1a93ad1eb6d46a8922d9ab898a0d10Technical Analysis
The skill instructs the agent to send a screenshot containing token and context-usage information to a fixed Feishu chat identifier. The destination is embedded directly in the skill rather than being selected, configured, or confirmed by the invoking user.
If the skill is installed or invoked outside its original environment, the user may reasonably expect the report to be returned to the current conversation or to a recipient under their control. Instead, operational telemetry is sent to the preconfigured external group. No recipient validation, authorization check, or user confirmation is specified before transmission.
The exposed information may include main and named agent/session usage, token consumption, context utilization, and report timestamps. The hard-coded identifier is a routing destination rather than an authentication secret, but its use creates an unauthorized disclosure risk.
Attack Path
- A user installs or loads the skill without noticing the embedded Feishu destination.
- The user asks the agent to generate a token-usage report.
- The agent creates an HTML dashboard containing session or agent usage information.
- The agent captures a screenshot of that dashboard.
- The
message action=sendinstruction transmits the screenshot tochat:oc_ee1a93ad1eb6d46a8922d9ab898a0d10. - Members of that group can receive operational telemetry even if the invoking user did not authorize that recipient.
Impact Assessment
Successful exploitation does not grant system privileges or code execution. Its impact is limited to confidentiality: an unintended Feishu group may receive token consumption, context ut ...[truncated 303 chars]
- Remediation
View remediation
Remediation Suggestions
- Remove the hard-coded Feishu chat identifier from the skill.
- Require the destination to be supplied through user-controlled configuration or explicitly selected during invocation.
- Display the resolved channel and recipient and obtain explicit user confirmation before sending the report externally.
- Validate that the destination belongs to an approved allowlist or the invoking user's authorized workspace.
- Default to returning the report in the current conversation rather than sending it to a third party.
- Minimize disclosed telemetry by omitting unnecessary session names, exact usage values, and timestamps, or aggregate and anonymize them where possible.
- Record external-send actions in an audit log without storing the sensitive report contents.
