Back to skill

Security audit

critical-writing

Security checks for vulnerabilities and agentic risk

Overview

This is a disclosed Chinese debate-style writing workflow, with usability and install-hygiene cautions but no evidence of hidden, destructive, or data-exfiltrating behavior.

Install this if you want a Chinese-first, structured writing process that asks questions before drafting and runs a critique/debate pass. For quick one-shot writing, it may feel too forceful. Avoid the unpinned npx install path unless you trust the package source; prefer ClawHub installation, manual installation, or a pinned reviewed CLI version.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (1)

T08 · Insecure Dependencies

Warning
Location
README.md:31
Finding
Unpinned Third-Party Package Execution Through npx## Vulnerability Details **File Location**: `README.md`, line 31 **Vulnerability Type**: Unpinned executable dependency **Risk Level**: Medium **Vulnerable code:** ```bash npx @skill-hub/cli install critical-writing --agent claude ``` ### Technical Analysis The documented installation command invokes `@skill-hub/cli` through `npx` without specifying an exact package version or verifying package integrity. When a user runs this command, npm resolves the package version from the configured registry at execution time and may download and execute a release that did not exist when this project was audited. This creates a supply-chain trust boundary outside the reviewed repository. If the package publisher account, package distribution process, or configured npm registry is compromised, an attacker could publish or substitute a malicious package version. The malicious package could execute through npm lifecycle scripts or the CLI entry point under the privileges of the user running the command. The command appears only in installation documentation and is not automatically executed by the Skill. Exploitation therefore requires a user or automated installation process to follow the documented command. ### Attack Path 1. An attacker compromises the `@skill-hub/cli` publishing account, its build pipeline, or a package registry used by the victim. 2. The attacker publishes or serves a malicious version under the expected package name. 3. A user follows the installation instructions and executes: ```bash npx @skill-hub/cli install critical-writing --agent claude ``` 4. `npx` resolves and downloads the attacker-controlled release because no exact version or integrity value is specified. 5. npm lifecycle code or the malicious CLI entry point executes with the invoking user's permissions. 6. The payload can access or modify resources available to that user, including project files, user configuration, environment vari ...[truncated 881 chars]
Remediation
## Remediation Suggestions 1. Pin the CLI to a reviewed, immutable version: ```bash npx --yes @skill-hub/cli@X.Y.Z install critical-writing --agent claude ``` 2. Verify the selected release before documenting it: - Review the published package contents. - Confirm the package publisher and registry source. - Validate npm provenance or release signatures where available. - Record and verify the package archive integrity hash. 3. Use a trusted, explicitly configured registry and avoid registry settings that permit dependency substitution. 4. Prefer a reproducible installation process backed by a lockfile and integrity metadata when the CLI is used in CI or automated environments. 5. Advise users not to run installation commands as root or an administrator. Use a restricted account with access limited to the intended Skill installation directory. 6. Consider providing a reviewed local installation method as the recommended option, while clearly identifying `npx` installation as execution of third-party code.
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (8)

Vague Triggers

High
Confidence
98% confidence
Finding
The trigger conditions are extremely broad and explicitly say the skill 'must' be used for common writing requests, which can cause the agent to over-invoke this workflow and override normal user intent. Because the workflow also forbids skipping steps, it can hijack benign requests into an unnecessarily rigid multi-step process, increasing prompt-scope capture and making it easier for a skill to dominate unrelated interactions.

Hidden Instructions

High
Category
Prompt Injection
Content
# Test Cases — critical-writing v2.0

## Test 1:基础触发
Confidence
60% confidence
Finding
Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Rp1

Medium
Category
MCP Rug Pull
Confidence
93% confidence
Finding
The README instructs users to run `npx @skill-hub/cli install critical-writing --agent claude` without pinning an exact package version. `npx` will fetch the latest published CLI at execution time, so if the package is compromised, typosquatted, or updated with malicious code, users may execute attacker-controlled code during installation. In a skill distribution context, installation commands are part of the trust boundary, so this is more dangerous than a purely informational reference.

Natural-Language Policy Violations

Medium
Confidence
91% confidence
Finding
The metadata hard-codes zh-CN without offering user choice, which can lead to mismatched language behavior and reduce transparency or usability for users operating in other languages. In an agent setting, forced locale can function as an unwanted behavioral constraint that overrides user preference, though it is not directly a high-severity security issue.

Natural-Language Policy Violations

Medium
Confidence
96% confidence
Finding
The title and overall guidance are explicitly framed as a Chinese writing manual, which establishes a mandatory Chinese-language/locale context. The document does not offer an opt-in language choice or clearly justify that the skill is region-specific, so it can violate language/locale policy requirements.

Vague Triggers

Medium
Confidence
92% confidence
Finding
This markdown file is in scope for vague-trigger review. The phrase "或初稿完成后自动进入" makes activation broad and unclear because it does not specify whether every completed draft should trigger the skill automatically or under what constraints, which could cause unintended invocation without an explicit user request.

Description-Behavior Mismatch

Low
Confidence
89% confidence
Finding
The manifest description frames this skill as a closed-loop collaborative writing workflow centered on questioning, planning, drafting, debate, and rewrite. In Step 6, the skill additionally offers to save the result as files, which is a distinct output/export capability not disclosed in the manifest’s core description.

Natural-Language Policy Violations

Low
Confidence
93% confidence
Finding
This markdown file is entirely written in Chinese and does not indicate that the user can choose another language or that the skill is intentionally limited to a Chinese-speaking context. Under the policy rule for language or locale constraints, forcing a single language without opt-in can be a natural-language policy violation.

Static analysis

No suspicious patterns detected.