Back to skill

Security audit

opencli-usage

Security checks for vulnerabilities and agentic risk

Overview

This skill is a disclosed orientation guide for OpenCLI, but users should treat its browser-session, plugin, and install features as powerful and review them before use.

Install only from sources you trust, prefer pinned versions or reviewed commits where possible, and be cautious when letting OpenCLI use logged-in browser sessions, install GitHub plugins, or pass through external CLIs because those actions can operate with your local account and existing credentials.

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
SKILL.md:33
Finding

Unpinned Third-Party Packages and Git-Based Plugins

Content
View full analysis
= 21 opencli doctor # run before browser-dependent work (see below) # From source git clone git@github.com:jackwener/OpenCLI.git cd OpenCLI && npm install npx tsx src/main.ts # same surface, no global install ``` At lines 128–131: ```bash opencli plugin install github:user/repo # install opencli plugin list [-f json] # see installed opencli plugin update [name] | --all # keep current opencli plugin uninstall ``` ### Technical Analysis The documented installation commands retrieve executable software without pinning it to reviewed, immutable versions or commits: - `npm install -g @jackwener/opencli` installs the package version currently selected by the registry. - `git clone` checks out the repository's current default branch rather than a reviewed commit. - `npm install` resolves and installs the dependency graph associated with the retrieved source. Package lifecycle scripts may execute during installation unless explicitly disabled. - `npx tsx` may resolve a package dynamically when it is not already installed and then executes the project entry point. - Plugin installation accepts a generic `github:user/repo` source, while plugin updates can retrieve newer code without requiring a reviewed commit hash. Consequently, the effective code installed or executed later may differ from the code that was previously audited. Exploitation would require compromise or malicious control of a selected package, transitive dependency, repository, plugin, or release channel. The file does not itself contain an embedded malicious payload, so this finding conc ...[truncated 1637 chars]
Remediation
View remediation
``` 2. Publish and verify package integrity metadata or signed release artifacts. Document the expected checksum or signature and require verification before installation. 3. Pin source installations to a reviewed commit or signed tag: ```bash git clone git@github.com:jackwener/OpenCLI.git cd OpenCLI git checkout --detach ``` 4. Commit a lockfile and use deterministic dependency installation, such as `npm ci`, rather than unconstrained resolution through `npm install`. 5. Consider disabling dependency lifecycle scripts during initial installation where compatible: ```bash npm ci --ignore-scripts ``` Any scripts that are genuinely required should be separately reviewed and run explicitly. 6. Avoid dynamic `npx` package resolution. Install a pinned `tsx` version through the lockfile and invoke the local binary. 7. Require plugins to be pinned to immutable commit hashes or signed releases. Maintain an allowlist of reviewed plugin repositories and versions. 8. Make plugin updates explicit rather than automatically tracking mutable upstream state. Display the old and new commit hashes and require review or confirmation before activation. 9. Run plugins and browser-integrated components with least privilege. Restrict access to sensitive environment variables, credentials, files, and authenticated browser sessions where practical. ]]>
Vulnerability Patterns
  • Rogue AgentSelf-Modification, Session Persistence
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (3)

Rp1

Medium
Category
MCP Rug Pull
Confidence
70% confidence
Finding

npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
60% confidence
Finding

Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Content

Scanner excerpt · SKILL.md (reported line 120)May include surrounding context.

opencli plugin list [-f json] # see installed opencli plugin update [name] | --all # keep current opencli plugin uninstall opencli plugin create # scaffold a new plugin

text

## External CLI passthrough

Session Persistence

Medium
Category
Rogue Agent
Confidence
60% confidence
Finding

Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Content

Scanner excerpt · SKILL.md (reported line 120)May include surrounding context.

opencli plugin list [-f json] # see installed opencli plugin update [name] | --all # keep current opencli plugin uninstall opencli plugin create # scaffold a new plugin

text

## External CLI passthrough