ETH Price: $3,352.03 (-0.69%)

Contract

0x91f273b7A28F5169FD7B7995A54B767cA797BC63
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Deposit155426572022-09-16 0:31:59799 days ago1663288319IN
0x91f273b7...cA797BC63
0 ETH0.0035590553
Deposit153076752022-08-09 11:15:42836 days ago1660043742IN
0x91f273b7...cA797BC63
0 ETH0.0023070237
Deposit150601532022-07-02 1:46:09875 days ago1656726369IN
0x91f273b7...cA797BC63
0 ETH0.0029397237
Deposit142933202022-02-28 7:39:28998 days ago1646033968IN
0x91f273b7...cA797BC63
0 ETH0.0028875343
Deposit140916002022-01-28 2:48:581030 days ago1643338138IN
0x91f273b7...cA797BC63
0 ETH0.014063177
Withdraw For140555762022-01-22 13:01:231035 days ago1642856483IN
0x91f273b7...cA797BC63
0 ETH0.0166619168
Update State136904972021-11-26 15:12:191092 days ago1637939539IN
0x91f273b7...cA797BC63
0 ETH0.00569129126
Deposit135652412021-11-06 21:04:001112 days ago1636232640IN
0x91f273b7...cA797BC63
0 ETH0.01040821131
Deposit135638932021-11-06 15:56:291112 days ago1636214189IN
0x91f273b7...cA797BC63
0 ETH0.01066219171
Deposit132545362021-09-19 6:31:131161 days ago1632033073IN
0x91f273b7...cA797BC63
0 ETH0.00698342112
Deposit132543492021-09-19 5:44:361161 days ago1632030276IN
0x91f273b7...cA797BC63
0 ETH0.00889862112
Deposit131709322021-09-06 7:49:051173 days ago1630914545IN
0x91f273b7...cA797BC63
0 ETH0.02335888294
Deposit130197332021-08-13 23:13:071197 days ago1628896387IN
0x91f273b7...cA797BC63
0 ETH0.01175889148
Withdraw For127432062021-07-01 17:43:311240 days ago1625161411IN
0x91f273b7...cA797BC63
0 ETH0.0053720446.2
Update State127431812021-07-01 17:38:051240 days ago1625161085IN
0x91f273b7...cA797BC63
0 ETH0.0027592146
Deposit127420592021-07-01 13:29:131240 days ago1625146153IN
0x91f273b7...cA797BC63
0 ETH0.0017731634
Deposit125549692021-06-02 12:02:511269 days ago1622635371IN
0x91f273b7...cA797BC63
0 ETH0.0019817738
Deposit123852542021-05-07 5:15:211296 days ago1620364521IN
0x91f273b7...cA797BC63
0 ETH0.0054016578
Deposit122432582021-04-15 7:15:491318 days ago1618470949IN
0x91f273b7...cA797BC63
0 ETH0.00792972164
Deposit119932022021-03-07 19:28:501356 days ago1615145330IN
0x91f273b7...cA797BC63
0 ETH0.0103536450
Deposit119820142021-03-06 2:05:001358 days ago1614996300IN
0x91f273b7...cA797BC63
0 ETH0.01203688190
Deposit119241162021-02-25 4:19:141367 days ago1614226754IN
0x91f273b7...cA797BC63
0 ETH0.02900972458
Deposit118156562021-02-08 11:50:521383 days ago1612785052IN
0x91f273b7...cA797BC63
0 ETH0.01150777238
Deposit116346122021-01-11 16:06:371411 days ago1610381197IN
0x91f273b7...cA797BC63
0 ETH0.05600316884
Withdraw Bankrol...116318222021-01-11 6:00:051412 days ago1610344805IN
0x91f273b7...cA797BC63
0 ETH0.01029250
View all transactions

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
EdgelessCasino

Compiler Version
v0.4.21+commit.dfe3193c

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion

Contract Source Code (Solidity)

/**
 *Submitted for verification at Etherscan.io on 2018-05-09
*/

/**
 * The edgeless casino contract v2 holds the players's funds and provides state channel functionality.
 * The casino has at no time control over the players's funds.
 * State channels can be updated and closed from both parties: the player and the casino.
 * author: Julia Altenried
 **/

pragma solidity ^0.4.21;

contract SafeMath {

	function safeSub(uint a, uint b) pure internal returns(uint) {
		assert(b <= a);
		return a - b;
	}
	
	function safeSub(int a, int b) pure internal returns(int) {
		if(b < 0) assert(a - b > a);
		else assert(a - b <= a);
		return a - b;
	}

	function safeAdd(uint a, uint b) pure internal returns(uint) {
		uint c = a + b;
		assert(c >= a && c >= b);
		return c;
	}

	function safeMul(uint a, uint b) pure internal returns (uint) {
		uint c = a * b;
		assert(a == 0 || c / a == b);
		return c;
	}
}


contract Token {
	function transferFrom(address sender, address receiver, uint amount) public returns(bool success);

	function transfer(address receiver, uint amount) public returns(bool success);

	function balanceOf(address holder) public view returns(uint);
}

contract Owned {
  address public owner;
  modifier onlyOwner {
    require(msg.sender == owner);
    _;
  }

  function Owned() public{
    owner = msg.sender;
  }

}

/** owner should be able to close the contract is nobody has been using it for at least 30 days */
contract Mortal is Owned {
	/** contract can be closed by the owner anytime after this timestamp if non-zero */
	uint public closeAt;
	/** the edgeless token contract */
	Token edg;
	
	function Mortal(address tokenContract) internal{
		edg = Token(tokenContract);
	}
	/**
	* lets the owner close the contract if there are no player funds on it or if nobody has been using it for at least 30 days
	*/
  function closeContract(uint playerBalance) internal{
		if(closeAt == 0) closeAt = now + 30 days;
		if(closeAt < now || playerBalance == 0){
			edg.transfer(owner, edg.balanceOf(address(this)));
			selfdestruct(owner);
		} 
  }

	/**
	* in case close has been called accidentally.
	**/
	function open() onlyOwner public{
		closeAt = 0;
	}

	/**
	* make sure the contract is not in process of being closed.
	**/
	modifier isAlive {
		require(closeAt == 0);
		_;
	}

	/**
	* delays the time of closing.
	**/
	modifier keepAlive {
		if(closeAt > 0) closeAt = now + 30 days;
		_;
	}
}

contract RequiringAuthorization is Mortal {
	/** indicates if an address is authorized to act in the casino's name  */
	mapping(address => bool) public authorized;
	/** tells if an address is allowed to receive funds from the bankroll **/
	mapping(address => bool) public allowedReceiver;

	modifier onlyAuthorized {
		require(authorized[msg.sender]);
		_;
	}

	/**
	 * Constructor. Authorize the owner.
	 * */
	function RequiringAuthorization() internal {
		authorized[msg.sender] = true;
		allowedReceiver[msg.sender] = true;
	}

	/**
	 * authorize a address to call game functions and set configs.
	 * @param addr the address to be authorized
	 **/
	function authorize(address addr) public onlyOwner {
		authorized[addr] = true;
	}

	/**
	 * deauthorize a address to call game functions and set configs.
	 * @param addr the address to be deauthorized
	 **/
	function deauthorize(address addr) public onlyOwner {
		authorized[addr] = false;
	}

	/**
	 * allow authorized wallets to withdraw funds from the bonkroll to this address
	 * @param receiver the receiver's address
	 * */
	function allowReceiver(address receiver) public onlyOwner {
		allowedReceiver[receiver] = true;
	}

	/**
	 * disallow authorized wallets to withdraw funds from the bonkroll to this address
	 * @param receiver the receiver's address
	 * */
	function disallowReceiver(address receiver) public onlyOwner {
		allowedReceiver[receiver] = false;
	}

	/**
	 * changes the owner of the contract. revokes authorization of the old owner and authorizes the new one.
	 * @param newOwner the address of the new owner
	 * */
	function changeOwner(address newOwner) public onlyOwner {
		deauthorize(owner);
		authorize(newOwner);
		disallowReceiver(owner);
		allowReceiver(newOwner);
		owner = newOwner;
	}
}

