Back to Home

Escrow

Part of The Vitalik Collection
0x54c1c951e578...07d9fa345629
Spurious DragonSource VerifiedEdit this contract
Deployed May 17, 2017 (9 years ago)Block 3,720,243

An optimized two-party escrow whose access guard uses a buggy || instead of &&, so both functions always throw and the contract is bricked.

Spurious Dragon EraVerified Source
Key Facts
Deployer
Vitalik Buterin(0x1db343...fa6ee6)
Deployment Block
3,720,243
Deployment Date
May 17, 2017, 06:14 AM
Code Size
355.0 B
Transactions by Year
20172

Description

Deployed May 17, 2017 by Vitalik Buterin (0x1db3439a22ee7c4d034e9b26437d3960b5af0517). An optimized build of a two-party escrow (buyer, seller, arbitrator): finalize() is meant to pay the seller and refund() the buyer. The access guard is written with a buggy || instead of &&: if (msg.sender != buyer || msg.sender != arbitrator) throw;. Because no caller can equal both buyer and arbitrator at once, that condition is always true, so both functions always throw and the contract is effectively bricked: any funds sent can never be released. This exact operator choice reproduces the target's short-circuit codegen; the && form compiles 2 bytes longer. Compiled with solc 0.4.11, optimizer on. The executable runtime reproduces byte-for-byte; only the trailing swarm metadata hash differs. runtime sha256 b1e345aaecdee9afa5ddc48f57dbc700faafcbbf16250c0a35791825bfd65442.

Source Verified

SolidityNear-exact bytecode match (swarm hash differs)
Compiler: v0.4.11

Executable runtime reproduces byte-for-byte from the reconstructed source with solc 0.4.11, optimizer on; only the swarm metadata hash differs. The buggy || guard (always true) is required to match. runtime sha256 b1e345aaecdee9afa5ddc48f57dbc700faafcbbf16250c0a35791825bfd65442.

Bytecode Overview

Opcodes355
Unique Opcodes88
Jump Instructions22
Storage Operations11

External Links

Related contracts