Back to skill

Security audit

forgex-cli

Security checks for vulnerabilities and agentic risk

Overview

The skill is a coherent wallet and trading CLI guide, but it asks users to install unaudited executable code and handle wallet secrets in risky ways that could expose funds.

Review this carefully before installing. Only use it if you trust the forgex-cli npm package and can verify the exact version/source. Do not paste real private keys or passwords into shell commands or agent chats, avoid plaintext wallet CSV exports, use dry runs first, and keep any wallet backups encrypted and outside cloud sync or source control.

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 (3)

T08 · Insecure Dependencies

Error
Location
SKILL.md:38
Finding

Unpinned Global Installation of Unverifiable Third-Party Executable Code

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
SKILL.md:118
Finding

Wallet Credentials and API Secrets Passed Through Command-Line Arguments

Content
View full analysis
[subcommand] [options] ``` ```bash # Set Codex API key for market data forgex config set codexApiKey "your-api-key" ``` ```bash # Generate new wallets (max 100 per group) forgex --password "pwd" wallet generate --group 1 --count 10 # Add an existing wallet by private key forgex --password "pwd" wallet add --group 1 --private-key "Base58Key..." --note "main wallet" # Remove a wallet from group forgex --password "pwd" wallet remove --group 1 --address "WalletAddress..." # Import from CSV (format: privateKey,note) forgex --password "pwd" wallet import --group 1 --file ./wallets.csv ``` ```bash # Export all groups as encrypted JSON forgex --password "pwd" wallet export-group \ --file ./all-groups.json \ --encrypt \ --password "file-encryption-password" # Import all groups from JSON backup forgex --password "pwd" wallet import-group \ --file ./all-groups.json \ --password "file-encryption-password" ``` ### Technical Analysis The documented interface places wallet passwords, raw private keys, API keys, and backup-encryption passwords directly in command-line arguments. Command arguments are not an appropriate secret transport mechanism because they may be exposed through: - Shell history files. - Process-listing and process-inspection interfaces. - Terminal session recording. - Debugging and observability tools. - Agent transcripts and command logs. - Wrapper scripts, audit logs, or error reports. The raw `--private-key` argument is particularly sensitive because possession of a Solana private key generally enables transaction signing without needing the accompanying ...[truncated 1686 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
SKILL.md:187
Finding

Plaintext Export of Wallet Private-Key Material to CSV

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
Findings (2)

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The skill repeatedly instructs users to pass wallet passwords and private keys directly on the command line, including examples like --password and --private-key. Command-line arguments are commonly exposed through shell history, process listings, logging, terminal scrollback, and orchestration telemetry, which can lead to wallet compromise and theft of on-chain funds.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The backup and export examples show writing wallet groups and CSV/JSON backups containing highly sensitive wallet material to local files, but do not clearly warn that these files may contain private keys and must be encrypted, access-restricted, and handled as secrets. If stored insecurely, copied into cloud sync folders, committed to repositories, or left with weak permissions, an attacker can recover wallet credentials and drain assets.

Content

No source excerpt is available for this finding.