contract ChargingGas is RequiringAuthorization, SafeMath {
	/** 1 EDG has 5 decimals **/
	uint public constant oneEDG = 100000;
	/** the price per kgas and GWei in tokens (with decimals) */
	uint public gasPrice;
	/** the amount of gas used per transaction in kGas */
	mapping(bytes4 => uint) public gasPerTx;
	/** the number of tokens (5 decimals) payed by the users to cover the gas cost */
	uint public gasPayback;
	
	function ChargingGas(uint kGasPrice) internal{
		//deposit, withdrawFor, updateChannel, updateBatch, transferToNewContract
	    bytes4[5] memory signatures = [bytes4(0x3edd1128),0x9607610a, 0xde48ff52, 0xc97b6d1f, 0x6bf06fde];
	    //amount of gas consumed by the above methods in GWei
	    uint[5] memory gasUsage = [uint(146), 100, 65, 50, 85];
	    setGasUsage(signatures, gasUsage);
	    setGasPrice(kGasPrice);
	}
	/**
	 * sets the amount of gas consumed by methods with the given sigantures.
	 * only called from the edgeless casino constructor.
	 * @param signatures an array of method-signatures
	 *        gasNeeded  the amount of gas consumed by these methods
	 * */
	function setGasUsage(bytes4[5] signatures, uint[5] gasNeeded) public onlyOwner {
		require(signatures.length == gasNeeded.length);
		for (uint8 i = 0; i < signatures.length; i++)
			gasPerTx[signatures[i]] = gasNeeded[i];
	}

	/**
	 * updates the price per 1000 gas in EDG.
	 * @param price the new gas price (with decimals, max 0.1 EDG)
	 **/
	function setGasPrice(uint price) public onlyAuthorized {
		require(price < oneEDG/10);
		gasPrice = price;
	}

	/**
	 * returns the gas cost of the called function.
	 * */
	function getGasCost() internal view returns(uint) {
		return safeMul(safeMul(gasPerTx[msg.sig], gasPrice), tx.gasprice) / 1000000000;
	}

}


contract CasinoBank is ChargingGas {
	/** the total balance of all players with virtual decimals **/
	uint public playerBalance;
	/** the balance per player in edgeless tokens with virtual decimals */
	mapping(address => uint) public balanceOf;
	/** in case the user wants/needs to call the withdraw function from his own wallet, he first needs to request a withdrawal */
	mapping(address => uint) public withdrawAfter;
	/** a number to count withdrawal signatures to ensure each signature is different even if withdrawing the same amount to the same address */
	mapping(address => uint) public withdrawCount;
	/** the maximum amount of tokens the user is allowed to deposit (with decimals) */
	uint public maxDeposit;
	/** the maximum withdrawal of tokens the user is allowed to withdraw on one day (only enforced when the tx is not sent from an authorized wallet) **/
	uint public maxWithdrawal;
	/** waiting time for withdrawal if not requested via the server **/
	uint public waitingTime;
	/** the address of the predecessor **/
	address public predecessor;

	/** informs listeners how many tokens were deposited for a player */
	event Deposit(address _player, uint _numTokens, uint _gasCost);
	/** informs listeners how many tokens were withdrawn from the player to the receiver address */
	event Withdrawal(address _player, address _receiver, uint _numTokens, uint _gasCost);
	
	
	/**
	 * Constructor.
	 * @param depositLimit    the maximum deposit allowed
	 *		  predecessorAddr the address of the predecessing contract
	 * */
	function CasinoBank(uint depositLimit, address predecessorAddr) internal {
		maxDeposit = depositLimit * oneEDG;
		maxWithdrawal = maxDeposit;
		waitingTime = 24 hours;
		predecessor = predecessorAddr;
	}

	/**
	 * accepts deposits for an arbitrary address.
	 * retrieves tokens from the message sender and adds them to the balance of the specified address.
	 * edgeless tokens do not have any decimals, but are represented on this contract with decimals.
	 * @param receiver  address of the receiver
	 *        numTokens number of tokens to deposit (0 decimals)
	 *				 chargeGas indicates if the gas cost is subtracted from the user's edgeless token balance
	 **/
	function deposit(address receiver, uint numTokens, bool chargeGas) public isAlive {
		require(numTokens > 0);
		uint value = safeMul(numTokens, oneEDG);
		uint gasCost;
		if (chargeGas) {
			gasCost = getGasCost();
			value = safeSub(value, gasCost);
			gasPayback = safeAdd(gasPayback, gasCost);
		}
		uint newBalance = safeAdd(balanceOf[receiver], value);
		require(newBalance <= maxDeposit);
		assert(edg.transferFrom(msg.sender, address(this), numTokens));
		balanceOf[receiver] = newBalance;
		playerBalance = safeAdd(playerBalance, value);
		emit Deposit(receiver, numTokens, gasCost);
	}

	/**
	 * If the user wants/needs to withdraw his funds himself, he needs to request the withdrawal first.
	 * This method sets the earliest possible withdrawal date to 'waitingTime from now (default 90m, but up to 24h).
	 * Reason: The user should not be able to withdraw his funds, while the the last game methods have not yet been mined.
	 **/
	function requestWithdrawal() public {
		withdrawAfter[msg.sender] = now + waitingTime;
	}

	/**
	 * In case the user requested a withdrawal and changes his mind.
	 * Necessary to be able to continue playing.
	 **/
	function cancelWithdrawalRequest() public {
		withdrawAfter[msg.sender] = 0;
	}

	/**
	 * withdraws an amount from the user balance if the waiting time passed since the request.
	 * @param amount the amount of tokens to withdraw
	 **/
	function withdraw(uint amount) public keepAlive {
		require(amount <= maxWithdrawal);
		require(withdrawAfter[msg.sender] > 0 && now > withdrawAfter[msg.sender]);
		withdrawAfter[msg.sender] = 0;
		uint value = safeMul(amount, oneEDG);
		balanceOf[msg.sender] = safeSub(balanceOf[msg.sender], value);
		playerBalance = safeSub(playerBalance, value);
		assert(edg.transfer(msg.sender, amount));
		emit Withdrawal(msg.sender, msg.sender, amount, 0);
	}

	/**
	 * lets the owner withdraw from the bankroll
	 * @param receiver the receiver's address
	 *				numTokens the number of tokens to withdraw (0 decimals)
	 **/
	function withdrawBankroll(address receiver, uint numTokens) public onlyAuthorized {
		require(numTokens <= bankroll());
		require(allowedReceiver[receiver]);
		assert(edg.transfer(receiver, numTokens));
	}

	/**
	 * withdraw the gas payback to the owner
	 **/
	function withdrawGasPayback() public onlyAuthorized {
		uint payback = gasPayback / oneEDG;
		assert(payback > 0);
		gasPayback = safeSub(gasPayback, payback * oneEDG);
		assert(edg.transfer(owner, payback));
	}

	/**
	 * returns the current bankroll in tokens with 0 decimals
	 **/
	function bankroll() view public returns(uint) {
		return safeSub(edg.balanceOf(address(this)), safeAdd(playerBalance, gasPayback) / oneEDG);
	}


	/**
	 * updates the maximum deposit.
	 * @param newMax the new maximum deposit (0 decimals)
	 **/
	function setMaxDeposit(uint newMax) public onlyAuthorized {
		maxDeposit = newMax * oneEDG;
	}
	
	/**
	 * updates the maximum withdrawal.
	 * @param newMax the new maximum withdrawal (0 decimals)
	 **/
	function setMaxWithdrawal(uint newMax) public onlyAuthorized {
		maxWithdrawal = newMax * oneEDG;
	}

	/**
	 * sets the time the player has to wait for his funds to be unlocked before withdrawal (if not withdrawing with help of the casino server).
	 * the time may not be longer than 24 hours.
	 * @param newWaitingTime the new waiting time in seconds
	 * */
	function setWaitingTime(uint newWaitingTime) public onlyAuthorized  {
		require(newWaitingTime <= 24 hours);
		waitingTime = newWaitingTime;
	}

	/**
	 * transfers an amount from the contract balance to the owner's wallet.
	 * @param receiver the receiver address
	 *				 amount   the amount of tokens to withdraw (0 decimals)
	 *				 v,r,s 		the signature of the player
	 **/
	function withdrawFor(address receiver, uint amount, uint8 v, bytes32 r, bytes32 s) public onlyAuthorized keepAlive {
		address player = ecrecover(keccak256(receiver, amount, withdrawCount[receiver]), v, r, s);
		withdrawCount[receiver]++;
		uint gasCost = getGasCost();
		uint value = safeAdd(safeMul(amount, oneEDG), gasCost);
		gasPayback = safeAdd(gasPayback, gasCost);
		balanceOf[player] = safeSub(balanceOf[player], value);
		playerBalance = safeSub(playerBalance, value);
		assert(edg.transfer(receiver, amount));
		emit Withdrawal(player, receiver, amount, gasCost);
	}
	
	/**
	 * transfers the player's tokens directly to the new casino contract after an update.
	 * @param newCasino the address of the new casino contract
	 *		  v, r, s   the signature of the player
	 *		  chargeGas indicates if the gas cost is payed by the player.
	 * */
	function transferToNewContract(address newCasino, uint8 v, bytes32 r, bytes32 s, bool chargeGas) public onlyAuthorized keepAlive {
		address player = ecrecover(keccak256(address(this), newCasino), v, r, s);
		uint gasCost = 0;
		if(chargeGas) gasCost = getGasCost();
		uint value = safeSub(balanceOf[player], gasCost);
		require(value > oneEDG);
		//fractions of one EDG cannot be withdrawn 
		value /= oneEDG;
		playerBalance = safeSub(playerBalance, balanceOf[player]);
		balanceOf[player] = 0;
		assert(edg.transfer(newCasino, value));
		emit Withdrawal(player, newCasino, value, gasCost);
		CasinoBank cb = CasinoBank(newCasino);
		assert(cb.credit(player, value));
	}
	
	/**
	 * receive a player balance from the predecessor contract.
	 * @param player the address of the player to credit the value for
	 *				value  the number of tokens to credit (0 decimals)
	 * */
	function credit(address player, uint value) public returns(bool) {
		require(msg.sender == predecessor);
		uint valueWithDecimals = safeMul(value, oneEDG);
		balanceOf[player] = safeAdd(balanceOf[player], valueWithDecimals);
		playerBalance = safeAdd(playerBalance, valueWithDecimals);
		emit Deposit(player, value, 0);
		return true;
	}

	/**
	 * lets the owner close the contract if there are no player funds on it or if nobody has been using it for at least 30 days
	 * */
	function close() public onlyOwner {
		closeContract(playerBalance);
	}
}


