Skip to main content
Glama
Solana Rent & Rug Shield MCP Gateway

Solana Rent & Rug Shield MCP Gateway

by sonnyman2014

simulate_solana_tx_drain

Simulates serialized Solana transactions before signing to detect inner-CPI SOL drains, stealth SPL approvals or authority delegations, rent traps, and unexpected balance changes.

Instructions

Pre-sign Layer-9 Inner-CPI Solana transaction drainer check. Inspects base64 or base58 serialized transactions before wallet signing to block malicious inner CPI SOL drains, stealth SPL Approve/SetAuthority delegations, creator-vault rent traps, and unexpected balance deltas.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "transaction": "<transaction>"
    },
    "name": "simulate_solana_tx_drain"
  }
}

Input Schema

NameRequiredDescriptionDefault
walletNoOptional fee-payer/signer Solana wallet public key (base58).
encodingNoEncoding of the serialized transaction ('base64' or 'base58').base64
transactionYesSerialized Solana transaction (unsigned or signed) in base64 or base58.
pro_pass_tokenNoOptional X-Pro-Pass-Token from Option A Unlimited Pro Pass.
payment_signatureNoOptional confirmed Solana transaction signature paying 89Sv5FvnMNRid1bn8y2Ti1vJPSxWxgiW9GSLsPpBnKK1 for x402 retry.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.6/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description must carry behavioral weight, and it does disclose the threat model and that it runs pre-signature. However, it never states the tool is read-only/non-submitting, what the outcome looks like (pass/fail verdict), or that the pro_pass_token and payment_signature parameters indicate an x402 payment gate with retry behavior. For a security gate that an agent may rely on before signing, the omission of the result semantics and payment flow is material.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

One front-loaded sentence that puts the operation and the pre-signing timing first, then enumerates the threat classes. Dense but mostly justified; the 'Layer-9 Inner-CPI' phrasing is jargon that adds little for an agent.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

There is no output schema, so the description is the only place a reader could learn what a check returns (verdict, flags, risk score), and it does not say. The payment-path parameters are also unexplained. Adequate for identifying the tool's domain, but incomplete for a tool whose result determines whether a signing action proceeds.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so all five parameters are already documented, including the base64/base58 encoding enum and the optional wallet key. The description's mention of 'base64 or base58' merely echoes the schema and adds no new meaning about, for example, how wallet or payment_signature affect the check.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

Names a specific verb (inspects a serialized transaction) and a specific resource, with the threat classes it targets ('inner CPI SOL drains', 'stealth SPL Approve/SetAuthority delegations'). It is distinguishable from the sibling token-audit and wallet-scan tools because it operates on a serialized transaction pre-signing, though it never explicitly contrasts itself with them.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives clear timing guidance: run 'before wallet signing' on base64 or base58 serialized transactions. It does not name when-not-to-use or point to a specific alternative tool, so it stops short of full routing guidance, but the context of use is unambiguous.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.