T09 · Insecure Skill Coding Practices
- Location
scripts/download.ts:181- Finding
Path Traversal Through Untrusted Spreadsheet Sheet Names
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
The skill mostly matches its Feishu link-extraction purpose, but its optional downloader has under-scoped browser and file-write behavior that users should review before installing.
Install only if you are comfortable with a skill that controls Chrome, visits all links found in a public Feishu sheet, and writes local files. Review extracted URLs before downloading, avoid using an authenticated or personal debugging Chrome profile, choose a low-risk output directory, and prefer a locally installed trusted Bun runtime instead of the unpinned npx command.
scripts/download.ts:181Path Traversal Through Untrusted Spreadsheet Sheet Names
scripts/download.ts:127Unrestricted Browser Navigation Allows Access to Internal Resources
SKILL.md:29Unpinned Runtime Package Is Downloaded and Executed Through npx
The skill description understates important behaviors: it writes local files and attaches to or launches Chrome, potentially inspecting a live browser context via CDP. When implementation capabilities exceed the declared purpose, users and policy systems may approve a skill without understanding that it can access broader browser/session data or create local artifacts.
The skill searches ~/.claude/skills and /workspace/.claude/skills, which accesses agent configuration directories rather than using a provided, scoped path. Access to these locations can reveal local configuration/layout information and becomes more dangerous because the same skill also attaches to browser instances and runs executable commands, increasing the blast radius if modified or repurposed.
Resolve the skill directory:
SKILL_DIR="$(find ~/.claude/skills /workspace/.claude/skills -maxdepth 1 -name feishu-sheet-links -type d 2>/dev/null | head -1)"
Run the extraction script:
The README instructs users to execute npx -y bun without pinning a specific version, which means the latest package matching bun from the npm registry will be fetched and executed at runtime. If the registry package is compromised, typo-confused, or changes behavior, users could run unintended code on their systems; this is more concerning in a skill context because the documentation directly encourages copy-paste execution.
This second npx -y bun invocation has the same supply-chain risk: it downloads and runs an unpinned package from the registry at execution time. Because this command is used for batch downloading content, it is likely to be run by end users as documented, so a compromised upstream package could achieve arbitrary code execution in the user's environment.
npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.
npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.
The skill invokes networked code and reads environment-dependent locations but does not declare any tool scope or permissions boundary. That makes the capability surface implicit rather than auditable, increasing the chance an agent executes network/file-affecting behavior without clear user or platform review.
Enumerating ~/.claude/skills and /workspace/.claude/skills discloses the existence and layout of locally installed skills. Even though this example filters for one name, it still probes sensitive agent-specific directories and normalizes a pattern that can be extended to inventory local capabilities for follow-on abuse.
Resolve the skill directory:
SKILL_DIR="$(find ~/.claude/skills /workspace/.claude/skills -maxdepth 1 -name feishu-sheet-links -type d 2>/dev/null | head -1)"
Run the extraction script:
Using npx -y bun without a pinned version allows retrieval of whatever package/version is current at execution time. This creates a supply-chain risk where compromised or unexpected upstream changes can alter behavior and execute arbitrary code on the host.
The second npx -y bun invocation has the same unpinned remote-execution risk as the first: execution depends on live package resolution at run time. An attacker controlling or poisoning the package supply chain could obtain code execution in the agent environment.
The usage string instructs users to run the script via npx -y bun, which pulls and executes the latest bun package without pinning a specific version or verifying integrity. If the upstream package is compromised or a malicious version is published, users could execute attacker-controlled code before this downloader even runs; because this skill is explicitly designed to download external Feishu-linked content, its workflow already encourages network-reliant execution and makes supply-chain trust more important, not less.
The usage string instructs execution via npx -y bun without pinning a specific package version, which allows whatever version is current in the registry at runtime to be installed and executed. If the package is compromised, typosquatted, or updated with malicious code, users running the documented command could execute untrusted code on their system.
The README describes batch-downloading linked articles into local Markdown files but does not clearly warn that this step will make outbound requests to every extracted external URL and write untrusted remote content to disk. In the context of a link-extraction/download skill, that omission increases the risk of users unintentionally contacting attacker-controlled hosts, downloading harmful or sensitive content, or storing dangerous Markdown/HTML payloads locally.
The skill writes extracted link data to feishu-links.json as part of its normal workflow but does not clearly warn the user about this file-creation side effect before doing so. Unexpected local writes can expose sensitive link inventories, clutter workspaces, or conflict with user expectations in restricted environments.
Detected: suspicious.dangerous_exec, suspicious.env_credential_access