A two-party escrow with arbitrator: finalize() releases funds to the seller, refund() returns them to the buyer. A solc 0.4.10 build of the same escrow logic.
Key Facts
Description
Deployed March 31, 2017 by Vitalik Buterin (0x1db3439a22ee7c4d034e9b26437d3960b5af0517). A two-party escrow with an arbitrator. The buyer deploys, naming a seller and an arbitrator. finalize() (callable by buyer or arbitrator) releases the contract balance to the seller; refund() (callable by seller or arbitrator) returns it to the buyer. Functionally identical to the verified Escrow at 0x139a5a0812bfc9b3d9234c9fd2d8c5d790f71e18, but built with storage order buyer/seller/arbitrator and solc 0.4.10 (optimizer off), giving a larger runtime with a swarm metadata trailer. The executable runtime reproduces byte-for-byte from the reconstructed source; only the trailing swarm metadata hash differs. runtime sha256 4fa8ca20d18ccb13e594b6329f047d32c52e33065e36db8ba4d8d37e4f2256df.
Source Verified
Executable runtime reproduces byte-for-byte from the reconstructed source with solc 0.4.10, optimizer off; only the swarm metadata hash differs. runtime sha256 4fa8ca20d18ccb13e594b6329f047d32c52e33065e36db8ba4d8d37e4f2256df.
Spurious Dragon Era
Continued DoS protection. State trie clearing.
Bytecode Overview
Verified Source Available
This contract has verified source code.
View Verification ProofShow source code (Solidity)
// Verified by EthereumHistory (ethereumhistory.com)
contract Escrow {
address buyer;
address seller;
address arbitrator;
function Escrow(address _seller, address _arbitrator) {
seller = _seller;
arbitrator = _arbitrator;
buyer = msg.sender;
}
function finalize() {
if (msg.sender == buyer || msg.sender == arbitrator)
seller.send(this.balance);
}
function refund() {
if (msg.sender == seller || msg.sender == arbitrator)
buyer.send(this.balance);
}
}External Links
Related contracts
SerpentGamble
Same deployerProvably-fair betting game where players choose their own odds. The owner settles bets with a commit-reveal random seed. Includes a 2-day emergency refund.
0x034df8...200e2fSeptember 20, 2015SerpentGamble
Same deployerSibling of 0x034dF870 (SerpentGamble). Provably-fair Serpent betting game; players choose their own odds, owner settles via commit-reveal seed, 2-day refund.
0x9ca7e9...fa8bb4September 21, 2015SerpentGamble
Same deployerSibling of 0x034dF870 (SerpentGamble). Provably-fair Serpent betting game; players choose their own odds, owner settles via commit-reveal seed, 2-day refund.
0x75649a...176028September 21, 2015SerpentGamble
Same deployerIntermediate build of serpent_gamble, a provably-fair betting dapp (Bet/Win/Loss/NewSeed), related to verified sibling 0x59375871. Source not yet reconstructed.
0xe1a99f...0d2457September 21, 2015SerpentGamble
Same deployerIntermediate build of serpent_gamble, a provably-fair betting dapp (Bet/Win/Loss/NewSeed), related to verified sibling 0x59375871. Source not yet reconstructed.
0xdc00a9...15861fSeptember 21, 2015SerpentGamble
Same deployerIntermediate build of serpent_gamble, a provably-fair betting dapp (Bet/Win/Loss/NewSeed), related to verified sibling 0x59375871. Source not yet reconstructed.
0xd0ed09...300b48September 21, 2015