Fullport

Provably Fair

Every coinflip and rock-paper-scissors round on Degenhub is verifiable end-to-end. The outcome is bound to a future Solana finalized slot at the moment your opponent locks in, so no one — not even the operator — can influence the result.

How a round is committed

  1. The server generates a 32-byte random serverSeed and publishes only its SHA-256 hash before the round starts. The seed is hidden until reveal.
  2. The challenger's join transaction confirms on Solana, fixing a targetSlot = currentFinalizedSlot + 5.
  3. Once targetSlot is finalized, its blockhash becomes the publicSeed — a public, immutable, untouchable input.
  4. Outcome is derived from SHA-512(serverSeed | publicSeed | gameId); first 16 hex chars taken as a 64-bit BigInt, modulo the ticket range. Coinflip uses ticket < 500,000 → HEADS.
  5. At reveal, the server publishes serverSeed and the blockhash it used. Anyone can re-run the SHA-512 themselves with the data below.

House fee

The house takes 5% of the WINNINGS — that is, 5% of the amount the winner gains. Both players wager X. The winner takes the pot (2X) minus a 5% fee on their gain (5% of X). Winner receives 1.95X; net gain is 0.95X.

Example: Both players wager 0.01 SOL. Pot = 0.02 SOL. Fee = 0.0005 SOL (5% of 0.01). Winner receives 0.0195 SOL. Net win is +0.0095 SOL.

Reference snippet

Use this Node script to verify any resolved round. The result must match resultHash and ticket published on the room.

import crypto from 'crypto';

function compute(serverSeed, publicSeed, gameId) {
  const hash = crypto.createHash('sha512')
    .update(`${serverSeed}-${publicSeed}-${gameId}`)
    .digest('hex');
  const uint = BigInt('0x' + hash.slice(0, 16));
  const ticket = Number(uint % BigInt(999_999 + 1));
  return { hash, ticket, side: ticket < 500_000 ? 'HEADS' : 'TAILS' };
}

Verify a round in-browser

Paste the serverSeed, publicSeed, and gameIdfrom any revealed room and we'll re-compute the hash + ticket using the same algorithm. If it matches what's shown on the room card, the outcome is verified.

Running live on Solana mainnet. Every round settles in real SOL using the exact provably-fair algorithm described above.