SunSwap DEX Trading

Fail

Audited by Snyk on Mar 3, 2026

Risk Level: CRITICAL
Full Analysis

CRITICAL E006: Malicious code pattern detected in skill scripts.

  • Malicious code pattern detected (high risk: 0.90). The scripts implement normal DEX functionality but include suspicious, non-official router API endpoints and router addresses, automatically load private keys from environment/file locations, and perform automatic (near-unlimited) approvals to the configured router; while there is no explicit code that sends private keys out, the hard-coded external endpoints (rot.endjgfsv.link / tnrouter.endjgfsv.link) and router addresses could be attacker-controlled and used to manipulate quotes/transactions or drain funds (supply-chain/backdoor pattern), and the code’s probing for local private-key files increases the risk of credential misuse.

MEDIUM W011: Third-party content exposure detected (indirect prompt injection risk).

  • Third-party content exposure detected (high risk: 0.90). The skill fetches live quotes from external SunSwap Smart Router API endpoints (see resources/sunswap_contracts.json and scripts/quote.js which calls https://rot.endjgfsv.link/... and https://tnrouter.endjgfsv.link/...), and scripts/swap.js directly consumes that API response to build transaction parameters and decide approvals/execution, so untrusted third‑party responses can materially influence tool behavior.

MEDIUM W012: Unverifiable external dependency detected (runtime URL that controls agent).

  • Potentially malicious external URL detected (high risk: 0.90). The skill calls the external Smart Router APIs at runtime (axios.get to https://rot.endjgfsv.link/swap/router and https://tnrouter.endjgfsv.link/swap/router in scripts/quote.js) and the returned JSON is used to build swap parameters and drive on-chain transactions, so these URLs directly control execution and are required for operation.

MEDIUM W009: Direct money access capability detected (payment gateways, crypto, banking).

  • Direct money access detected (high risk: 1.00). The skill is explicitly a crypto trading tool for the SunSwap DEX on the TRON blockchain. It requires a TRON_PRIVATE_KEY, offers scripts that approve tokens and sign/send swaps (node scripts/swap.js with a --execute flag), returns transaction hashes, and automates checking balance/allowance, approvals, and executing on-chain swaps. These are direct blockchain wallet and transaction operations (signing/sending token transfer/swap transactions), i.e., explicit capability to move funds. Therefore it meets the "Direct Financial Execution" criteria.
Audit Metadata
Risk Level
CRITICAL
Analyzed
Mar 3, 2026, 03:20 AM