Program

Program overview

What the Geode program does, where its address comes from, what it is built with, who signs each instruction a client submits and what each transaction costs.

The Geode program holds a shielded SOL pool on Solana. A holder's wallet moves SOL into the pool vault with shield and receives two note commitments in a depth-26 Poseidon tree. Every later spend consumes two input notes, one of which may be a zero-amount dummy, and creates two, proven by a Groth16 proof the program verifies on chain: pay moves a storage price into the storage vault and a fee into the fee vault against a receipt for one sealed file, unshield moves SOL out to a recipient, and both repay the relayer the network refund (relayer_refund). Each spend writes two nullifier accounts, so a note is spent once, and emits an event the relayer and the browser read to rebuild the tree. See Notes and the pool and The proof that pays for the design.

  1. Seal
  2. Quote
  3. Prove
  4. Pay
  5. Store
  6. Open
Every file, from your device to Irys. Dashed: what the chain sees. Solid: what stays with you.

Program id

Text
CN61Ua4hgvpJwvWRbCakeN3CZ3GZdjaRurAkzi4H37Xq

The program has this id on every cluster. Code reads it from GET /config as programId and derives every account on Accounts from it.

Build and dependencies

PartVersion
Anchor (anchor-lang, feature event-cpi)=0.31.1, also pinned as anchor_version in Anchor.toml
groth16-solana=0.2.0
solana-poseidon=2.2.4
Crategeode 0.1.0, edition 2021
CircuitCircom 2.2.3, circomlib 2.0.5, snarkjs 0.7.6

The IDL ships in the chain package as GEODE_IDL, which Events decodes with. The SBF ELF is 462,512 bytes.

Verifier and hashing

Proofs are verified by groth16-solana over the alt_bn128 syscalls, against a verifying key compiled into the program from circuits/build/verifying_key.rs. The key has 8 IC points for 7 public inputs. Its SHA-256 (of the exact verification_key.json bytes) is stored in Config.verifying_key_hash.

Every Poseidon hash in the program (tree nodes, receipt, binding hashes) runs through the Poseidon syscall with Parameters::Bn254X5 and big-endian inputs, the same parameters as circomlib. A unit test checks Poseidon(1, 2) against the circomlib reference vector. The memo digest is SHA-256 through hashv.

The circuit, its signals and the setup behind the verifying key are on Circuit and setup.

Instructions

InstructionSignerWhat it does
shieldHolder's walletMoves SOL into the pool vault, inserts two commitments
payConfigured relayerSpends two input notes, one of which may be a zero-amount dummy, to pay a storage price and fee against a receipt and the network refund to the relayer
unshieldConfigured relayerSpends two input notes, one of which may be a zero-amount dummy, to send SOL to a recipient and the network refund to the relayer

Signers

  • The holder's wallet signs shield only. It is the depositor account, pays the deposit and the rent of the two nullifier accounts, and its address is bound into the proof.
  • The relayer is the sole signer and fee payer of pay and unshield. The program requires the signing relayer to be in Config.relayers and binds its address into the proof, so a proof made for one relayer verifies for no other. The chain package's buildUnsignedV0 refuses any message with more than one required signature or a fee payer other than the given payer. The relayer pays the rent of the two nullifier accounts and the transaction fee, and the same instruction repays it relayer_refund from the pool vault: twice the rent-exempt minimum of an 8-byte account, read from the Rent sysvar, plus 5,000 lamports. The proof binds relayer_refund and spends it, so it comes out of the holder's notes. See The network refund.

Compute and size

Measured on 2026-11-16. Each transaction is v0 over the prepared lookup table; each spend carries two full 80-byte memos. Units consumed are from the confirmed transaction's metadata and match simulation. The limit is what buildUnsignedV0 sets from a simulation: ceil((units + w) * 1.2) + 10,000, capped at 1,400,000, where w is 4,000 for a wallet-signed transaction (shield) and 0 otherwise.

InstructionCU consumedCU limitSerialized bytes
shield218,539277,047936
pay226,238281,486989
unshield215,125268,1501,001

shield leaves 296 bytes of the 1,232-byte packet, above the 128 bytes buildUnsignedV0 reserves for wallet-signed transactions. pay and unshield carry one signature, the relayer's.

Lookup table

Every Geode transaction is a v0 message over one address lookup table holding the fixed accounts: the config, pool, pool_vault, storage, fee and __event_authority PDAs, the program data address, the System Program and the program id. With those nine addresses loaded from the table, a spend carrying a 256-byte proof, seven 32-byte public values and two 80-byte memos fits one packet. The per-spend accounts (the two nullifier PDAs, the signer and, for unshield, the recipient) stay in the message. buildUnsignedV0 waits until the table is active before compiling.