Back to skill

Security audit

AI电商视频广告 | 视频广告素材 | 信息流广告 | 广告视频生成 | LinkPix

Security checks for vulnerabilities and agentic risk

Overview

The skill matches its video-ad generation purpose, but it should be reviewed because it tells agents to install and upgrade an unpinned global CLI and configure credentials persistently.

Install only if you intend to use LinkPix/qhkit and are comfortable giving that service selected product media and an API token. Prefer a pinned, isolated qhkit install and platform-managed secrets; do not blindly run upgrade commands printed by the CLI, and confirm estimated credits before generation.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • 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
Findings (2)

T08 · Insecure Dependencies

Error
Location
SKILL.md:44
Finding
Unpinned third-party CLI installation and execution## Vulnerability Details **File Location**: `SKILL.md`, lines 44–47 and 73 **Vulnerability Type**: Unpinned and globally installed third-party dependency **Risk Level**: High ### Vulnerable Code ```bash npm i -g @iqinghu/qhkit ``` ```bash npx @iqinghu/qhkit <command> ... ``` ```bash npm i -g @iqinghu/qhkit@latest ``` ### Technical Analysis The Skill directs the agent to install or execute `@iqinghu/qhkit` without pinning an audited version or verifying package integrity. The explicit `@latest` upgrade instruction also allows the executed implementation to change after the Skill has been reviewed. npm packages can execute lifecycle scripts during installation. The installed CLI subsequently processes API credentials and user-selected local media. A compromised package release, publisher account, registry, mirror, or transitive dependency could therefore introduce arbitrary executable code. Global installation is broader than necessary for invoking this CLI. Although it does not inherently grant administrator privileges, it modifies the agent user's shared executable environment and can affect other sessions using the same account. If the installation is performed through an elevated npm configuration, the package may execute with those elevated privileges. ### Attack Path 1. An attacker compromises the package publisher, package registry, configured mirror, or a transitive dependency. 2. The attacker publishes a malicious version under the legitimate package name. 3. The agent follows the Skill and runs an unpinned global installation, `npx`, or the `@latest` upgrade. 4. Malicious lifecycle code or CLI code executes with the privileges of the agent process. 5. The malicious package can access files readable by that account, including selected media and locally available credentials, and can modify the user's environment or communicate over the network. ### Impact Assessment Successful exploitatio ...[truncated 707 chars]
Remediation
## Remediation Suggestions 1. Pin `@iqinghu/qhkit` to a specifically reviewed version rather than resolving an unconstrained version or `@latest`. 2. Record and verify the expected package integrity value through a lockfile or another trusted integrity mechanism. 3. Prefer a project-local or isolated installation over a global installation. 4. Avoid automatic upgrades. Review release provenance, changes, and integrity before changing the pinned version. 5. Where compatible with the package, disable npm lifecycle scripts during installation and explicitly enable only scripts proven necessary. 6. Do not recommend privilege elevation for installation. If installation cannot proceed with ordinary user privileges, stop and request an explicit user decision. 7. Restrict the CLI process to the minimum required files, environment variables, and network destinations. 8. Treat alternative registries as additional supply-chain trust boundaries and use only explicitly approved sources.

T09 · Insecure Skill Coding Practices

Error
Location
SKILL.md:68
Finding
Execution of upgrade commands supplied through runtime-controlled output## Vulnerability Details **File Location**: `SKILL.md`, line 68 **Vulnerability Type**: Unsafe execution of an unvalidated command from CLI output **Risk Level**: High ### Vulnerable Instruction The instruction at this location states, in English translation: ```text If the command returns a version-stage error, the message contains the upgrade command; execute it as instructed. ``` ### Technical Analysis The Skill instructs the agent to treat the `message` field returned by the CLI as an executable upgrade instruction. This crosses a trust boundary: runtime output controlled by the installed CLI or its backend is converted into a local command without an exact allowlist, argument validation, integrity verification, or separate user approval. If the CLI, dependency chain, update service, or backend response is compromised, the returned message could contain an arbitrary shell command rather than a legitimate npm upgrade command. Because the instruction says to execute the command as provided, shell metacharacters, command substitutions, redirections, or an entirely unrelated executable could be used to run attacker-controlled operations. ### Attack Path 1. An attacker compromises the installed CLI, one of its dependencies, or the backend response used to construct the version error. 2. The compromised component returns an error with `stage` set to `version`. 3. The accompanying `message` contains a malicious command disguised as an upgrade instruction. 4. The agent follows the Skill's instruction and submits that text to a shell. 5. The command executes with the agent process's privileges, allowing file access, credential theft, network communication, or system modification within that security context. ### Impact Assessment Exploitation can result in arbitrary command execution with the privileges of the agent account. The attacker may access user-readable files, media, environment variables, API tokens, and netwo ...[truncated 405 chars]
Remediation
## Remediation Suggestions 1. Never execute a command extracted from the CLI's `message`, standard output, or standard error. 2. Treat the returned message strictly as informational text for the user. 3. Replace the dynamic behavior with a locally defined, exact allowlist of permissible package-management operations. 4. Require an exact package name and a pinned, reviewed version; reject additional shell syntax or arguments. 5. Invoke the package manager through a structured process API with a fixed executable and argument array rather than through a shell. 6. Require explicit user confirmation before any installation or upgrade that changes the local environment. 7. Verify package provenance and integrity before installation. 8. Run upgrades without elevated privileges and in an isolated, project-local environment wherever possible.
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 (4)

Context-Inappropriate Capability

Medium
Confidence
93% confidence
Finding
The skill directs the agent to install missing runtime dependencies and globally install a CLI, including downloading Node.js binaries and modifying PATH. That expands the skill from content generation into environment bootstrapping and software installation, which can change the host system state and increase supply-chain and execution risk beyond the declared user task.

Context-Inappropriate Capability

Medium
Confidence
91% confidence
Finding
The skill instructs the agent to collect and configure an API token, including setting a persistent environment variable or writing config via the CLI. This introduces credential-handling behavior not clearly bounded to transient task execution, creating risk of credential exposure, persistence, or reuse across sessions.

Vague Triggers

Medium
Confidence
87% confidence
Finding
The manifest says the skill must trigger for broad, common ad-video requests, creating an overly aggressive activation condition. This can cause the agent to invoke a high-impact external-tool workflow, including installation and credential setup paths, when the user may only be asking for generic advice or planning help.

Vague Triggers

Medium
Confidence
84% confidence
Finding
The trigger guidance provides only broad positive examples and lacks boundaries for non-applicable cases. In context, that ambiguity matters because activation may lead to external CLI use, pricing calls, polling, installation steps, and credential configuration, increasing the chance of unnecessary or surprising actions.

Static analysis

No suspicious patterns detected.