← Back to lotto

Provably-fair proof

This page reproduces the winner computation from public inputs. You can recompute every step in your browser's DevTools — don't trust our math, verify it.

1. Pre-commit (server_seed_hash)

Published when the draw went live (2026-05-26T06:53:58.935Z).

ea927e2f514d3ed1159387acd6a0798069cbccfb3ef485dedfb6a8fc2b72681d

2. Reveal (server_seed)

Revealed after draw (2026-05-29T06:54:02.644Z).

0475648b607f16b2e069d43fff469b31f4508c1413d7079119f30618e93da436

Hash check: ✓ sha256(server_seed) === published hash

3. Client seed inputs (all sold eggs)

#WalletWinner?
2BGDKeT...iukC
3BGDKeT...iukC
6BGDKeT...iukC🎉

4. Derived client_seed

client_seed = sha256(sorted by entry_number, joined as "N:wallet" with '|')

30ed598d94c80b995e867249ca380e3495d6ca21b095550e2cb808e5d74f3cab

5. External entropy (Bitcoin block)

Mixed into the HMAC input so the draw depends on a value the operator could not have known when the server seed was committed ( 2026-05-26T06:53:58.935Z). Any Bitcoin block mined after the commit works — we take the tip at draw time.

sourcemempool.spaceheight951,530hash00000000000000000000c37acc3f51e0d8e1f4ddb78576dec29e2a0d3bf5ed3fblock time2026-05-29T06:41:56.000Z

Cross-check on mempool.space or blockstream.info.

6. Winner computation

HMAC-SHA256(server_seed, "client_seed:lotto_id:source:height:hash"), first 16 hex chars, mod sold_count (3).

hmac = 2cfe1e275d9399eb777135c8e0940ff978d4d99bf439952f89fbbec2cd0987a7

Computed index: 2 → winning egg: #6

7. Independent verification

Show JS snippet (paste into DevTools)
const seed = "0475648b607f16b2e069d43fff469b31f4508c1413d7079119f30618e93da436";
const hashStr = "ea927e2f514d3ed1159387acd6a0798069cbccfb3ef485dedfb6a8fc2b72681d";
const clientSeed = "30ed598d94c80b995e867249ca380e3495d6ca21b095550e2cb808e5d74f3cab";
const lottoId = "18e52a5d-1cd6-4faf-8cab-e6107e73d7f6";
const sold = 3;
const entropy = "mempool.space:951530:00000000000000000000c37acc3f51e0d8e1f4ddb78576dec29e2a0d3bf5ed3f";

async function run() {
  const enc = new TextEncoder();
  const seedBytes = enc.encode(seed);
  const hashed = await crypto.subtle.digest("SHA-256", seedBytes);
  const recomputed = [...new Uint8Array(hashed)]
    .map((b) => b.toString(16).padStart(2, "0")).join("");
  console.log("hashOk:", recomputed === hashStr);

  const key = await crypto.subtle.importKey(
    "raw", seedBytes, { name: "HMAC", hash: "SHA-256" }, false, ["sign"]
  );
  const message = entropy
    ? clientSeed + ":" + lottoId + ":" + entropy
    : clientSeed + ":" + lottoId;
  const sig = await crypto.subtle.sign("HMAC", key, enc.encode(message));
  const hex = [...new Uint8Array(sig)]
    .map((b) => b.toString(16).padStart(2, "0")).join("");
  const idx = Number(BigInt("0x" + hex.slice(0, 16)) % BigInt(sold));
  console.log("hmac:", hex);
  console.log("winnerIndex:", idx);
}
run();