contract EdgelessCasino is CasinoBank{
	/** the most recent known state of a state channel */
	mapping(address => State) public lastState;
	/** fired when the state is updated */
	event StateUpdate(address player, uint128 count, int128 winBalance, int difference, uint gasCost);
  /** fired if one of the parties chooses to log the seeds and results */
  event GameData(address player, bytes32[] serverSeeds, bytes32[] clientSeeds, int[] results, uint gasCost);
  
	struct State{
		uint128 count;
		int128 winBalance;
	}


  /**
  * creates a new edgeless casino contract.
  * @param predecessorAddress the address of the predecessing contract
	*				 tokenContract      the address of the Edgeless token contract
	* 			 depositLimit       the maximum deposit allowed
	* 			 kGasPrice				  the price per kGas in WEI
  **/
  function EdgelessCasino(address predecessorAddress, address tokenContract, uint depositLimit, uint kGasPrice) CasinoBank(depositLimit, predecessorAddress) Mortal(tokenContract) ChargingGas(kGasPrice) public{

  }
  
  /**
   * updates several state channels at once. can be called by authorized wallets only.
   * 1. determines the player address from the signature.
   * 2. verifies if the signed game-count is higher than the last known game-count of this channel.
   * 3. updates the balances accordingly. This means: It checks the already performed updates for this channel and computes
   *    the new balance difference to add or subtract from the player‘s balance.
   * @param winBalances array of the current wins or losses
   *				gameCounts  array of the numbers of signed game moves
   *				v,r,s       array of the players's signatures
   *        chargeGas   indicates if the gas costs should be subtracted from the players's balances
   * */
  function updateBatch(int128[] winBalances,  uint128[] gameCounts, uint8[] v, bytes32[] r, bytes32[] s, bool chargeGas) public onlyAuthorized{
    require(winBalances.length == gameCounts.length);
    require(winBalances.length == v.length);
    require(winBalances.length == r.length);
    require(winBalances.length == s.length);
    require(winBalances.length <= 50);
    address player;
    uint gasCost = 0;
    if(chargeGas) 
      gasCost = getGasCost();
    gasPayback = safeAdd(gasPayback, safeMul(gasCost, winBalances.length));
    for(uint8 i = 0; i < winBalances.length; i++){
      player = ecrecover(keccak256(winBalances[i], gameCounts[i]), v[i], r[i], s[i]);
      _updateState(player, winBalances[i], gameCounts[i], gasCost);
    }
  }

  /**
   * updates a state channel. can be called by both parties.
   * 1. verifies the signature.
   * 2. verifies if the signed game-count is higher than the last known game-count of this channel.
   * 3. updates the balances accordingly. This means: It checks the already performed updates for this channel and computes
   *    the new balance difference to add or subtract from the player‘s balance.
   * @param winBalance the current win or loss
   *				gameCount  the number of signed game moves
   *				v,r,s      the signature of either the casino or the player
   *        chargeGas  indicates if the gas costs should be subtracted from the player's balance
   * */
  function updateState(int128 winBalance,  uint128 gameCount, uint8 v, bytes32 r, bytes32 s, bool chargeGas) public{
  	address player = determinePlayer(winBalance, gameCount, v, r, s);
  	uint gasCost = 0;
  	if(player == msg.sender)//if the player closes the state channel himself, make sure the signer is a casino wallet
  		require(authorized[ecrecover(keccak256(player, winBalance, gameCount), v, r, s)]);
  	else if (chargeGas){//subtract the gas costs from the player balance only if the casino wallet is the sender
  		gasCost = getGasCost();
  		gasPayback = safeAdd(gasPayback, gasCost);
  	}
  	_updateState(player, winBalance, gameCount, gasCost);
  }
  
  /**
   * internal method to perform the actual state update.
   * @param player the player address
   *        winBalance the player's win balance
   *        gameCount  the player's game count
   * */
  function _updateState(address player, int128 winBalance,  uint128 gameCount, uint gasCost) internal {
    State storage last = lastState[player];
  	require(gameCount > last.count);
  	int difference = updatePlayerBalance(player, winBalance, last.winBalance, gasCost);
  	lastState[player] = State(gameCount, winBalance);
  	emit StateUpdate(player, gameCount, winBalance, difference, gasCost);
  }

  /**
   * determines if the msg.sender or the signer of the passed signature is the player. returns the player's address
   * @param winBalance the current winBalance, used to calculate the msg hash
   *				gameCount  the current gameCount, used to calculate the msg.hash
   *				v, r, s    the signature of the non-sending party
   * */
  function determinePlayer(int128 winBalance, uint128 gameCount, uint8 v, bytes32 r, bytes32 s) view internal returns(address){
  	if (authorized[msg.sender])//casino is the sender -> player is the signer
  		return ecrecover(keccak256(winBalance, gameCount), v, r, s);
  	else
  		return msg.sender;
  }

	/**
	 * computes the difference of the win balance relative to the last known state and adds it to the player's balance.
	 * in case the casino is the sender, the gas cost in EDG gets subtracted from the player's balance.
	 * @param player the address of the player
	 *				winBalance the current win-balance
	 *				lastWinBalance the win-balance of the last known state
	 *				gasCost the gas cost of the tx
	 * */
  function updatePlayerBalance(address player, int128 winBalance, int128 lastWinBalance, uint gasCost) internal returns(int difference){
  	difference = safeSub(winBalance, lastWinBalance);
  	int outstanding = safeSub(difference, int(gasCost));
  	uint outs;
  	if(outstanding < 0){
  		outs = uint256(outstanding * (-1));
  		playerBalance = safeSub(playerBalance, outs);
  		balanceOf[player] = safeSub(balanceOf[player], outs);
  	}
  	else{
  		outs = uint256(outstanding);
  		assert(bankroll() * oneEDG > outs);
  	  playerBalance = safeAdd(playerBalance, outs);
  	  balanceOf[player] = safeAdd(balanceOf[player], outs);
  	}
  }
  
  /**
   * logs some seeds and game results for players wishing to have their game history logged by the contract
   * @param serverSeeds array containing the server seeds
   *        clientSeeds array containing the client seeds
   *        results     array containing the results
   *        v, r, s     the signature of the non-sending party (to make sure the correct results are logged)
   * */
  function logGameData(bytes32[] serverSeeds, bytes32[] clientSeeds, int[] results, uint8 v, bytes32 r, bytes32 s) public{
    address player = determinePlayer(serverSeeds, clientSeeds, results, v, r, s);
    uint gasCost;
    //charge gas in case the server is logging the results for the player
    if(player != msg.sender){
      gasCost = (57 + 768 * serverSeeds.length / 1000)*gasPrice;
      balanceOf[player] = safeSub(balanceOf[player], gasCost);
      playerBalance = safeSub(playerBalance, gasCost);
      gasPayback = safeAdd(gasPayback, gasCost);
    }
    emit GameData(player, serverSeeds, clientSeeds, results, gasCost);
  }
  
  /**
   * determines if the msg.sender or the signer of the passed signature is the player. returns the player's address
   * @param serverSeeds array containing the server seeds
   *        clientSeeds array containing the client seeds
   *        results     array containing the results
   *				v, r, s    the signature of the non-sending party
   * */
  function determinePlayer(bytes32[] serverSeeds, bytes32[] clientSeeds, int[] results, uint8 v, bytes32 r, bytes32 s) view internal returns(address){
  	address signer = ecrecover(keccak256(serverSeeds, clientSeeds, results), v, r, s);
  	if (authorized[msg.sender])//casino is the sender -> player is the signer
  		return signer;
  	else if (authorized[signer])
  		return msg.sender;
  	else 
  	  revert();
  }

}

Contract Security Audit

Contract ABI

