Skip to content

cartoonitunes/honestdice1eth-verification

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

Verification Proof: HonestDice (1 ETH variant)

Contract: 0xd79b4c6791784184e2755b2fc1659eaab0f80456 Block: 75,008 (August 12, 2015) Deployer: 0x87c5b5874a18b4306df8a752a6c8cc3e82dafc19 Creation tx: 0xe3d8ba1c62818c7d259e1b827303215d4fa39fbcef8664524634e165dbff1e29 ETH locked: 83.94 ETH ($180K+)

What is this?

A commit-reveal dice game deployed on day 13 of Ethereum mainnet by the same developer who deployed the 10 ETH variant (HonestDice at 0xc4c51de1...). This is the 1 ETH minimum bet version, bankrolled with 1,000 ETH on deployment day.

The contract has 601 transactions and was still being played in March 2026, making it one of the longest-running smart contracts in Ethereum history. 83.94 ETH remains locked in the contract.

How it works

  1. Player calls roll(chance, secretHash) with ETH and a probability (1-255)
  2. Server calls serverSeed(player, seed) with a random seed
  3. Player calls claim(secret) to reveal and collect winnings
  4. If server doesn't respond within 20 blocks, player calls claimTimeout() for a refund

House edge: 1% (winnings = value * 99/100 * 256/chance)

Source Code

See HonestDice.sol.

Compiler

Language: Solidity Version: soljson v0.1.1+commit.6ff4cd6 Optimizer: ON (200 runs)

Verification

curl -o soljson-v0.1.1.js https://binaries.soliditylang.org/bin/soljson-v0.1.1+commit.6ff4cd6.js
node verify.js

Key Findings

  • Same deployer as HonestDice 10 ETH variant (0xc4c51de1...), deployed 191 blocks later on the same day
  • 1 ETH minimum vs 10 ETH in the other variant, no setMinimumBet() function
  • 99% payout (1% house edge) vs 98% in the 10 ETH variant
  • Broken withdrawal lock: lockBetsForWithdraw() and unlockBets() declare local variables that shadow the state variable betsLocked, so the lock never actually engages
  • Optimizer dispatch pattern: soljson v0.1.1 with optimizer ON generates 60e060020a (EXP-based) selector extraction instead of 7c01...04 (PUSH29-based)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors