IMPORTANT: $LOOTX token is NOT LIVE. Any token currently trading under the LootX name is a scam and is NOT affiliated with us. Always verify announcements through our official channels.
Verified Protocol Code

On-Chain Audit Details

Explore verified entrypoints, security checks, state diagrams, and rules of the LootX Solana smart contracts.

LootX Event Room Program (Verified)
Verified Oracle PartnerLIVE

Powered by Switchboard Randomness

LootX integrates Switchboard's TEE-secured oracle network for verifiable, tamper-proof randomness on draw execution. No validator can predict or manipulate the winner — not even Switchboard itself.

TEE
Secured
VRF
On-Chain
Proof
$5B+
Secured
Tamper-proof draw executionCryptographic VRF proof on-chainImmune to validator manipulationCommit → Reveal patternSOL, BTC, Memecoins & USDC rooms securedswitchboard.xyz

Switchboard VRF — Draw Execution Flow

Commit-reveal pattern ensuring no party can predict or manipulate the winner.

Step 1: Commit

Draw Initiated

Admin triggers commit_draw. SOL / USDC vault is locked. Randomness account is committed to a specific Solana slothash. No outcome is known yet.

Vault locked at commit time
Step 2: Oracle Generate

TEE Randomness

Switchboard oracle nodes generate a verifiable random value inside a Trusted Execution Environment. A cryptographic VRF proof is attached — tamper-proof by design.

~1–2 slots (~800ms)
Step 3: Reveal & Settle

Winner Settled

Admin calls settle_draw. Program reads vrf_result % max_tickets, verifies winner PDA on-chain, and distributes SOL / USDC / physical prizes.

VRF proof verified on-chain

Why commit-reveal? SOL or USDC is locked at commit time — before the random value exists. This prevents selective revelation attacks where a losing party could refuse to reveal an unfavorable result.

A+ SecurityAnchor (Solana)

LootX Event Contract

Handles the logic for initializing rooms, escrowing ticket entry fees (in native SOL or USDC), buying tickets as PDAs, drawing verifiable winners on-chain via Switchboard VRF, and distributing the designated Room Prize (SOL, cbBTC, Memecoins or tokenized RWAs like Pokémon cards and luxury watches) to the winner, and platform fees to treasury and holder reward distribution.

1254 Lines of Code 18 Active Asserts Checked Arithmetic Enabled
Program ID
7v1ZiSMA...W8X3Pnzb
Solscan Verify
Audit Grade
A+ Security

Solana Anchor program compiles using strict type boundaries. All state variables utilize signed validation paths preventing parameter injection.

Checked Arithmetic overflows (checked_add)
Strict PDA Owner Validation check

On-Chain Data Flow Diagram

Understanding the PDA accounts tree and state changes in LootX.

Step 1: Init

PlatformConfig PDA

Admin defines the global state: deployer address and destination Treasury Wallet.

Step 2: Initialize Room

RaffleRoom PDA

Admin spawns a room using numerical `room_id` seeds. Creates vault PDA to collect SOL/USDC entry fees.

Step 3: Buy Entries

Entry PDAs

Users pay SOL or USDC to the room vault. Each entry generates a sequential PDA saving the buyer's key.

Step 4: Draw & Clear

CPI Distribution

Random seed resolves winner index. Winner gets the designated Room Prize (SOL, cbBTC, Memecoins, or tokenized RWAs), Treasury & Holders receive platform fees, vault is emptied.

Core Program Security Mechanisms

Key defensive validation patterns built directly into the on-chain Anchor code.

PDA Seeds Validation

Every ticket and room account is locked behind a strict PDA derivation. For example, tickets use `['ticket', room_key, ticket_index]`, which prevents users from fake ticketing or re-submitting keys.

Switchboard VRF Randomness

Winner draws are secured by Switchboard's TEE-secured oracle network using Verifiable Random Functions (VRF). Each draw result ships with a cryptographic proof verifiable on-chain, making manipulation by validators or any third party mathematically impossible.

Multi-Currency & Asset Escrow

Supports native SOL and SPL USDC ticket sales. Escrows entry fees safely, mapping room payouts directly to target assets including SOL, cbBTC, Memecoins (ANSEM, CATE, FAPCOIN, MEMESTOCK, CASHCAT) and tokenized RWAs.

Deterministic Winner PDA Proof

During distribution, the program recalculates the ticket PDA address of the winner index on-chain and requires a match, verifying that the winner account was a real participant.

Platform Pause Mechanism

An admin global configuration check on every ticket purchase allows pausing ticket sales globally in case of unexpected network situations.

On-Chain Instructions / Entrypoint Inspector

Click on any function to view parameters, required accounts, logic description, and security validations.