[{"constant":false,"inputs":[{"name":"serverSeeds","type":"bytes32[]"},{"name":"clientSeeds","type":"bytes32[]"},{"name":"results","type":"int256[]"},{"name":"v","type":"uint8"},{"name":"r","type":"bytes32"},{"name":"s","type":"bytes32"}],"name":"logGameData","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"bankroll","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"receiver","type":"address"}],"name":"disallowReceiver","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"signatures","type":"bytes4[5]"},{"name":"gasNeeded","type":"uint256[5]"}],"name":"setGasUsage","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"lastState","outputs":[{"name":"count","type":"uint128"},{"name":"winBalance","type":"int128"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"addr","type":"address"}],"name":"deauthorize","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"newMax","type":"uint256"}],"name":"setMaxWithdrawal","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"receiver","type":"address"},{"name":"numTokens","type":"uint256"},{"name":"chargeGas","type":"bool"}],"name":"deposit","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"close","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"withdrawAfter","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"withdrawCount","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"maxDeposit","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"playerBalance","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"newCasino","type":"address"},{"name":"v","type":"uint8"},{"name":"r","type":"bytes32"},{"name":"s","type":"bytes32"},{"name":"chargeGas","type":"bool"}],"name":"transferToNewContract","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"balanceOf","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"oneEDG","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"maxWithdrawal","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"receiver","type":"address"},{"name":"amount","type":"uint256"},{"name":"v","type":"uint8"},{"name":"r","type":"bytes32"},{"name":"s","type":"bytes32"}],"name":"withdrawFor","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"newOwner","type":"address"}],"name":"changeOwner","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"closeAt","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"waitingTime","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"","type":"bytes4"}],"name":"gasPerTx","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"allowedReceiver","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"addr","type":"address"}],"name":"authorize","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"predecessor","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"authorized","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"newMax","type":"uint256"}],"name":"setMaxDeposit","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"receiver","type":"address"}],"name":"allowReceiver","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"price","type":"uint256"}],"name":"setGasPrice","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"winBalances","type":"int128[]"},{"name":"gameCounts","type":"uint128[]"},{"name":"v","type":"uint8[]"},{"name":"r","type":"bytes32[]"},{"name":"s","type":"bytes32[]"},{"name":"chargeGas","type":"bool"}],"name":"updateBatch","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"requestWithdrawal","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"winBalance","type":"int128"},{"name":"gameCount","type":"uint128"},{"name":"v","type":"uint8"},{"name":"r","type":"bytes32"},{"name":"s","type":"bytes32"},{"name":"chargeGas","type":"bool"}],"name":"updateState","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"gasPayback","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"cancelWithdrawalRequest","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"receiver","type":"address"},{"name":"numTokens","type":"uint256"}],"name":"withdrawBankroll","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"newWaitingTime","type":"uint256"}],"name":"setWaitingTime","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"player","type":"address"},{"name":"value","type":"uint256"}],"name":"credit","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"withdrawGasPayback","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"open","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"gasPrice","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[{"name":"predecessorAddress","type":"address"},{"name":"tokenContract","type":"address"},{"name":"depositLimit","type":"uint256"},{"name":"kGasPrice","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"name":"player","type":"address"},{"indexed":false,"name":"count","type":"uint128"},{"indexed":false,"name":"winBalance","type":"int128"},{"indexed":false,"name":"difference","type":"int256"},{"indexed":false,"name":"gasCost","type":"uint256"}],"name":"StateUpdate","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"player","type":"address"},{"indexed":false,"name":"serverSeeds","type":"bytes32[]"},{"indexed":false,"name":"clientSeeds","type":"bytes32[]"},{"indexed":false,"name":"results","type":"int256[]"},{"indexed":false,"name":"gasCost","type":"uint256"}],"name":"GameData","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"_player","type":"address"},{"indexed":false,"name":"_numTokens","type":"uint256"},{"indexed":false,"name":"_gasCost","type":"uint256"}],"name":"Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"_player","type":"address"},{"indexed":false,"name":"_receiver","type":"address"},{"indexed":false,"name":"_numTokens","type":"uint256"},{"indexed":false,"name":"_gasCost","type":"uint256"}],"name":"Withdrawal","type":"event"}]

