T08 · Insecure Dependencies
- Location
SKILL.md:14- Finding
Documented commands execute an undeclared package through npx
- Content
View full analysis
[args] # Borrower commands npx ts-node scripts/lp.ts [args] # LP commands ``` The README repeats this pattern for all financial operations: ```bash npx ts-node scripts/client.ts status npx ts-node scripts/client.ts borrow 5 npx ts-node scripts/client.ts repay all npx ts-node scripts/client.ts bridge 10 arc base npx ts-node scripts/lp.ts pool-status npx ts-node scripts/lp.ts deposit 100 npx ts-node scripts/lp.ts withdraw all ``` However, `ts-node` is not declared in the package manifest: ```json "dependencies": { "@circle-fin/adapter-viem-v2": "^1.4.0", "@circle-fin/bridge-kit": "^1.5.0", "dotenv": "^17.2.4", "ethers": "^6.16.0" }, "devDependencies": { "tsx": "^4.21.0", "typescript": "^5.9.3" } ``` ### Technical Analysis The Skill instructs users and agents to execute `npx ts-node`, but `ts-node` is neither a direct dependency nor represented as the intended local executable in the reviewed manifest. When no local binary is available, `npx` may resolve, download, and execute a package from the configured npm registry at invocation time. This bypasses the reviewed lockfile as the authoritative source for the command runner. It creates a mutable supply-chain execution path inside a process that is explicitly expected to have access to `WALLET_PRIVATE_KEY`. The project already defines local scripts using the locked `tsx` dependency: ```json "scripts": { "client": "npx tsx scripts/client.ts", "lp": "npx tsx scripts/lp.ts" } ``` Therefore, retrieving a separate runner at invocation time is not necessary for the declared functionality. ### Attack Path 1. A user exports `WALLET_PRIVATE_KEY` as required by the Skill. 2. The user or AI ag ...[truncated 1381 chars]- Remediation
View remediation
