Back to skill

Security audit

synaptic-mcp-paywall

Security checks for vulnerabilities and agentic risk

Overview

This skill is about blockchain API payments, but its instructions allow automatic spending and include insecure payment examples without enough user control or safety detail.

Review carefully before installing or copying this skill. Use only low-balance or delegated wallets, require explicit spend limits and allowlists, replace any recipient address with one you control, and implement full on-chain verification with replay protection before exposing paid endpoints.

Vulnerability Patterns
  • 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
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (2)

T09 · Insecure Skill Coding Practices

Error
Location
SKILL.md:19
Finding

Hardcoded Payment Recipient Can Divert API Revenue

Content
View full analysis
{ const txHash = req.headers['x-synaptic-tx']; if (!txHash) { return res.status(402).json({ error: "Payment Required", recipient: "syn1l8agc8qzgqqqu60jtatlhmh93a8my6xvm9ml0f", price_sUSD: "0.0008", network: "SynapticChain L1" }); } // Verify tx on-chain in <500ms via SynapticChain RPC next(); }); ``` ### Technical Analysis The middleware embeds a fixed cryptocurrency recipient address in the HTTP 402 response. The skill is advertised as allowing API owners to monetize their own endpoints, but the example does not require the owner to configure an address under their control. An API operator who copies the example without replacing the address will instruct clients to send payments to the embedded destination. Cryptocurrency transfers are generally irreversible, so an incorrect or third-party destination can result in permanent loss of revenue. The address itself is not a secret. The security issue is that an unexplained, fixed payment destination is placed in security-sensitive sample configuration without a mandatory owner-controlled configuration step or validation. ### Attack Path 1. An API operator installs or follows the skill documentation. 2. The operator copies the provided middleware into a premium endpoint. 3. A client requests the endpoint without an `x-synaptic-tx` header. 4. The server returns the hardcoded recipient address in the HTTP 402 response. 5. The client transfers funds to that address. 6. The API operator does not receive the payment unless the hardcoded address happens to be under the operator's control. ### Impact Assessment The issue can divert all payments generated through deployments that retain the hardcoded address. Its scope is lim ...[truncated 243 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
SKILL.md:19
Finding

HTTP 402 Paywall Bypass Through Unverified Transaction Header

Content
View full analysis
{ const txHash = req.headers['x-synaptic-tx']; if (!txHash) { return res.status(402).json({ error: "Payment Required", recipient: "syn1l8agc8qzgqqqu60jtatlhmh93a8my6xvm9ml0f", price_sUSD: "0.0008", network: "SynapticChain L1" }); } // Verify tx on-chain in <500ms via SynapticChain RPC next(); }); ``` ### Technical Analysis The middleware only tests whether the attacker-controlled `x-synaptic-tx` header is present. Although a comment says the transaction should be verified on-chain, the example performs no verification before calling `next()`. Consequently, any non-empty value—including a fabricated string, an unrelated transaction hash, a transaction with an insufficient amount, or a previously used transaction—satisfies the check. The code does not validate transaction existence, finality, network, asset, amount, recipient, sender, request association, or replay status. Because this middleware controls access to `/api/premium`, the missing verification creates a direct authentication and payment-authorization bypass. ### Attack Path 1. An attacker sends a request to `/api/premium`. 2. The attacker adds an arbitrary non-empty header, for example: ```http x-synaptic-tx: fake ``` 3. The `if (!txHash)` condition evaluates to false. 4. No RPC or blockchain validation is performed. 5. The middleware calls `next()`. 6. The attacker accesses the protected endpoint without making the required payment. The same flaw also permits reuse of a legitimate transaction because no nonce, request identifier, or consumed-transaction record is checked. ### Impact Assessment A remote, unauthenticated client can bypass the paywall and consume premium API functionality without payme ...[truncated 337 chars]
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
Findings (1)

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill explicitly says agents 'automatically sign and dispatch micro-settlement transactions' but does not disclose the security implications of autonomous spending, wallet attachment, transaction authorization scope, or key custody. In an agent-skill context, this can cause users to enable unattended on-chain payments without understanding that external services may trigger real fund movement, increasing the risk of unintended spending, abuse by malicious endpoints, or unsafe key exposure patterns.

Content

No source excerpt is available for this finding.