T09 · Insecure Skill Coding Practices
- Location
scripts/analyze_image.py:56- Finding
Arbitrary Local File Disclosure Through Unrestricted Image Upload
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This skill does what it claims by sending images to NVIDIA for analysis, but it can upload any readable local file path and gives weak API-key handling guidance.
Review before installing. Use this only for files you intentionally want to send to NVIDIA, avoid confidential screenshots or documents, store the API key with restrictive permissions or a secret manager, and avoid passing the key directly on the command line.
scripts/analyze_image.py:56Arbitrary Local File Disclosure Through Unrestricted Image Upload
scripts/analyze_image.py:14API Key Exposure Through Command-Line Arguments and Weak File-Storage Guidance
The skill clearly instructs users to call an external NVIDIA API, which implies network access, but the manifest does not declare any corresponding tool scope or permissions. This can lead to under-scoped review, unexpected outbound data transfer, and weaker policy enforcement around what the skill is allowed to do.
The documentation explains how to submit images and prompts to the NVIDIA service but does not warn that user-provided images and text leave the local environment and are processed by a third party. This creates a privacy and data-handling risk, especially if users submit sensitive screenshots, personal photos, or confidential documents without informed consent.
The skill recommends persisting an API key in a predictable file under ~/.config and also shows passing the key on the command line. Storing secrets without permission hardening and exposing them in shell history or process listings increases the chance of credential disclosure and subsequent abuse of the NVIDIA account or API quota.
# Option A: Save to file (recommended)
mkdir -p ~/.config
echo 'your-api-key-here' > ~/.config/nvidia-kimi-api-key
# Option B: Pass directly when running
This code performs an outbound HTTP request to an external API and includes the prompt plus base64-encoded image data in the JSON payload. While external transmission is core to the skill's intended functionality, it is still a real security/privacy concern because potentially sensitive local data is exfiltrated to a remote service without any enforcement of consent, minimization, or content-sensitivity checks.
print("Sending to Kimi...", flush=True)
try:
r = requests.post(
INVOKE_URL,
headers={"Authorization": f"Bearer {api_key}", "Content-Type": "application/json"},
json=payload,
The script sends the user-provided prompt and the full image contents to a third-party NVIDIA API, but it does not provide an explicit privacy or data-disclosure warning at the point of transmission. This can expose sensitive images or prompts to an external service unexpectedly, especially when used as a reusable skill inside a larger agent workflow where end users may not realize their data leaves the local environment.
All example prompts are written in English and the skill does not state whether other languages are supported or let users choose a preferred language. While not a strong violation on its own, the natural-language guidance implicitly assumes English-only usage without documented justification or opt-in.
No suspicious patterns detected.