Back to skill

Security audit

APort Agent Guardrail

Security checks for vulnerabilities and agentic risk

Overview

The skill’s guardrail purpose is coherent, but it asks users to run mutable external installer code that then changes agent-wide tool-call enforcement.

Review this carefully before installing. Use only a pinned, reviewed version or immutable commit, avoid running it with elevated privileges, and understand that it will persistently mediate future OpenClaw tool calls and may send policy-check context to APort in hosted mode.

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

Error
Location
SKILL.md:16
Finding
Execution of Unpinned Third-Party Installer Code<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md`, lines 16–26 **Vulnerability Type**: Unpinned third-party dependency and installer execution **Risk Level**: High ### Vulnerable Code ```markdown ```bash # Recommended (no clone needed) npx @aporthq/agent-guardrails # Hosted passport: skip the wizard by passing agent_id from aport.io npx @aporthq/agent-guardrails <agent_id> ``` Get a Hosted Passport **agent_id** at [aport.io](https://aport.io/builder/create/) after creating a passport there. __*OPTIONAL*__ From the repo (clone first): [github.com/aporthq/aport-agent-guardrails](https://github.com/aporthq/aport-agent-guardrails) — then run `./bin/openclaw` or `./bin/openclaw <agent_id>` from the repo root. ``` ### Technical Analysis The documented installation procedures execute externally maintained code without pinning it to an exact package version, immutable source commit, integrity hash, or cryptographically signed release. Running `npx @aporthq/agent-guardrails` resolves and executes the package version selected by the npm registry at installation time. Consequently, the code executed by a user can differ from the code that existed when this Skill was reviewed. The alternative GitHub workflow similarly tells users to clone the repository and execute `./bin/openclaw` without identifying a reviewed commit or release. This creates a supply-chain trust boundary in which compromise of the npm publisher account, registry distribution path, GitHub account, repository, or installer release process could cause arbitrary attacker-controlled code to execute. The project contains only `SKILL.md`, so the actual installer, plugin, and wrapper implementations are not available locally for verification. The behavior is not, by itself, proof that the external package is malicious. The vulnerability is that the instructions provide no mechanism to guarantee that the remotely obtained code is the same code that was audited. ### Attack Path 1. An atta ...[truncated 1799 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Pin the npm command to an exact reviewed version: ```bash npx --yes @aporthq/agent-guardrails@<exact-version> ``` Do not use version ranges or mutable tags such as `latest`. 2. Publish and document a cryptographic integrity value for the package artifact. Verify its checksum or signature before execution. 3. For the GitHub installation path, require checkout of an immutable reviewed commit: ```bash git clone https://github.com/aporthq/aport-agent-guardrails.git cd aport-agent-guardrails git checkout --detach <reviewed-full-commit-hash> ``` 4. Prefer signed release tags and document how users must verify the signature against a separately published, trusted maintainer key. 5. Vendor the installer and security-sensitive wrapper code in the Skill package where practical, allowing the complete execution path to be audited together with `SKILL.md`. 6. Publish package lockfiles, provenance attestations, software bills of materials, and reproducible-build information. 7. Run installation with the least-privileged account necessary. Explicitly warn users not to execute the installer as root or an administrator unless that privilege is demonstrably required. 8. Document every file, plugin, wrapper, configuration entry, and network endpoint created or accessed by the installer so users can verify the resulting installation. ]]>
Vulnerability Patterns
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
Findings (3)

Rp1

Medium
Category
MCP Rug Pull
Confidence
93% confidence
Finding
The skill instructs users to execute a package directly from the registry via npx without pinning an exact version. That creates a supply-chain risk: if the upstream package is updated maliciously, compromised, or publishes a breaking version, users may execute unreviewed code during installation with the trust implied by this security-focused guardrail skill.

Rp1

Medium
Category
MCP Rug Pull
Confidence
94% confidence
Finding
This installation command again relies on an unpinned npx package, allowing whatever version is current at execution time to run. Because the command accepts an `agent_id` and is part of setting up a tool that intercepts agent actions, compromise here could subvert the guardrail itself or execute arbitrary installer logic on the host.

Rp1

Medium
Category
MCP Rug Pull
Confidence
90% confidence
Finding
Although this line is descriptive text rather than the primary install block, it still references the same unpinned npx execution pattern and normalizes running registry-fetched code without a fixed version. In a security product, this context makes the issue more dangerous because users are especially likely to trust and execute the command without additional scrutiny.