T05 · Unauthorized Access and Privilege Escalation
- Location
scripts/feishu_send_media.py:91- Finding
Unmatched agents can silently inherit an unrelated Feishu account
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This Feishu media sender mostly does what it says, but its credential selection and file validation are loose enough that users should review it before installing.
Install only if you trust the workspace and Feishu configuration it will run under. Before use, verify the recipient, selected file, and account binding; avoid sensitive paths; and prefer a version that fails closed on unmatched agents, uses path-aware workspace checks, rejects non-media files, enforces size limits, and asks for confirmation before upload.
scripts/feishu_send_media.py:91Unmatched agents can silently inherit an unrelated Feishu account
scripts/feishu_send_media.py:45String-prefix workspace matching permits incorrect agent identity resolution
scripts/feishu_send_media.py:125Insufficient file validation creates a local-file disclosure primitive
The skill clearly describes behavior that reads local files, accesses credentials from the local configuration, and sends data over the network to Feishu, but it does not declare any explicit tool scope or permissions boundary. In an agent ecosystem, this weakens user visibility and enforcement around sensitive capabilities, increasing the chance that local files or tokens are accessed and exfiltrated without informed consent.
The quick-start and description explain how to send media but do not prominently warn that a local file is uploaded to a third-party service and then delivered into a Feishu chat. This creates a meaningful risk of accidental disclosure of sensitive images/videos, especially because users may treat a local path argument as a purely local operation rather than external transmission.
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
def get_tenant_access_token(app_id: str, app_secret: str) -> str:
resp = requests.post(
FEISHU_TOKEN_URL,
json={"app_id": app_id, "app_secret": app_secret},
timeout=15,
This code uploads a user-specified local file to Feishu and then sends it as a message via external HTTP APIs. Although the network behavior is visible in code, there is no confirmation prompt, explicit disclosure in the CLI output, or warning in the module docstring that local file contents and recipient identifiers will be transmitted to a remote service.
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
"msg_type": msg_type,
"content": content,
}
resp = requests.post(
FEISHU_SEND_MSG_URL,
headers=headers,
params=params,