T09 · Insecure Skill Coding Practices
- Location
scripts/generate_template.py:111- Finding
Spreadsheet Formula Injection Through Untrusted Cell Values
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This skill appears intended to generate Excel import templates, but it has real review-worthy risks around unsafe spreadsheet output, file overwrite paths, unpinned installs, and sensitive financial OCR data handling.
Review before installing. Use an isolated environment, pin dependency versions, avoid confidential or regulated screenshots unless approved, and do not open generated workbooks from untrusted source data until formula-like values and output filenames are sanitized.
scripts/generate_template.py:111Spreadsheet Formula Injection Through Untrusted Cell Values
scripts/generate_template.py:77Arbitrary Output Location Through Table-Name Path Traversal
INSTALL.md:40Unpinned Third-Party Package Installation and Execution
The install guide instructs users to run npx clawhub without pinning an exact package version. Because npx resolves and executes the currently published package, a compromised upstream release or typosquatted package update could cause arbitrary code execution on the user's machine during login or publishing flows.
The publish command uses npx clawhub without a pinned version, which means the command may execute whatever version is latest at runtime. If the package supply chain is compromised, an attacker could run malicious code in the context of the publisher's workstation and credentials.
The installation command tells downstream users to run npx clawhub install excel-import-helper without pinning the CLI version. This expands the attack surface to all consumers of the skill, since any malicious or unexpectedly changed upstream CLI release would be executed automatically.
The usage section says users can directly say "帮我把 xxx.png 导入到模板", but it does not define a bounded set of trigger phrases, scope constraints, or exclusion conditions. This natural-language phrasing is broad enough that ordinary conversation about importing an image into a template could unintentionally activate the skill.
The skill instructs users to process screenshots/images for OCR in financial-report scenarios, which can contain sensitive financial, banking, or personal data, yet provides no privacy, retention, or handling warning. This increases the risk that users submit confidential screenshots without understanding exposure, especially since the OCR dependency may also perform first-run network downloads.
This code file contains natural-language documentation entirely in Chinese, including the module description and usage examples, and later prints Chinese-only status messages. The policy explicitly flags language or locale constraints when a skill forces a specific language without offering user choice or documenting a justified regional scope.
The natural-language content of the skill is entirely in Chinese and does not offer any language choice or note that the skill is intended only for Chinese-speaking users. Under the policy, forcing a specific language without user opt-in can be a locale/language policy violation unless clearly justified and documented.
The manifest describes a tool for importing fields from Excel files or screenshots and performing OCR, which implies local file processing. However, the documentation states that cnocr will automatically download models on first run, introducing network activity not mentioned in the skill description. This is a small but real behavior expansion beyond the described local import workflow.
For a skill framed as an Excel/screenshot import helper, silently fetching external OCR models is an additional capability with security and deployment implications. While OCR itself is in scope, outbound retrieval of runtime assets is a separate capability that should be explicitly declared if relied upon.
This code includes natural-language comments and a docstring exclusively in Chinese, such as the module description and function documentation, which can indicate a language-specific policy baked into the skill without offering user opt-in or documenting a justified locale restriction. Under the stated policy, forcing a specific language without choice can be a natural-language policy violation.