A swap provider returns two things that need to agree: a description of the trade and instructions that execute it. A screen can show the expected tokens and amounts while the transaction underneath asks for something else.
Rockpile checks that relationship before signing. This article follows a user-initiated Jupiter spot swap on Solana. Quote validation, native instruction validation, simulation, and user review each check a different part of that request.
Preserve the trade you requested
The starting point is the user’s intent: which wallet is trading, which asset it will spend, how much it will spend, which asset it should receive, and the permitted slippage.
Token identity matters here. A ticker or logo is presentation data; it does not uniquely identify an asset. Validation uses the token’s mint address—the on-chain identifier for that token—and the amount in native integer units. Decimal information must also agree with the asset, so an incorrect display conversion cannot quietly change the meaning of the amount.
The returned quote must preserve the requested input. Rockpile rejects a changed input amount rather than treating the provider’s response as a new instruction from the user.
Check the minimum output, not just the slippage label
Slippage tolerance sets the permitted reduction from the quoted output. The minimum output is the concrete bound the transaction needs to enforce.
Those values must agree. A response cannot advertise a modest slippage tolerance while supplying a much lower minimum output. Rockpile checks the relationship between the quoted output, the permitted slippage, and the minimum amount.
For example, a quote for 1,000 output units with 0.5% allowed slippage implies a minimum of 995 units. A response specifying 900 units would permit a much larger reduction than the user authorized.
This protects the terms of the requested trade. It does not establish that the quoted price is a good one. Price impact, market conditions, and the value of the token remain separate parts of the decision. Missing price-impact information must also remain distinguishable from a measured zero.
Decode what the transaction will ask the program to do
The native validator checks supported Jupiter instruction encodings against the authorized swap. Its checks include input amounts, output terms, token mints, destination accounts, slippage, and fee fields. Validation happens inside the native wallet boundary, so the interface cannot establish compliance simply by labeling a transaction as a swap.
For example, changing the destination token account must fail validation even if the provider leaves the quote’s text unchanged. Increasing a fee field must not be accepted merely because the input token and amount still match.
The tests deliberately substitute accounts, change amounts and fees, and append unexpected bytes to otherwise valid instructions. Both supported direct and shared-account route formats must reject these changes before signing.
Requested trade
↓
Validate returned quote
↓
Validate transaction instructions
↓
Simulate through configured RPC
↓
Revalidate modified transaction
↓
Review and authorize signing
This is more specific than recognizing the Jupiter program address. Recognizing a program identifies which on-chain code will run; decoding and checking its instructions establishes what this request asks that code to do.
Simulate through a separate request
Rockpile’s Jupiter signing path requires successful simulation through its configured read RPC. It does not accept the swap provider’s description of success as a substitute for that check.
Simulation evaluates the transaction against the state observed by that RPC. An execution error blocks this path before signing. The RPC still represents an external dependency, and state may change between simulation and execution.
Rockpile uses the simulation result to adjust the transaction’s compute budget, then runs native validation again. This second check matters: a transaction validated before modification is not automatically validated afterward.
A successful simulation therefore complements instruction validation. It does not replace the comparison with the user’s intent, guarantee a final output, or certify a token or protocol as safe.
Keep the result separate from the quote
After signing, a quote is still an estimate of the proposed trade. It must not become a historical record of tokens received simply because submission was attempted.
A confirmed transaction with an unverified received amount stays recorded with an unknown output. Rockpile does not fill that gap with the quoted amount. It also retains the signed transaction for recovery after interrupted delivery. Rebuilding and signing a replacement automatically could turn one intended swap into two.
These controls address a chain of trust: the provider’s response must match the request, the instructions must match the approved terms, and the recorded result must reflect observed execution. They do not remove the trading risks of the asset or venue.
For the approval mechanism shared with other transactions, read from review to signature. For a submitted trade whose result is unclear, see unknown transaction status.