606060405234156200001057600080fd5b6040516080806200281583398101604052808051919060200180519190602001805191906020018051915082905084826200004a620002fa565b6200005462000323565b60008054600160a060020a031990811633600160a060020a03908116918217845560028054909316908c16179091558152600360209081526040808320805460ff1990811660019081179092556004909352928190208054909216909217905560a0905190810160409081527f3edd11280000000000000000000000000000000000000000000000000000000082527f9607610a0000000000000000000000000000000000000000000000000000000060208301527fde48ff5200000000000000000000000000000000000000000000000000000000818301527fc97b6d1f0000000000000000000000000000000000000000000000000000000060608301527f6bf06fde00000000000000000000000000000000000000000000000000000000608083015290925060a090519081016040908152609282526064602083015260419082015260326060820152605560808201529050620001c4828264010000000062000bc66200022182021704565b620001dd8364010000000062001780620002be82021704565b505050620186a091909102600c819055600d5562015180600e55600f8054600160a060020a031916600160a060020a03909216919091179055506200034b92505050565b6000805433600160a060020a039081169116146200023e57600080fd5b5060005b60058160ff161015620002b9578160ff8216600581106200025f57fe5b6020020151600660008560ff8516600581106200027857fe5b60200201517fffffffff0000000000000000000000000000000000000000000000000000000016815260208101919091526040016000205560010162000242565b505050565b600160a060020a03331660009081526003602052604090205460ff161515620002e657600080fd5b6127108110620002f557600080fd5b600555565b60a06040519081016040526005815b600081526000199091019060200181620003095790505090565b60a06040519081016040526005815b6000815260200190600190039081620003325790505090565b6124ba806200035b6000396000f3006060604052600436106101ea5763ffffffff60e060020a6000350416630102305b81146101ef5780630c657eb0146102d05780631ae32b82146102f55780631e33a6d514610314578063203faa891461037557806327c97fa5146103bd5780632e1a7d4d146103dc5780633926384d146103f25780633edd11281461040857806343d726d61461042f5780634659f42a146104425780634f23618f146104615780636083e59a14610480578063651f066a146104935780636bf06fde146104a657806370a08231146104d65780637ab4e968146104f55780638c0ff5b7146105085780638da5cb5b1461051b5780639607610a1461054a578063a6f9dae114610578578063a985408714610597578063aa13e8c2146105aa578063ad8ce06b146105bd578063b2f5e6c2146105f2578063b6a5d7de14610625578063b719d03214610644578063b918161114610657578063bb371fdd14610676578063bb7502321461068c578063bf1fe420146106ab578063c97b6d1f146106c1578063dbaf214514610814578063de48ff5214610827578063e1538b321461085d578063e714a02814610870578063e9e3074614610883578063ebc73e65146108a5578063ef6506db146108bb578063f66e86bb146108dd578063fcfff16f146108f0578063fe173b9714610903575b600080fd5b34156101fa57600080fd5b6102ce600460248135818101908301358060208181020160405190810160405280939291908181526020018383602002808284378201915050505050509190803590602001908201803590602001908080602002602001604051908101604052809392919081815260200183836020028082843782019150505050505091908035906020019082018035906020019080806020026020016040519081016040528093929190818152602001838360200280828437509496505060ff8535169460208101359450604001359250610916915050565b005b34156102db57600080fd5b6102e3610af6565b60405190815260200160405180910390f35b341561030057600080fd5b6102ce600160a060020a0360043516610b8a565b341561031f57600080fd5b6102ce600460a481600560a06040519081016040529190828260a080828437820191505050505091908060a001906005806020026040519081016040529190828260a08082843750939550610bc6945050505050565b341561038057600080fd5b610394600160a060020a0360043516610c5b565b6040516001608060020a039092168252600f90810b900b60208201526040908101905180910390f35b34156103c857600080fd5b6102ce600160a060020a0360043516610c82565b34156103e757600080fd5b6102ce600435610cbe565b34156103fd57600080fd5b6102ce600435610e73565b341561041357600080fd5b6102ce600160a060020a03600435166024356044351515610ea4565b341561043a57600080fd5b6102ce611045565b341561044d57600080fd5b6102e3600160a060020a036004351661106d565b341561046c57600080fd5b6102e3600160a060020a036004351661107f565b341561048b57600080fd5b6102e3611091565b341561049e57600080fd5b6102e3611097565b34156104b157600080fd5b6102ce600160a060020a036004351660ff60243516604435606435608435151561109d565b34156104e157600080fd5b6102e3600160a060020a036004351661135a565b341561050057600080fd5b6102e361136c565b341561051357600080fd5b6102e3611373565b341561052657600080fd5b61052e611379565b604051600160a060020a03909116815260200160405180910390f35b341561055557600080fd5b6102ce600160a060020a036004351660243560ff60443516606435608435611388565b341561058357600080fd5b6102ce600160a060020a03600435166115f4565b34156105a257600080fd5b6102e361167a565b34156105b557600080fd5b6102e3611680565b34156105c857600080fd5b6102e37bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1960043516611686565b34156105fd57600080fd5b610611600160a060020a0360043516611698565b604051901515815260200160405180910390f35b341561063057600080fd5b6102ce600160a060020a03600435166116ad565b341561064f57600080fd5b61052e6116ec565b341561066257600080fd5b610611600160a060020a03600435166116fb565b341561068157600080fd5b6102ce600435611710565b341561069757600080fd5b6102ce600160a060020a0360043516611741565b34156106b657600080fd5b6102ce600435611780565b34156106cc57600080fd5b6102ce6004602481358181019083013580602081810201604051908101604052809392919081815260200183836020028082843782019150505050505091908035906020019082018035906020019080806020026020016040519081016040528093929190818152602001838360200280828437820191505050505050919080359060200190820180359060200190808060200260200160405190810160405280939291908181526020018383602002808284378201915050505050509190803590602001908201803590602001908080602002602001604051908101604052809392919081815260200183836020028082843782019150505050505091908035906020019082018035906020019080806020026020016040519081016040528093929190818152602001838360200280828437509496505050509135151591506117ba9050565b341561081f57600080fd5b6102ce6119bc565b341561083257600080fd5b6102ce600435600f0b6001608060020a036024351660ff6044351660643560843560a43515156119df565b341561086857600080fd5b6102e3611b29565b341561087b57600080fd5b6102ce611b2f565b341561088e57600080fd5b6102ce600160a060020a0360043516602435611b4a565b34156108b057600080fd5b6102ce600435611c25565b34156108c657600080fd5b610611600160a060020a0360043516602435611c61565b34156108e857600080fd5b6102ce611d41565b34156108fb57600080fd5b6102ce611e0f565b341561090e57600080fd5b6102e3611e31565b600080610927888888888888611e37565b915033600160a060020a031682600160a060020a03161415156109c9576005546103e889516103000281151561095957fe5b0460390102905061098f6009600084600160a060020a0316600160a060020a031681526020019081526020016000205482611f9a565b600160a060020a0383166000908152600960205260409020556008546109b59082611f9a565b6008556007546109c59082611fac565b6007555b7f1139e9be34b0b8aee07eb5c072c11de928d5e4c6d1b29bc68aea129464b62b0082898989856040518086600160a060020a0316600160a060020a03168152602001806020018060200180602001858152602001848103845288818151815260200191508051906020019060200280838360005b83811015610a55578082015183820152602001610a3d565b50505050905001848103835287818151815260200191508051906020019060200280838360005b83811015610a94578082015183820152602001610a7c565b50505050905001848103825286818151815260200191508051906020019060200280838360005b83811015610ad3578082015183820152602001610abb565b505050509050019850505050505050505060405180910390a15050505050505050565b600254600090610b8590600160a060020a03166370a082313060405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b1515610b4d57600080fd5b5af11515610b5a57600080fd5b50505060405180519050620186a0610b76600854600754611fac565b811515610b7f57fe5b04611f9a565b905090565b60005433600160a060020a03908116911614610ba557600080fd5b600160a060020a03166000908152600460205260409020805460ff19169055565b6000805433600160a060020a03908116911614610be257600080fd5b5060005b60058160ff161015610c56578160ff821660058110610c0157fe5b6020020151600660008560ff851660058110610c1957fe5b60200201517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168152602081019190915260400160002055600101610be6565b505050565b6010602052600090815260409020546001608060020a03811690608060020a9004600f0b82565b60005433600160a060020a03908116911614610c9d57600080fd5b600160a060020a03166000908152600360205260409020805460ff19169055565b6000806001541115610cd45762278d0042016001555b600d54821115610ce357600080fd5b600160a060020a0333166000908152600a6020526040812054118015610d205750600160a060020a0333166000908152600a602052604090205442115b1515610d2b57600080fd5b600160a060020a0333166000908152600a6020526040812055610d5182620186a0611fd0565b600160a060020a033316600090815260096020526040902054909150610d779082611f9a565b600160a060020a033316600090815260096020526040902055600854610d9d9082611f9a565b600855600254600160a060020a031663a9059cbb338460405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b1515610df657600080fd5b5af11515610e0357600080fd5b505050604051805190501515610e1557fe5b7fc2b4a290c20fb28939d29f102514fbffd2b73c059ffba8b78250c94161d5fcc63333846000604051600160a060020a0394851681529290931660208301526040808301919091526060820192909252608001905180910390a15050565b600160a060020a03331660009081526003602052604090205460ff161515610e9a57600080fd5b620186a002600d55565b60008060006001546000141515610eba57600080fd5b60008511610ec757600080fd5b610ed485620186a0611fd0565b92508315610f0257610ee4611ff1565b9150610ef08383611f9a565b9250610efe60075483611fac565b6007555b600160a060020a038616600090815260096020526040902054610f259084611fac565b600c54909150811115610f3757600080fd5b600254600160a060020a03166323b872dd33308860405160e060020a63ffffffff8616028152600160a060020a0393841660048201529190921660248201526044810191909152606401602060405180830381600087803b1515610f9a57600080fd5b5af11515610fa757600080fd5b505050604051805190501515610fb957fe5b600160a060020a0386166000908152600960205260409020819055600854610fe19084611fac565b6008557f90890809c654f11d6e72a28fa60149770a0d11ec6c92319d6ceb2bb0a4ea1a158686846040518084600160a060020a0316600160a060020a03168152602001838152602001828152602001935050505060405180910390a1505050505050565b60005433600160a060020a0390811691161461106057600080fd5b61106b60085461204c565b565b600a6020526000908152604090205481565b600b6020526000908152604090205481565b600c5481565b60085481565b600160a060020a03331660009081526003602052604081205481908190819060ff1615156110ca57600080fd5b600060015411156110df5762278d0042016001555b6001308a6040516c01000000000000000000000000600160a060020a03938416810282529190921602601482015260280160405180910390208989896040516000815260200160405260405193845260ff9092166020808501919091526040808501929092526060840192909252608090920191516020810390808403906000865af1151561116d57600080fd5b505060206040510351935060009250841561118d5761118a611ff1565b92505b600160a060020a0384166000908152600960205260409020546111b09084611f9a565b9150620186a082116111c157600080fd5b600854600160a060020a038516600090815260096020526040902054620186a0909304926111ef9190611f9a565b600855600160a060020a03808516600090815260096020526040808220919091556002549091169063a9059cbb908b9085905160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b151561126257600080fd5b5af1151561126f57600080fd5b50505060405180519050151561128157fe5b7fc2b4a290c20fb28939d29f102514fbffd2b73c059ffba8b78250c94161d5fcc6848a8486604051600160a060020a0394851681529290931660208301526040808301919091526060820192909252608001905180910390a15087600160a060020a03811663ef6506db858460405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b151561133057600080fd5b5af1151561133d57600080fd5b50505060405180519050151561134f57fe5b505050505050505050565b60096020526000908152604090205481565b620186a081565b600d5481565b600054600160a060020a031681565b600160a060020a0333166000908152600360205260408120548190819060ff1615156113b357600080fd5b600060015411156113c85762278d0042016001555b600160a060020a0388166000908152600b602052604090819020546001918a918a9151600160a060020a03939093166c010000000000000000000000000283526014830191909152603482015260540160405180910390208787876040516000815260200160405260405193845260ff9092166020808501919091526040808501929092526060840192909252608090920191516020810390808403906000865af1151561147557600080fd5b505060206040510351600160a060020a0389166000908152600b602052604090208054600101905592506114a7611ff1565b91506114bf6114b988620186a0611fd0565b83611fac565b90506114cd60075483611fac565b600755600160a060020a0383166000908152600960205260409020546114f39082611f9a565b600160a060020a0384166000908152600960205260409020556008546115199082611f9a565b600855600254600160a060020a031663a9059cbb898960405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b151561157257600080fd5b5af1151561157f57600080fd5b50505060405180519050151561159157fe5b7fc2b4a290c20fb28939d29f102514fbffd2b73c059ffba8b78250c94161d5fcc683898985604051600160a060020a0394851681529290931660208301526040808301919091526060820192909252608001905180910390a15050505050505050565b60005433600160a060020a0390811691161461160f57600080fd5b60005461162490600160a060020a0316610c82565b61162d816116ad565b60005461164290600160a060020a0316610b8a565b61164b81611741565b6000805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b60015481565b600e5481565b60066020526000908152604090205481565b60046020526000908152604090205460ff1681565b60005433600160a060020a039081169116146116c857600080fd5b600160a060020a03166000908152600360205260409020805460ff19166001179055565b600f54600160a060020a031681565b60036020526000908152604090205460ff1681565b600160a060020a03331660009081526003602052604090205460ff16151561173757600080fd5b620186a002600c55565b60005433600160a060020a0390811691161461175c57600080fd5b600160a060020a03166000908152600460205260409020805460ff19166001179055565b600160a060020a03331660009081526003602052604090205460ff1615156117a757600080fd5b61271081106117b557600080fd5b600555565b600160a060020a0333166000908152600360205260408120548190819060ff1615156117e557600080fd5b87518951146117f357600080fd5b865189511461180157600080fd5b855189511461180f57600080fd5b845189511461181d57600080fd5b60328951111561182c57600080fd5b6000915083156118415761183e611ff1565b91505b611857600754611852848c51611fd0565b611fac565b6007555060005b88518160ff16101561134f576001898260ff168151811061187b57fe5b90602001906020020151898360ff168151811061189457fe5b90602001906020020151604051608060020a600f93840b90930b830281526001608060020a0390911690910260108201526020016040518091039020888360ff16815181106118df57fe5b90602001906020020151888460ff16815181106118f857fe5b90602001906020020151888560ff168151811061191157fe5b906020019060200201516040516000815260200160405260405193845260ff9092166020808501919091526040808501929092526060840192909252608090920191516020810390808403906000865af1151561196d57600080fd5b50506020604051035192506119b4838a8360ff168151811061198b57fe5b906020019060200201518a8460ff16815181106119a457fe5b906020019060200201518561214f565b60010161185e565b600e54600160a060020a0333166000908152600a60205260409020429091019055565b6000806119ef88888888886122ae565b91506000905033600160a060020a031682600160a060020a03161415611af357600360006001848b8b6040516c01000000000000000000000000600160a060020a03909416939093028352608060020a600f92830b90920b820260148401526001608060020a031602602482015260340160405180910390208989896040516000815260200160405260405193845260ff9092166020808501919091526040808501929092526060840192909252608090920191516020810390808403906000865af11515611abd57600080fd5b505060206040510351600160a060020a0316815260208101919091526040016000205460ff161515611aee57600080fd5b611b13565b8215611b1357611b01611ff1565b9050611b0f60075482611fac565b6007555b611b1f8289898461214f565b5050505050505050565b60075481565b600160a060020a0333166000908152600a6020526040812055565b600160a060020a03331660009081526003602052604090205460ff161515611b7157600080fd5b611b79610af6565b811115611b8557600080fd5b600160a060020a03821660009081526004602052604090205460ff161515611bac57600080fd5b600254600160a060020a031663a9059cbb838360405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b1515611c0257600080fd5b5af11515611c0f57600080fd5b505050604051805190501515611c2157fe5b5050565b600160a060020a03331660009081526003602052604090205460ff161515611c4c57600080fd5b62015180811115611c5c57600080fd5b600e55565b600f54600090819033600160a060020a03908116911614611c8157600080fd5b611c8e83620186a0611fd0565b600160a060020a038516600090815260096020526040902054909150611cb49082611fac565b600160a060020a038516600090815260096020526040902055600854611cda9082611fac565b6008557f90890809c654f11d6e72a28fa60149770a0d11ec6c92319d6ceb2bb0a4ea1a15848460006040518084600160a060020a0316600160a060020a03168152602001838152602001828152602001935050505060405180910390a15060019392505050565b600160a060020a03331660009081526003602052604081205460ff161515611d6857600080fd5b50600754620186a0900460008111611d7c57fe5b611d8d600754620186a08302611f9a565b600755600254600054600160a060020a039182169163a9059cbb91168360405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b1515611ded57600080fd5b5af11515611dfa57600080fd5b505050604051805190501515611e0c57fe5b50565b60005433600160a060020a03908116911614611e2a57600080fd5b6000600155565b60055481565b600080600188888860405180848051906020019060200280838360005b83811015611e6c578082015183820152602001611e54565b50505050905001838051906020019060200280838360005b83811015611e9c578082015183820152602001611e84565b50505050905001828051906020019060200280838360005b83811015611ecc578082015183820152602001611eb4565b50505050905001935050505060405180910390208686866040516000815260200160405260405193845260ff9092166020808501919091526040808501929092526060840192909252608090920191516020810390808403906000865af11515611f3557600080fd5b505060206040510351600160a060020a03331660009081526003602052604090205490915060ff1615611f6a57809150611f8f565b600160a060020a03811660009081526003602052604090205460ff16156101ea573391505b509695505050505050565b600082821115611fa657fe5b50900390565b6000828201838110801590611fc15750828110155b1515611fc957fe5b9392505050565b6000828202831580611fc15750828482811515611fe957fe5b0414611fc957fe5b600080357bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916815260066020526040812054600554633b9aca009161203d916120379190611fd0565b3a611fd0565b81151561204657fe5b04905090565b600154151561205f5762278d0042016001555b42600154108061206d575080155b15611e0c57600254600054600160a060020a039182169163a9059cbb9116826370a082313060405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b15156120d057600080fd5b5af115156120dd57600080fd5b5050506040518051905060405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b151561212a57600080fd5b5af1151561213757600080fd5b50505060405180515050600054600160a060020a0316ff5b600160a060020a038416600090815260106020526040812080549091906001608060020a039081169085161161218457600080fd5b815461219e9087908790608060020a9004600f0b86612376565b90506040805190810160409081526001608060020a0386168252600f87900b602080840191909152600160a060020a0389166000908152601090915220815181546fffffffffffffffffffffffffffffffff19166001608060020a039190911617815560208201518154600f9190910b6001608060020a03908116608060020a029116179055507fbbddc02bfa2e7cedacea185a3820c053215b120e102dd6de97b11d4ba8897ab886858784876040518086600160a060020a0316600160a060020a03168152602001856001608060020a03166001608060020a0316815260200184600f0b600f0b81526020018381526020018281526020019550505050505060405180910390a1505050505050565b600160a060020a03331660009081526003602052604081205460ff161561236a5760018686604051608060020a600f93840b90930b830281526001608060020a03909116909102601082015260200160405180910390208585856040516000815260200160405260405193845260ff9092166020808501919091526040808501929092526060840192909252608090920191516020810390808403906000865af1151561235a57600080fd5b505060206040510351905061236d565b50335b95945050505050565b600080600061238b86600f0b86600f0b612466565b92506123978385612466565b915060008212156123f957816000190290506123b560085482611f9a565b600855600160a060020a0387166000908152600960205260409020546123db9082611f9a565b600160a060020a03881660009081526009602052604090205561245c565b508080620186a0612408610af6565b021161241057fe5b61241c60085482611fac565b600855600160a060020a0387166000908152600960205260409020546124429082611fac565b600160a060020a0388166000908152600960205260409020555b5050949350505050565b6000808212156124815781830383901361247c57fe5b611fa6565b81830383901315611fa657fe00a165627a7a7230582010adc13c966227d3bfc7ddbbac28967494f2d5e138e036293b4275ca8402c751002900000000000000000000000015f08079310e2c9dacaa73c0e450368185724aea00000000000000000000000008711d3b02c8758f2fb3ab4e80228418a7f8e39c0000000000000000000000000000000000000000000000000000000008f0d1800000000000000000000000000000000000000000000000000000000000000073

