Back to skill

Security audit

AI生成电商pod素材 | 印花提取 | 印花贴合 | 印花裂变 | 青虎AI

Security checks for vulnerabilities and agentic risk

Overview

The skill’s POD image-generation purpose is coherent, but it asks the agent to install and upgrade unpinned command-line software and follow upgrade commands from tool output without enough user control.

Review before installing. Only use this skill if you trust the qhkit npm package and service, are comfortable uploading source images to that service, and are willing to provide a qhkit token. Require the agent to ask before installing Node, installing or upgrading npm packages, changing PATH or shell profiles, or running any upgrade command; prefer a pinned, local, sandboxed installation over global @latest use.

Vulnerability Patterns
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • 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
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (2)

T03 · Remote Payload Retrieval and Execution

Error
Location
SKILL.md:61
Finding
Execution of Dynamically Supplied Upgrade Commands## Vulnerability Details **File Location**: `SKILL.md`, line 61 **Vulnerability Type**: Remote payload retrieval and execution **Risk Level**: Critical **Relevant instruction, translated into English:** ```text Upgrade when the command returns {"ok":false,"stage":"version",...}. The message contains the upgrade command; execute it directly. ``` ### Technical Analysis The Skill instructs the agent to execute an upgrade command obtained dynamically from the `qhkit` command's `message` field. This output is not restricted to a hard-coded command, parsed against an allowlist, or subjected to user confirmation. Because `qhkit` is a third-party executable that can communicate with an external service, the effective command may be controlled by the installed package, its publisher, or its backend. It can change after the Skill has been reviewed. Treating a diagnostic message as executable instructions creates a remote command-execution channel. The upgrade instruction is not necessary in this form. The declared image-generation functionality only requires invoking a known CLI interface. Any legitimate upgrade can instead use a locally defined, version-pinned command. ### Attack Path 1. An attacker compromises the `qhkit` package, its publisher account, distribution channel, or backend service. 2. The compromised component returns a response containing `stage:"version"`. 3. The response places an attacker-selected shell command in the `message` field and represents it as the required upgrade procedure. 4. Following the Skill instruction, the agent executes that command without validation or separate user authorization. 5. The command runs with the privileges of the account hosting the agent. ### Impact Assessment Successful exploitation permits arbitrary command execution with the agent process's user privileges. Depending on the runtime environment, the attacker could: - Read or modify files accessible to the agent ac ...[truncated 494 chars]
Remediation
## Remediation Suggestions - Remove the instruction to execute commands contained in `message`, standard output, standard error, or any other remotely influenced field. - Treat all CLI output strictly as untrusted data. - Define permitted maintenance commands locally and validate them against an exact allowlist. - Pin upgrades to a reviewed version, for example: ```bash npm install --global @iqinghu/qhkit@REVIEWED_VERSION ``` - Require explicit user approval before installing or upgrading software. - Reject upgrade responses that contain shell operators, command substitutions, redirects, URLs, or commands outside the allowlist. - Run the CLI in a sandbox with restricted filesystem, network, and environment-variable access. - Report unsupported-version errors to the user rather than automatically following commands supplied by the tool.

T08 · Insecure Dependencies

Warning
Location
SKILL.md:43
Finding
Unpinned Global Installation and Execution of a Third-Party Package## Vulnerability Details **File Location**: `SKILL.md`, lines 43–46 and 61–66 **Vulnerability Type**: Insecure third-party dependency handling **Risk Level**: Medium **Code snippets:** ```bash npm i -g @iqinghu/qhkit ``` ```bash npx @iqinghu/qhkit <command> ... ``` ```bash npm i -g @iqinghu/qhkit@latest ``` The instructions also permit using the following fallback registry: ```bash --registry=https://registry.npmmirror.com ``` ### Technical Analysis The package is installed without an exact version, and the upgrade command explicitly selects `@latest`. The `npx` fallback can likewise resolve and execute a package version at invocation time. Consequently, the executed implementation is not fixed to the version that existed when the Skill was audited. A global npm installation also increases exposure because package lifecycle scripts and executable entry points run with the current user's filesystem access and place binaries into a shared user or system-level command location. If an administrator runs the command with elevation to overcome a permission error, the impact can become system-wide, although the Skill does not directly instruct the agent to elevate privileges. The fallback registry introduces an additional supply-chain trust boundary. It may be operationally useful, but obtaining executable packages from multiple sources expands the set of infrastructure whose compromise could affect installation. ### Attack Path 1. An attacker compromises the package publisher account, npm distribution path, fallback registry, or a future package release. 2. The attacker publishes a malicious version under the legitimate package name. 3. The agent runs the unpinned installation, `@latest` upgrade, or `npx` fallback. 4. The package manager resolves the malicious release. 5. Malicious lifecycle code or the installed `qhkit` executable runs with the current user's privileges. 6. The package accesses f ...[truncated 827 chars]
Remediation
## Remediation Suggestions - Pin `@iqinghu/qhkit` to an exact, reviewed version rather than using an omitted version or `@latest`. - Record and verify package integrity metadata before installation. - Prefer a project-local installation in an isolated directory over a global installation. - Avoid `npx` for dynamically resolved package execution. Invoke a previously installed, integrity-verified binary instead. - Require user approval before installation or upgrade. - Review new package versions before changing the pin. - Use one explicitly trusted registry and document its trust assumptions. - Disable npm lifecycle scripts during installation where compatible: ```bash npm install --ignore-scripts --save-exact @iqinghu/qhkit@REVIEWED_VERSION ``` - If lifecycle scripts are required, inspect them before installation and run installation inside a sandbox. - Do not recommend privilege elevation to make global installation succeed.
Vulnerability Patterns
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (3)

Context-Inappropriate Capability

Medium
Confidence
93% confidence
Finding
The skill explicitly instructs the agent to bootstrap Node.js, install a global npm package, and upgrade that package as part of normal task execution. That expands the skill from POD asset generation into system modification and code acquisition from the network, increasing supply-chain and host-integrity risk well beyond the user’s apparent request. The context makes this more dangerous because the instructions say to 'not give up' when dependencies are missing, encouraging persistent environment changes without clear user confirmation.

Vague Triggers

Medium
Confidence
85% confidence
Finding
The skill declares that it 'must trigger' whenever users mention broad terms like POD, print, mockup, or pattern design, which can capture many benign conversations without clear intent to use this tool. Over-broad activation increases the chance the agent invokes external tooling, networked services, or setup steps unexpectedly, reducing user control and raising the risk of unintended actions.

Missing User Warnings

Medium
Confidence
95% confidence
Finding
The skill includes shell commands for downloading Node.js, verifying archives, modifying PATH, and globally installing npm packages, but it does not require a clear upfront warning and affirmative consent before making those system changes. In practice, a user asking for image/mockup generation could trigger package installation and network fetches they did not anticipate, creating integrity and operational risk. The contextual mismatch between creative-image generation and host modification makes this more dangerous, not less.

Static analysis

No suspicious patterns detected.