Back to Home

Roulette

Game
0x5fe5b7546d16...de1fc825a4fd
FrontierSource Verified
Deployed August 10, 2015 (10 years ago)Block 66,126

An early Ethereum roulette contract from August 2015, notable for a critical randomness vulnerability: its 'private' seed is hardcoded to 1 in the constructor.

Key Facts

Deployment Block
66,126
Deployment Date
Aug 10, 2015, 11:26 PM
Code Size
2.3 KB
Transactions by Year
2015446
20174
20182
20191
20201
20212
20222
20232
202514
202610

Description

Roulette is one of the earliest gambling contracts on Ethereum mainnet, deployed at block 66,126 on August 10, 2015 — 11 days after genesis. Created by address 0xa14cf6cec1c6aae4b608458f6e14692863a937aa, it implements a roulette-style betting game where players wager between 1 and 10 ETH on a number.

The contract maintains a Casino struct holding the house address, balance, and betting limits. Players call betOnNumber(uint number) to place a bet; a random number is generated using an internal seed and compared to determine the outcome. Winnings are sent directly to the player's address.

The contract's source code includes a comment claiming that the privSeed used for random number generation is difficult to guess because it is "nowhere visible." However, privSeed is initialized to 1 in the constructor — a hardcoded, publicly known value. Anyone reading the contract source can predict every outcome. This is an early example of the "bad randomness" vulnerability class that would later be systematically exploited across many Ethereum gambling contracts.

The minimum bet is 1 ETH and the maximum is 10 ETH.

Heuristic Analysis

The following characteristics were detected through bytecode analysis and may not be accurate.

Detected Type: Game
Contains SELFDESTRUCT opcode

Frontier Era

The initial release of Ethereum. A bare-bones implementation for technical users.

Block span: 01,149,999
July 30, 2015March 14, 2016

Bytecode Overview

Opcodes2,375
Unique Opcodes159
Jump Instructions138
Storage Operations59

Verified Source Available

This contract has verified source code on Etherscan.

View Source Code

External Links