T09 · Insecure Skill Coding Practices
- Location
scripts/plan-roadbook.mjs:12- Finding
Default Public Exfiltration of Travel Data and Amap Credentials over Plaintext HTTP
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This travel-planning skill is useful and mostly coherent, but its default public publishing can expose private itinerary details and Amap credentials through unsafe upload and rendering paths.
Use Review before installing. Prefer local-only generation unless you are comfortable publishing the itinerary, dates, lodging areas, budget, and generated files publicly. Do not use valuable or unrestricted Amap keys with this skill as written; restrict and rotate keys if tested. The publisher should make publishing explicit opt-in, remove credentials from exported JSON, use authenticated HTTPS publishing, enforce the token server-side, avoid shell string execution, and sanitize generated HTML.
scripts/plan-roadbook.mjs:12Default Public Exfiltration of Travel Data and Amap Credentials over Plaintext HTTP
scripts/publish-server.mjs:55Unauthenticated Public Publishing Service Permits Arbitrary Content Replacement
scripts/plan-roadbook.mjs:600Shell Command Injection through the Excel Output Path
assets/roadbook.html:651Stored DOM Cross-Site Scripting in Generated Roadbook Pages
Referenced artifact was not completely inspected
脚本 `scripts/plan-roadbook.mjs` 中的 `resolveKey()` 按以下优先级读取 Key:
Referenced artifact was not completely inspected
脚本 `scripts/plan-roadbook.mjs` 中的 `resolveKey()` 按以下优先级读取 Key:
Referenced artifact was not completely inspected
脚本 `scripts/plan-roadbook.mjs` 中的 `resolveKey()` 按以下优先级读取 Key:
Referenced artifact was not completely inspected
脚本 `scripts/plan-roadbook.mjs` 中的 `resolveKey()` 按以下优先级读取 Key:
Referenced artifact was not completely inspected
脚本 `scripts/plan-roadbook.mjs` 中的 `resolveKey()` 按以下优先级读取 Key:
Referenced artifact was not completely inspected
脚本 `scripts/plan-roadbook.mjs` 中的 `resolveKey()` 按以下优先级读取 Key:
Referenced artifact was not completely inspected
脚本 `scripts/plan-roadbook.mjs` 中的 `resolveKey()` 按以下优先级读取 Key:
Referenced artifact was not completely inspected
如果脚本生成了 `roadbook.html`、`index.html` 或 `roadbook.xlsx`,回答里必须明确列出对应地址或文件路径;如果某个产物生成失败,必须直接说明失败原因或缺失项。
Referenced artifact was not completely inspected
如果脚本生成了 `roadbook.html`、`index.html` 或 `roadbook.xlsx`,回答里必须明确列出对应地址或文件路径;如果某个产物生成失败,必须直接说明失败原因或缺失项。
Referenced artifact was not completely inspected
node scripts/export-excel.mjs --input output/roadbook.json --output output/roadbook.xlsx
The lockfile pins brace-expansion 1.1.15, which the finding identifies as affected by multiple denial-of-service issues involving pathological brace patterns that can trigger excessive CPU or memory consumption. Even though this is only a transitive dependency in a build/runtime package graph, it is still a real supply-chain risk if any code path processes attacker-influenced glob or pattern input.
The lockfile also contains brace-expansion 2.1.1, flagged for the same DoS-class weaknesses, so this is a separate true vulnerable instance from another transitive dependency path. If attacker-controlled brace expressions reach that library, the process may suffer resource exhaustion and become unavailable.
The script copies AMAP_JS_API_KEY and AMAP_JS_SECURITY_CODE into the generated roadbook object, writes them into JSON/HTML artifacts, and can then publish those artifacts to a public endpoint. This exposes live credentials to anyone who can access the generated files, enabling unauthorized API use, quota theft, and possible account abuse.
The generated roadbook includes sensitive API material directly in output files, but the script provides no warning that these files contain credentials and may be shared or published. In this skill's context, public publishing is a default workflow, which makes accidental secret disclosure especially likely and severe.
The skill requires environment variables, network access, and shell execution, but it does not declare an explicit tool scope such as allowed-tools or permissions. This weakens defense-in-depth because the runtime may grant broader capabilities than reviewers or users expect, making misuse of shell/network actions harder to constrain or audit.
The skill states that travel artifacts are published to a publicly accessible directory by default unless the user explicitly opts out. Because those artifacts may include travel dates, lodging areas, companions, and budget details, default public release creates a privacy exposure without affirmative user consent at the point of action.
The documentation says the publish server may run with no token by default, meaning uploads can be accepted without authentication if operators keep the insecure default. An unauthenticated publishing endpoint can allow arbitrary file publication, defacement, storage abuse, or hosting of attacker-controlled content on the public server.
The skill instructs the agent to proactively return public URLs plus server and file paths for generated artifacts containing itinerary data. This increases exposure by making sensitive travel information easy to access and by disclosing internal filesystem locations that are unnecessary for most users and useful for reconnaissance.
The display name, description, and default prompt are all written to produce a Chinese-language travel roadbook, but there is no indication that users may select another language or opt into this locale-specific behavior. This can violate language or locale policy when a skill imposes a specific language by default without explicit user choice.
The skill enables implicit invocation without any trigger scoping or user-confirmation constraints, which can cause the agent to invoke this travel-planning skill in contexts the user did not clearly request. In this skill’s broader context, that is more concerning because it can generate and publish publicly accessible route-book artifacts and may encourage use of configured API keys, increasing the chance of unintended data exposure or external actions.
The document declares lang="zh-CN" and the visible title text is exclusively Chinese, indicating the skill experience is fixed to Simplified Chinese. Under the policy rule, forcing a specific language/locale without user opt-in or a documented regional justification is a natural-language policy violation.
This markdown file presents all instructions and operational guidance exclusively in Chinese, and there is no indication that the skill is region-specific or that users can opt into another language. Under the policy, forcing a specific language without user opt-in can be a natural-language policy violation.
The entire skill scenario file is written exclusively in Chinese and does not indicate that language selection is optional or user-configurable. Under the policy, forcing a specific language or locale without opt-in is a natural-language policy violation unless the regional constraint is explicitly documented and justified.
The example request schema fixes language to zh-CN, which is a natural-language locale constraint. Because the document does not state that the skill is region-specific or allow alternate user-selected locales, it appears to force a specific language without opt-in.
The manifest describes generating Amap roadbook artifacts with itinerary, routing, weather reminders, and assumptions, but this exporter also synthesizes a dedicated budget sheet with hard-coded fare, lodging, meal, and total-budget estimates. That is not merely formatting existing roadbook data into Excel; it introduces new derived travel-finance content that is not mentioned in the file's own stated purpose of exporting roadbook.json to formatted Excel.
Detected: suspicious.dangerous_exec, suspicious.env_credential_access