Deployed Bytecode

0x6060604052600436106101ea5763ffffffff60e060020a6000350416630102305b81146101ef5780630c657eb0146102d05780631ae32b82146102f55780631e33a6d514610314578063203faa891461037557806327c97fa5146103bd5780632e1a7d4d146103dc5780633926384d146103f25780633edd11281461040857806343d726d61461042f5780634659f42a146104425780634f23618f146104615780636083e59a14610480578063651f066a146104935780636bf06fde146104a657806370a08231146104d65780637ab4e968146104f55780638c0ff5b7146105085780638da5cb5b1461051b5780639607610a1461054a578063a6f9dae114610578578063a985408714610597578063aa13e8c2146105aa578063ad8ce06b146105bd578063b2f5e6c2146105f2578063b6a5d7de14610625578063b719d03214610644578063b918161114610657578063bb371fdd14610676578063bb7502321461068c578063bf1fe420146106ab578063c97b6d1f146106c1578063dbaf214514610814578063de48ff5214610827578063e1538b321461085d578063e714a02814610870578063e9e3074614610883578063ebc73e65146108a5578063ef6506db146108bb578063f66e86bb146108dd578063fcfff16f146108f0578063fe173b9714610903575b600080fd5b34156101fa57600080fd5b6102ce600460248135818101908301358060208181020160405190810160405280939291908181526020018383602002808284378201915050505050509190803590602001908201803590602001908080602002602001604051908101604052809392919081815260200183836020028082843782019150505050505091908035906020019082018035906020019080806020026020016040519081016040528093929190818152602001838360200280828437509496505060ff8535169460208101359450604001359250610916915050565b005b34156102db57600080fd5b6102e3610af6565b60405190815260200160405180910390f35b341561030057600080fd5b6102ce600160a060020a0360043516610b8a565b341561031f57600080fd5b6102ce600460a481600560a06040519081016040529190828260a080828437820191505050505091908060a001906005806020026040519081016040529190828260a08082843750939550610bc6945050505050565b341561038057600080fd5b610394600160a060020a0360043516610c5b565b6040516001608060020a039092168252600f90810b900b60208201526040908101905180910390f35b34156103c857600080fd5b6102ce600160a060020a0360043516610c82565b34156103e757600080fd5b6102ce600435610cbe565b34156103fd57600080fd5b6102ce600435610e73565b341561041357600080fd5b6102ce600160a060020a03600435166024356044351515610ea4565b341561043a57600080fd5b6102ce611045565b341561044d57600080fd5b6102e3600160a060020a036004351661106d565b341561046c57600080fd5b6102e3600160a060020a036004351661107f565b341561048b57600080fd5b6102e3611091565b341561049e57600080fd5b6102e3611097565b34156104b157600080fd5b6102ce600160a060020a036004351660ff60243516604435606435608435151561109d565b34156104e157600080fd5b6102e3600160a060020a036004351661135a565b341561050057600080fd5b6102e361136c565b341561051357600080fd5b6102e3611373565b341561052657600080fd5b61052e611379565b604051600160a060020a03909116815260200160405180910390f35b341561055557600080fd5b6102ce600160a060020a036004351660243560ff60443516606435608435611388565b341561058357600080fd5b6102ce600160a060020a03600435166115f4565b34156105a257600080fd5b6102e361167a565b34156105b557600080fd5b6102e3611680565b34156105c857600080fd5b6102e37bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1960043516611686565b34156105fd57600080fd5b610611600160a060020a0360043516611698565b604051901515815260200160405180910390f35b341561063057600080fd5b6102ce600160a060020a03600435166116ad565b341561064f57600080fd5b61052e6116ec565b341561066257600080fd5b610611600160a060020a03600435166116fb565b341561068157600080fd5b6102ce600435611710565b341561069757600080fd5b6102ce600160a060020a0360043516611741565b34156106b657600080fd5b6102ce600435611780565b34156106cc57600080fd5b6102ce6004602481358181019083013580602081810201604051908101604052809392919081815260200183836020028082843782019150505050505091908035906020019082018035906020019080806020026020016040519081016040528093929190818152602001838360200280828437820191505050505050919080359060200190820180359060200190808060200260200160405190810160405280939291908181526020018383602002808284378201915050505050509190803590602001908201803590602001908080602002602001604051908101604052809392919081815260200183836020028082843782019150505050505091908035906020019082018035906020019080806020026020016040519081016040528093929190818152602001838360200280828437509496505050509135151591506117ba9050565b341561081f57600080fd5b6102ce6119bc565b341561083257600080fd5b6102ce600435600f0b6001608060020a036024351660ff6044351660643560843560a43515156119df565b341561086857600080fd5b6102e3611b29565b341561087b57600080fd5b6102ce611b2f565b341561088e57600080fd5b6102ce600160a060020a0360043516602435611b4a565b34156108b057600080fd5b6102ce600435611c25565b34156108c657600080fd5b610611600160a060020a0360043516602435611c61565b34156108e857600080fd5b6102ce611d41565b34156108fb57600080fd5b6102ce611e0f565b341561090e57600080fd5b6102e3611e31565b600080610927888888888888611e37565b915033600160a060020a031682600160a060020a03161415156109c9576005546103e889516103000281151561095957fe5b0460390102905061098f6009600084600160a060020a0316600160a060020a031681526020019081526020016000205482611f9a565b600160a060020a0383166000908152600960205260409020556008546109b59082611f9a565b6008556007546109c59082611fac565b6007555b7f1139e9be34b0b8aee07eb5c072c11de928d5e4c6d1b29bc68aea129464b62b0082898989856040518086600160a060020a0316600160a060020a03168152602001806020018060200180602001858152602001848103845288818151815260200191508051906020019060200280838360005b83811015610a55578082015183820152602001610a3d565b50505050905001848103835287818151815260200191508051906020019060200280838360005b83811015610a94578082015183820152602001610a7c565b50505050905001848103825286818151815260200191508051906020019060200280838360005b83811015610ad3578082015183820152602001610abb565b505050509050019850505050505050505060405180910390a15050505050505050565b600254600090610b8590600160a060020a03166370a082313060405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b1515610b4d57600080fd5b5af11515610b5a57600080fd5b50505060405180519050620186a0610b76600854600754611fac565b811515610b7f57fe5b04611f9a565b905090565b60005433600160a060020a03908116911614610ba557600080fd5b600160a060020a03166000908152600460205260409020805460ff19169055565b6000805433600160a060020a03908116911614610be257600080fd5b5060005b60058160ff161015610c56578160ff821660058110610c0157fe5b6020020151600660008560ff851660058110610c1957fe5b60200201517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168152602081019190915260400160002055600101610be6565b505050565b6010602052600090815260409020546001608060020a03811690608060020a9004600f0b82565b60005433600160a060020a03908116911614610c9d57600080fd5b600160a060020a03166000908152600360205260409020805460ff19169055565b6000806001541115610cd45762278d0042016001555b600d54821115610ce357600080fd5b600160a060020a0333166000908152600a6020526040812054118015610d205750600160a060020a0333166000908152600a602052604090205442115b1515610d2b57600080fd5b600160a060020a0333166000908152600a6020526040812055610d5182620186a0611fd0565b600160a060020a033316600090815260096020526040902054909150610d779082611f9a565b600160a060020a033316600090815260096020526040902055600854610d9d9082611f9a565b600855600254600160a060020a031663a9059cbb338460405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b1515610df657600080fd5b5af11515610e0357600080fd5b505050604051805190501515610e1557fe5b7fc2b4a290c20fb28939d29f102514fbffd2b73c059ffba8b78250c94161d5fcc63333846000604051600160a060020a0394851681529290931660208301526040808301919091526060820192909252608001905180910390a15050565b600160a060020a03331660009081526003602052604090205460ff161515610e9a57600080fd5b620186a002600d55565b60008060006001546000141515610eba57600080fd5b60008511610ec757600080fd5b610ed485620186a0611fd0565b92508315610f0257610ee4611ff1565b9150610ef08383611f9a565b9250610efe60075483611fac565b6007555b600160a060020a038616600090815260096020526040902054610f259084611fac565b600c54909150811115610f3757600080fd5b600254600160a060020a03166323b872dd33308860405160e060020a63ffffffff8616028152600160a060020a0393841660048201529190921660248201526044810191909152606401602060405180830381600087803b1515610f9a57600080fd5b5af11515610fa757600080fd5b505050604051805190501515610fb957fe5b600160a060020a0386166000908152600960205260409020819055600854610fe19084611fac565b6008557f90890809c654f11d6e72a28fa60149770a0d11ec6c92319d6ceb2bb0a4ea1a158686846040518084600160a060020a0316600160a060020a03168152602001838152602001828152602001935050505060405180910390a1505050505050565b60005433600160a060020a0390811691161461106057600080fd5b61106b60085461204c565b565b600a6020526000908152604090205481565b600b6020526000908152604090205481565b600c5481565b60085481565b600160a060020a03331660009081526003602052604081205481908190819060ff1615156110ca57600080fd5b600060015411156110df5762278d0042016001555b6001308a6040516c01000000000000000000000000600160a060020a03938416810282529190921602601482015260280160405180910390208989896040516000815260200160405260405193845260ff9092166020808501919091526040808501929092526060840192909252608090920191516020810390808403906000865af1151561116d57600080fd5b505060206040510351935060009250841561118d5761118a611ff1565b92505b600160a060020a0384166000908152600960205260409020546111b09084611f9a565b9150620186a082116111c157600080fd5b600854600160a060020a038516600090815260096020526040902054620186a0909304926111ef9190611f9a565b600855600160a060020a03808516600090815260096020526040808220919091556002549091169063a9059cbb908b9085905160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b151561126257600080fd5b5af1151561126f57600080fd5b50505060405180519050151561128157fe5b7fc2b4a290c20fb28939d29f102514fbffd2b73c059ffba8b78250c94161d5fcc6848a8486604051600160a060020a0394851681529290931660208301526040808301919091526060820192909252608001905180910390a15087600160a060020a03811663ef6506db858460405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b151561133057600080fd5b5af1151561133d57600080fd5b50505060405180519050151561134f57fe5b505050505050505050565b60096020526000908152604090205481565b620186a081565b600d5481565b600054600160a060020a031681565b600160a060020a0333166000908152600360205260408120548190819060ff1615156113b357600080fd5b600060015411156113c85762278d0042016001555b600160a060020a0388166000908152600b602052604090819020546001918a918a9151600160a060020a03939093166c010000000000000000000000000283526014830191909152603482015260540160405180910390208787876040516000815260200160405260405193845260ff9092166020808501919091526040808501929092526060840192909252608090920191516020810390808403906000865af1151561147557600080fd5b505060206040510351600160a060020a0389166000908152600b602052604090208054600101905592506114a7611ff1565b91506114bf6114b988620186a0611fd0565b83611fac565b90506114cd60075483611fac565b600755600160a060020a0383166000908152600960205260409020546114f39082611f9a565b600160a060020a0384166000908152600960205260409020556008546115199082611f9a565b600855600254600160a060020a031663a9059cbb898960405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b151561157257600080fd5b5af1151561157f57600080fd5b50505060405180519050151561159157fe5b7fc2b4a290c20fb28939d29f102514fbffd2b73c059ffba8b78250c94161d5fcc683898985604051600160a060020a0394851681529290931660208301526040808301919091526060820192909252608001905180910390a15050505050505050565b60005433600160a060020a0390811691161461160f57600080fd5b60005461162490600160a060020a0316610c82565b61162d816116ad565b60005461164290600160a060020a0316610b8a565b61164b81611741565b6000805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b60015481565b600e5481565b60066020526000908152604090205481565b60046020526000908152604090205460ff1681565b60005433600160a060020a039081169116146116c857600080fd5b600160a060020a03166000908152600360205260409020805460ff19166001179055565b600f54600160a060020a031681565b60036020526000908152604090205460ff1681565b600160a060020a03331660009081526003602052604090205460ff16151561173757600080fd5b620186a002600c55565b60005433600160a060020a0390811691161461175c57600080fd5b600160a060020a03166000908152600460205260409020805460ff19166001179055565b600160a060020a03331660009081526003602052604090205460ff1615156117a757600080fd5b61271081106117b557600080fd5b600555565b600160a060020a0333166000908152600360205260408120548190819060ff1615156117e557600080fd5b87518951146117f357600080fd5b865189511461180157600080fd5b855189511461180f57600080fd5b845189511461181d57600080fd5b60328951111561182c57600080fd5b6000915083156118415761183e611ff1565b91505b611857600754611852848c51611fd0565b611fac565b6007555060005b88518160ff16101561134f576001898260ff168151811061187b57fe5b90602001906020020151898360ff168151811061189457fe5b90602001906020020151604051608060020a600f93840b90930b830281526001608060020a0390911690910260108201526020016040518091039020888360ff16815181106118df57fe5b90602001906020020151888460ff16815181106118f857fe5b90602001906020020151888560ff168151811061191157fe5b906020019060200201516040516000815260200160405260405193845260ff9092166020808501919091526040808501929092526060840192909252608090920191516020810390808403906000865af1151561196d57600080fd5b50506020604051035192506119b4838a8360ff168151811061198b57fe5b906020019060200201518a8460ff16815181106119a457fe5b906020019060200201518561214f565b60010161185e565b600e54600160a060020a0333166000908152600a60205260409020429091019055565b6000806119ef88888888886122ae565b91506000905033600160a060020a031682600160a060020a03161415611af357600360006001848b8b6040516c01000000000000000000000000600160a060020a03909416939093028352608060020a600f92830b90920b820260148401526001608060020a031602602482015260340160405180910390208989896040516000815260200160405260405193845260ff9092166020808501919091526040808501929092526060840192909252608090920191516020810390808403906000865af11515611abd57600080fd5b505060206040510351600160a060020a0316815260208101919091526040016000205460ff161515611aee57600080fd5b611b13565b8215611b1357611b01611ff1565b9050611b0f60075482611fac565b6007555b611b1f8289898461214f565b5050505050505050565b60075481565b600160a060020a0333166000908152600a6020526040812055565b600160a060020a03331660009081526003602052604090205460ff161515611b7157600080fd5b611b79610af6565b811115611b8557600080fd5b600160a060020a03821660009081526004602052604090205460ff161515611bac57600080fd5b600254600160a060020a031663a9059cbb838360405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b1515611c0257600080fd5b5af11515611c0f57600080fd5b505050604051805190501515611c2157fe5b5050565b600160a060020a03331660009081526003602052604090205460ff161515611c4c57600080fd5b62015180811115611c5c57600080fd5b600e55565b600f54600090819033600160a060020a03908116911614611c8157600080fd5b611c8e83620186a0611fd0565b600160a060020a038516600090815260096020526040902054909150611cb49082611fac565b600160a060020a038516600090815260096020526040902055600854611cda9082611fac565b6008557f90890809c654f11d6e72a28fa60149770a0d11ec6c92319d6ceb2bb0a4ea1a15848460006040518084600160a060020a0316600160a060020a03168152602001838152602001828152602001935050505060405180910390a15060019392505050565b600160a060020a03331660009081526003602052604081205460ff161515611d6857600080fd5b50600754620186a0900460008111611d7c57fe5b611d8d600754620186a08302611f9a565b600755600254600054600160a060020a039182169163a9059cbb91168360405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b1515611ded57600080fd5b5af11515611dfa57600080fd5b505050604051805190501515611e0c57fe5b50565b60005433600160a060020a03908116911614611e2a57600080fd5b6000600155565b60055481565b600080600188888860405180848051906020019060200280838360005b83811015611e6c578082015183820152602001611e54565b50505050905001838051906020019060200280838360005b83811015611e9c578082015183820152602001611e84565b50505050905001828051906020019060200280838360005b83811015611ecc578082015183820152602001611eb4565b50505050905001935050505060405180910390208686866040516000815260200160405260405193845260ff9092166020808501919091526040808501929092526060840192909252608090920191516020810390808403906000865af11515611f3557600080fd5b505060206040510351600160a060020a03331660009081526003602052604090205490915060ff1615611f6a57809150611f8f565b600160a060020a03811660009081526003602052604090205460ff16156101ea573391505b509695505050505050565b600082821115611fa657fe5b50900390565b6000828201838110801590611fc15750828110155b1515611fc957fe5b9392505050565b6000828202831580611fc15750828482811515611fe957fe5b0414611fc957fe5b600080357bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916815260066020526040812054600554633b9aca009161203d916120379190611fd0565b3a611fd0565b81151561204657fe5b04905090565b600154151561205f5762278d0042016001555b42600154108061206d575080155b15611e0c57600254600054600160a060020a039182169163a9059cbb9116826370a082313060405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b15156120d057600080fd5b5af115156120dd57600080fd5b5050506040518051905060405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b151561212a57600080fd5b5af1151561213757600080fd5b50505060405180515050600054600160a060020a0316ff5b600160a060020a038416600090815260106020526040812080549091906001608060020a039081169085161161218457600080fd5b815461219e9087908790608060020a9004600f0b86612376565b90506040805190810160409081526001608060020a0386168252600f87900b602080840191909152600160a060020a0389166000908152601090915220815181546fffffffffffffffffffffffffffffffff19166001608060020a039190911617815560208201518154600f9190910b6001608060020a03908116608060020a029116179055507fbbddc02bfa2e7cedacea185a3820c053215b120e102dd6de97b11d4ba8897ab886858784876040518086600160a060020a0316600160a060020a03168152602001856001608060020a03166001608060020a0316815260200184600f0b600f0b81526020018381526020018281526020019550505050505060405180910390a1505050505050565b600160a060020a03331660009081526003602052604081205460ff161561236a5760018686604051608060020a600f93840b90930b830281526001608060020a03909116909102601082015260200160405180910390208585856040516000815260200160405260405193845260ff9092166020808501919091526040808501929092526060840192909252608090920191516020810390808403906000865af1151561235a57600080fd5b505060206040510351905061236d565b50335b95945050505050565b600080600061238b86600f0b86600f0b612466565b92506123978385612466565b915060008212156123f957816000190290506123b560085482611f9a565b600855600160a060020a0387166000908152600960205260409020546123db9082611f9a565b600160a060020a03881660009081526009602052604090205561245c565b508080620186a0612408610af6565b021161241057fe5b61241c60085482611fac565b600855600160a060020a0387166000908152600960205260409020546124429082611fac565b600160a060020a0388166000908152600960205260409020555b5050949350505050565b6000808212156124815781830383901361247c57fe5b611fa6565b81830383901315611fa657fe00a165627a7a7230582010adc13c966227d3bfc7ddbbac28967494f2d5e138e036293b4275ca8402c7510029

Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)

00000000000000000000000015f08079310e2c9dacaa73c0e450368185724aea00000000000000000000000008711d3b02c8758f2fb3ab4e80228418a7f8e39c0000000000000000000000000000000000000000000000000000000008f0d1800000000000000000000000000000000000000000000000000000000000000073

-----Decoded View---------------
Arg [0] : predecessorAddress (address): 0x15F08079310E2c9DacaA73c0e450368185724aEa
Arg [1] : tokenContract (address): 0x08711D3B02C8758F2FB3ab4e80228418a7F8e39c
Arg [2] : depositLimit (uint256): 150000000
Arg [3] : kGasPrice (uint256): 115

-----Encoded View---------------
4 Constructor Arguments found :
Arg [0] : 00000000000000000000000015f08079310e2c9dacaa73c0e450368185724aea
Arg [1] : 00000000000000000000000008711d3b02c8758f2fb3ab4e80228418a7f8e39c
Arg [2] : 0000000000000000000000000000000000000000000000000000000008f0d180
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000073


Swarm Source

bzzr://10adc13c966227d3bfc7ddbbac28967494f2d5e138e036293b4275ca8402c751

Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading
Loading...
Loading

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
Loading...
Loading
[ Download: CSV Export  ]

A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.