Sponsored Link:   Trade.io - The Exchange You've Been Waiting For Has Arrived. Instant Verification, Fully Customizable. Pre-Register today
Contract Overview | IDEX_1
ETH Balance: 33,386.906640572714107923 Ether
ETH USD Value: $21,520,866.15 (@ $644.59/ETH)
No Of Transactions: 1534070 txns
Misc  
   
Address Watch Add To Watch List
Contract Creator 0x33daedabab9085bd1a94460a652e7ffff592dfe3at txn 0x24b99bebf8a908be3d09bb8101446350cc7d1bea467b5242352c9c53e85c5283
Token Balances
  Latest 25 txns from a total Of 1534070 transactions (> more than 25 PendingTxns) View All

TxHash Age From To Value [TxFee]
0x64bd588d1ea36d28f25bbdc392c245a875ee38e8ba7f331afa5acb6f49a96347(pending) 1 sec ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0x258cd964656d61b38072b211f7a2b975141cb0cd4c1df1ddc52e7a1d1f8d81c5(pending) 1 sec ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0xc729be0e3a59527ce8810f9a6f195898650a54f6b50431d685376c8291c0cd47(pending) 10 secs ago0x834d80c17ed93fb163544c5bcbf128de5052a977  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0x5af325fd09c7648b01fda55b81856d1e5136c76a0a75c06e785901e3fe363a25(pending) 17 secs ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0xa653053f19158549ef3e0082f8861d727e11d2e4681d5ea0cfd8ff43af14211e(pending) 17 secs ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0xdc9fd68767616708c45cb2822ac5ae79883550ebc9dba5ea3dcf0835dea9c557(pending) 26 secs ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0x2281143dc17592baaac95fcd6f07f67ce93ab95cc280585026d71f26a49652b4(pending) 26 secs ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0xf59402d8e94568f4bbfa9e4276b006876ae426ce4ad489df1844f261f211fc8e(pending) 26 secs ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0x6ccc4caa6cd41b2da4c7c5efb8cb7b7e0c19731835a94a80598118bbd0728781(pending) 27 secs ago0xa41c6288546f245220e655b54856cc5b0aa0796b  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0x560847cb5a659c8127c16ef1d034d43294fbdc807c6edc8b9e760bdb5df352a1(pending) 42 secs ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0x6ecb5b92743defce8ad506178ccf6d7a96803376382151bf6fa0ddaad9fd1ae5(pending) 50 secs ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0x65f4a378df82a7dc67089093394fe0ffca89874514db8c8371679a6e7df8e080(pending) 50 secs ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0x5609e01e9f20df85b808e9aff56c0d3e2f5e0969be4cfff8a43dc826b4fd60e5(pending) 50 secs ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0x7093e1f097277980f76027f459a241a2227cad6b440102a64dc1d727cc0153a0(pending) 58 secs ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0xe7d789e3bb6e1f23cef855c925d7e924b12824fdd0e40b3c14bd993d0faeb1a8(pending) 58 secs ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0x19d0aba55d515f98744d0526aa2f8f2d3c06df7d457da6bec5bfad6887e173ed(pending) 58 secs ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0xd75ddc20b6ff9a31c7ed30b350fc40361e5f7ae487749e5c2ffc64e71bfcc8d7(pending) 58 secs ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0xd2ad4966ef583357fd4badc02e325b6d4079e72e77bbdb9abd1e2d27d442aaa8(pending)1 min ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0xc64e2753966debde70e1fb0f8d53c8841857a21fca65a503a9e289e400d75c18(pending)1 min ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0xe0940b9db0f129639e381a52df7a4de5b41e32ee30cfe6344aa338c99c9a27a2(pending)1 min ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0x1939073ed634dc6f41e930ed361c5cba959f27ab4148c871e4d58a354a8bb1c9(pending)1 min ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0x1cbe806024f8587b245d656568beaa0a8a8c23257318278954cf92726ec11fbe(pending)1 min ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0xab78f42e0514f586e5d241aa2b243037be28026a6695e83f1eefe90dc5fdc450(pending)1 min ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0x8bd2966d9885e90bf934d9ea2d9d1c9d066a983cc898d72100aa0e3ea018b83b(pending)1 min ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
0xd295e671e464fe6ab41af6bd60f295bf5778c0b48c1d93dbd96a93be4faa2ebb(pending)1 min ago0xceceaa8edc0830c7cec497e33bb3a3c28dd55a32  IN  0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080 Ether(pending)
 Internal Transactions as a result of Contract Execution
  Latest 25 Internal Txns, Click here to View More View All
ParentTxHash Block Age From To Value
0x162c6c236cc7284344f350075f396aeee34602ef9bccbbe386bb8f36cd600bcb54924894 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x63d2987d951bb4051e71bf99cb51b800c90bff630.257319052693190666 Ether
0xadd698cabe0ca8fc39a1dc5d4bb3914d6ba37848d65b58ba913ca2c884d4331954924884 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x82195e4c74d8f8959b938d718aebe91a12442f9a0.192119290515784083 Ether
0x7ccd74c0abdd358c8fc846cf3df10231f976b03c38716a542f3a2f0906a4a15054924884 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x2ed6df1357170123c896432b30998a0231d3f2840.276622500000000001 Ether
0xd3f450d9a3fa6038db883e6cb0cf95e207f2026a4a78e8c7d34dc5f2af3dcac554924865 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080xe1b43cc3706760496fc2c985fc3e8341884e7cb30.9994 Ether
0x7d27a208764e55863be987356d2433ebd14e39e6308cf7a53aa7b52c6762f9ca54924835 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x5cbbbbb70bd0833a210ae6ef092b5048b882fcb011.9994 Ether
0xabab34b34e6597ea3e43648b3468b4bba23dc708dbc85bb34b7841a7ae04f57654924835 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x6b8492215c7fb3590c3b5642743d113311e17e0e5.978414999999999996 Ether
0xa7cd5bd37812cd1529dab9c41878700f8659bd03d91dbc8cc52f2feed97c26fc54924835 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x8adb07faa9dbc0c0ff3715f40dece4a4e7ee8c481.003395 Ether
0x56fcfb4111414b1eeacf92ad9e88152c68d6a80f187186601b7615c230ef031c54924835 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x3923a5802160719fe3e4f53afce92920a21d258e15.340154036278496695 Ether
0xef86a498d70af82e78e407d6b10fd2fb07d400361adfe0edd1d4f241f59bac3b54924835 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x1800194c8ab5d2d816fe36c706a8e5e0645e26681.213009212893224144 Ether
0x2da55902880f6568ff0a33d21f7eae391f12dc3c350bf908f4799ce52511dd7354924835 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080xf2da64cf36e390957a912ae04342ebf70857ebac5.724238515754509716 Ether
0xa35c337f6413d30bd5279441d881e4a8fae91aee2927a4359a0615a3843e68a154924787 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080xf36de67d4501b5d3e3a972e32ce597f555ac14ba5.079394687932874505 Ether
0x9d9e29bc2b3fef1799eeecbb04851fdfb55b07a4b3b194e48ce89e90de5f673a54924787 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x6facedb3e7ce14511b6f8f6100b154d09514ba225.179969933707174615 Ether
0xcaa8564bea83c3c0eda9af3f23120dcf9e764b0829688b3a8bb5d9e442d2e33e54924768 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080xfa3100b28683ef859c42b5788924c0fc08de74900.9194 Ether
0xef5e93be2952f2fb62eddd6b860e2ae1201a609a980ffc82df07d0ef0c45b19d54924699 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x1d8c2a71845eeed129073758e259d3ec9be81a354.9994 Ether
0x9b7bbfe804713af6b86d61b3aeca751e84d3be58080fe87b73e58f37070fc26254924699 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080xcda7bb0054810e4dc18c098e779f666c74831d990.391152580292048045 Ether
0xf309c50b6dad2afcfb8a929d29996d6f1fe6e25040695bce8b99877db14b818054924699 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x2672d3996829d8d41e776f1494cd142c424018ba16.494955906287662544 Ether
0x00be993cfbd1209d67eedcecf5e5a325492dc5bf4721504b44c783dc1cd42cb0549246510 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x193c82b46c5c5dac522e18ad0d64c91abea4ebec1.0425033605 Ether
0xa9b108ba8c4fc42ea1fdddedf848f65cbdcfe55b84e6ad1fe02bde1214476d55549246211 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x89f534fde0f4b7701cacc31c5af27f9e7a02974c0.189187061368321788 Ether
0x1c7cffcbd820d66735c4221312ed095759c38d6aa3d61d7886dfc5f613403278549246211 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080xb7f18dd1d6bc1b0f9252973144d947910a5920640.299400000000000001 Ether
0x56fc955c13de7887fb9fee14861274b36629f6eb36a08fc96cacd3c3e5128a85549246012 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x70ee3353f7329dd3fc5b8533dc28cbbeea5ccfd55.990129868087222495 Ether
0xc2b0b57151da1534b85a27415b6a589d2a3cd1c8fcbb31e004b221192ee5c56c549246012 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x039304ca810d5a6ce087365ae4ddc837923472c41.160957999363596319 Ether
0xec879fac96b72f105b2aa9d928f9857438fe266f7f2721a93f41b66f5364d780549245912 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080xacf14ab404274b72e919f22ae4638f52797833a31.088310000000000001 Ether
0x6f446b6da77ceec026bf6429a010d1cf4664e5554595e4453f744947c42b46f9549245912 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080xad8cf288102fc8cf350fe0a4b0ac74ce094cece39.2994 Ether
0xc66437f853ae19bd12d25a3ff39ea3ac0b6bf36a737fa10d21570ea4e41e3b77549245712 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x6cad98fb07a26a2b5226dd2a8c24724e3368c1c80.513497416765578085 Ether
0x96126bc8ddfbe98faf119902d247459ed29c2158424e2074928bb74690162b44549245513 mins ago0x2a0c0dbecc7e4d658f48e01e3fa353f44050c2080x86f6e74730a472ec0135e8b76345635a7e2de6ef1.00635501 Ether
[ Download CSV Export  ] 
Warning: The compiled contract might be susceptible to ZeroFunctionSelector (very low-severity) Solidity compiler bugs.

Contract Source Code Verified (Exact match)
Contract Name: Exchange
Compiler Version: v0.4.16+commit.d7661dd9
Optimization Enabled: Yes
Runs (Optimiser):  200



  Contract Source Code   Find Similiar Contracts
pragma solidity ^0.4.16;

contract Token {
    bytes32 public standard;
    bytes32 public name;
    bytes32 public symbol;
    uint256 public totalSupply;
    uint8 public decimals;
    bool public allowTransactions;
    mapping (address => uint256) public balanceOf;
    mapping (address => mapping (address => uint256)) public allowance;
    function transfer(address _to, uint256 _value) returns (bool success);
    function approveAndCall(address _spender, uint256 _value, bytes _extraData) returns (bool success);
    function approve(address _spender, uint256 _value) returns (bool success);
    function transferFrom(address _from, address _to, uint256 _value) returns (bool success);
}

contract Exchange {
  function assert(bool assertion) {
    if (!assertion) throw;
  }
  function safeMul(uint a, uint b) returns (uint) {
    uint c = a * b;
    assert(a == 0 || c / a == b);
    return c;
  }

  function safeSub(uint a, uint b) returns (uint) {
    assert(b <= a);
    return a - b;
  }

  function safeAdd(uint a, uint b) returns (uint) {
    uint c = a + b;
    assert(c>=a && c>=b);
    return c;
  }
  address public owner;
  mapping (address => uint256) public invalidOrder;
  event SetOwner(address indexed previousOwner, address indexed newOwner);
  modifier onlyOwner {
    assert(msg.sender == owner);
    _;
  }
  function setOwner(address newOwner) onlyOwner {
    SetOwner(owner, newOwner);
    owner = newOwner;
  }
  function getOwner() returns (address out) {
    return owner;
  }
  function invalidateOrdersBefore(address user, uint256 nonce) onlyAdmin {
    if (nonce < invalidOrder[user]) throw;
    invalidOrder[user] = nonce;
  }

  mapping (address => mapping (address => uint256)) public tokens; //mapping of token addresses to mapping of account balances

  mapping (address => bool) public admins;
  mapping (address => uint256) public lastActiveTransaction;
  mapping (bytes32 => uint256) public orderFills;
  address public feeAccount;
  uint256 public inactivityReleasePeriod;
  mapping (bytes32 => bool) public traded;
  mapping (bytes32 => bool) public withdrawn;
  event Order(address tokenBuy, uint256 amountBuy, address tokenSell, uint256 amountSell, uint256 expires, uint256 nonce, address user, uint8 v, bytes32 r, bytes32 s);
  event Cancel(address tokenBuy, uint256 amountBuy, address tokenSell, uint256 amountSell, uint256 expires, uint256 nonce, address user, uint8 v, bytes32 r, bytes32 s);
  event Trade(address tokenBuy, uint256 amountBuy, address tokenSell, uint256 amountSell, address get, address give);
  event Deposit(address token, address user, uint256 amount, uint256 balance);
  event Withdraw(address token, address user, uint256 amount, uint256 balance);

  function setInactivityReleasePeriod(uint256 expiry) onlyAdmin returns (bool success) {
    if (expiry > 1000000) throw;
    inactivityReleasePeriod = expiry;
    return true;
  }

  function Exchange(address feeAccount_) {
    owner = msg.sender;
    feeAccount = feeAccount_;
    inactivityReleasePeriod = 100000;
  }

  function setAdmin(address admin, bool isAdmin) onlyOwner {
    admins[admin] = isAdmin;
  }

  modifier onlyAdmin {
    if (msg.sender != owner && !admins[msg.sender]) throw;
    _;
  }

  function() external {
    throw;
  }

  function depositToken(address token, uint256 amount) {
    tokens[token][msg.sender] = safeAdd(tokens[token][msg.sender], amount);
    lastActiveTransaction[msg.sender] = block.number;
    if (!Token(token).transferFrom(msg.sender, this, amount)) throw;
    Deposit(token, msg.sender, amount, tokens[token][msg.sender]);
  }

  function deposit() payable {
    tokens[address(0)][msg.sender] = safeAdd(tokens[address(0)][msg.sender], msg.value);
    lastActiveTransaction[msg.sender] = block.number;
    Deposit(address(0), msg.sender, msg.value, tokens[address(0)][msg.sender]);
  }

  function withdraw(address token, uint256 amount) returns (bool success) {
    if (safeSub(block.number, lastActiveTransaction[msg.sender]) < inactivityReleasePeriod) throw;
    if (tokens[token][msg.sender] < amount) throw;
    tokens[token][msg.sender] = safeSub(tokens[token][msg.sender], amount);
    if (token == address(0)) {
      if (!msg.sender.send(amount)) throw;
    } else {
      if (!Token(token).transfer(msg.sender, amount)) throw;
    }
    Withdraw(token, msg.sender, amount, tokens[token][msg.sender]);
  }

  function adminWithdraw(address token, uint256 amount, address user, uint256 nonce, uint8 v, bytes32 r, bytes32 s, uint256 feeWithdrawal) onlyAdmin returns (bool success) {
    bytes32 hash = keccak256(this, token, amount, user, nonce);
    if (withdrawn[hash]) throw;
    withdrawn[hash] = true;
    if (ecrecover(keccak256("\x19Ethereum Signed Message:\n32", hash), v, r, s) != user) throw;
    if (feeWithdrawal > 50 finney) feeWithdrawal = 50 finney;
    if (tokens[token][user] < amount) throw;
    tokens[token][user] = safeSub(tokens[token][user], amount);
    tokens[token][feeAccount] = safeAdd(tokens[token][feeAccount], safeMul(feeWithdrawal, amount) / 1 ether);
    amount = safeMul((1 ether - feeWithdrawal), amount) / 1 ether;
    if (token == address(0)) {
      if (!user.send(amount)) throw;
    } else {
      if (!Token(token).transfer(user, amount)) throw;
    }
    lastActiveTransaction[user] = block.number;
    Withdraw(token, user, amount, tokens[token][user]);
  }

  function balanceOf(address token, address user) constant returns (uint256) {
    return tokens[token][user];
  }

  function trade(uint256[8] tradeValues, address[4] tradeAddresses, uint8[2] v, bytes32[4] rs) onlyAdmin returns (bool success) {
    /* amount is in amountBuy terms */
    /* tradeValues
       [0] amountBuy
       [1] amountSell
       [2] expires
       [3] nonce
       [4] amount
       [5] tradeNonce
       [6] feeMake
       [7] feeTake
     tradeAddressses
       [0] tokenBuy
       [1] tokenSell
       [2] maker
       [3] taker
     */
    if (invalidOrder[tradeAddresses[2]] > tradeValues[3]) throw;
    bytes32 orderHash = keccak256(this, tradeAddresses[0], tradeValues[0], tradeAddresses[1], tradeValues[1], tradeValues[2], tradeValues[3], tradeAddresses[2]);
    if (ecrecover(keccak256("\x19Ethereum Signed Message:\n32", orderHash), v[0], rs[0], rs[1]) != tradeAddresses[2]) throw;
    bytes32 tradeHash = keccak256(orderHash, tradeValues[4], tradeAddresses[3], tradeValues[5]); 
    if (ecrecover(keccak256("\x19Ethereum Signed Message:\n32", tradeHash), v[1], rs[2], rs[3]) != tradeAddresses[3]) throw;
    if (traded[tradeHash]) throw;
    traded[tradeHash] = true;
    if (tradeValues[6] > 100 finney) tradeValues[6] = 100 finney;
    if (tradeValues[7] > 100 finney) tradeValues[7] = 100 finney;
    if (safeAdd(orderFills[orderHash], tradeValues[4]) > tradeValues[0]) throw;
    if (tokens[tradeAddresses[0]][tradeAddresses[3]] < tradeValues[4]) throw;
    if (tokens[tradeAddresses[1]][tradeAddresses[2]] < (safeMul(tradeValues[1], tradeValues[4]) / tradeValues[0])) throw;
    tokens[tradeAddresses[0]][tradeAddresses[3]] = safeSub(tokens[tradeAddresses[0]][tradeAddresses[3]], tradeValues[4]);
    tokens[tradeAddresses[0]][tradeAddresses[2]] = safeAdd(tokens[tradeAddresses[0]][tradeAddresses[2]], safeMul(tradeValues[4], ((1 ether) - tradeValues[6])) / (1 ether));
    tokens[tradeAddresses[0]][feeAccount] = safeAdd(tokens[tradeAddresses[0]][feeAccount], safeMul(tradeValues[4], tradeValues[6]) / (1 ether));
    tokens[tradeAddresses[1]][tradeAddresses[2]] = safeSub(tokens[tradeAddresses[1]][tradeAddresses[2]], safeMul(tradeValues[1], tradeValues[4]) / tradeValues[0]);
    tokens[tradeAddresses[1]][tradeAddresses[3]] = safeAdd(tokens[tradeAddresses[1]][tradeAddresses[3]], safeMul(safeMul(((1 ether) - tradeValues[7]), tradeValues[1]), tradeValues[4]) / tradeValues[0] / (1 ether));
    tokens[tradeAddresses[1]][feeAccount] = safeAdd(tokens[tradeAddresses[1]][feeAccount], safeMul(safeMul(tradeValues[7], tradeValues[1]), tradeValues[4]) / tradeValues[0] / (1 ether));
    orderFills[orderHash] = safeAdd(orderFills[orderHash], tradeValues[4]);
    lastActiveTransaction[tradeAddresses[2]] = block.number;
    lastActiveTransaction[tradeAddresses[3]] = block.number;
  }
}

    Contract ABI  
[{"constant":false,"inputs":[{"name":"assertion","type":"bool"}],"name":"assert","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"newOwner","type":"address"}],"name":"setOwner","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"token","type":"address"},{"name":"amount","type":"uint256"},{"name":"user","type":"address"},{"name":"nonce","type":"uint256"},{"name":"v","type":"uint8"},{"name":"r","type":"bytes32"},{"name":"s","type":"bytes32"},{"name":"feeWithdrawal","type":"uint256"}],"name":"adminWithdraw","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"lastActiveTransaction","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"token","type":"address"},{"name":"amount","type":"uint256"}],"name":"depositToken","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"bytes32"}],"name":"withdrawn","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"admins","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"admin","type":"address"},{"name":"isAdmin","type":"bool"}],"name":"setAdmin","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"},{"name":"","type":"address"}],"name":"tokens","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"feeAccount","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"invalidOrder","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"getOwner","outputs":[{"name":"out","type":"address"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"a","type":"uint256"},{"name":"b","type":"uint256"}],"name":"safeSub","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"user","type":"address"},{"name":"nonce","type":"uint256"}],"name":"invalidateOrdersBefore","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"a","type":"uint256"},{"name":"b","type":"uint256"}],"name":"safeMul","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"deposit","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"bytes32"}],"name":"traded","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"expiry","type":"uint256"}],"name":"setInactivityReleasePeriod","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"a","type":"uint256"},{"name":"b","type":"uint256"}],"name":"safeAdd","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"tradeValues","type":"uint256[8]"},{"name":"tradeAddresses","type":"address[4]"},{"name":"v","type":"uint8[2]"},{"name":"rs","type":"bytes32[4]"}],"name":"trade","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"inactivityReleasePeriod","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"token","type":"address"},{"name":"amount","type":"uint256"}],"name":"withdraw","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"bytes32"}],"name":"orderFills","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"token","type":"address"},{"name":"user","type":"address"}],"name":"balanceOf","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[{"name":"feeAccount_","type":"address"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"payable":false,"stateMutability":"nonpayable","type":"fallback"},{"anonymous":false,"inputs":[{"indexed":true,"name":"previousOwner","type":"address"},{"indexed":true,"name":"newOwner","type":"address"}],"name":"SetOwner","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"tokenBuy","type":"address"},{"indexed":false,"name":"amountBuy","type":"uint256"},{"indexed":false,"name":"tokenSell","type":"address"},{"indexed":false,"name":"amountSell","type":"uint256"},{"indexed":false,"name":"expires","type":"uint256"},{"indexed":false,"name":"nonce","type":"uint256"},{"indexed":false,"name":"user","type":"address"},{"indexed":false,"name":"v","type":"uint8"},{"indexed":false,"name":"r","type":"bytes32"},{"indexed":false,"name":"s","type":"bytes32"}],"name":"Order","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"tokenBuy","type":"address"},{"indexed":false,"name":"amountBuy","type":"uint256"},{"indexed":false,"name":"tokenSell","type":"address"},{"indexed":false,"name":"amountSell","type":"uint256"},{"indexed":false,"name":"expires","type":"uint256"},{"indexed":false,"name":"nonce","type":"uint256"},{"indexed":false,"name":"user","type":"address"},{"indexed":false,"name":"v","type":"uint8"},{"indexed":false,"name":"r","type":"bytes32"},{"indexed":false,"name":"s","type":"bytes32"}],"name":"Cancel","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"tokenBuy","type":"address"},{"indexed":false,"name":"amountBuy","type":"uint256"},{"indexed":false,"name":"tokenSell","type":"address"},{"indexed":false,"name":"amountSell","type":"uint256"},{"indexed":false,"name":"get","type":"address"},{"indexed":false,"name":"give","type":"address"}],"name":"Trade","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"token","type":"address"},{"indexed":false,"name":"user","type":"address"},{"indexed":false,"name":"amount","type":"uint256"},{"indexed":false,"name":"balance","type":"uint256"}],"name":"Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"token","type":"address"},{"indexed":false,"name":"user","type":"address"},{"indexed":false,"name":"amount","type":"uint256"},{"indexed":false,"name":"balance","type":"uint256"}],"name":"Withdraw","type":"event"}]

  Contract Creation Code Switch To Opcodes View
6060604052341561000f57600080fd5b604051602080611d0c833981016040528080519150505b60008054600160a060020a03338116600160a060020a0319928316179092556006805492841692909116919091179055620186a06007555b505b611c9d8061006f6000396000f3006060604052361561012d5763ffffffff60e060020a6000350416630674763c811461014057806313af40351461015a5780632295115b1461017b578063254dcfe2146101ca578063338b5dea146101fb5780633823d66c1461021f578063429b62e5146102495780634b0bddd21461027c578063508493bc146102a257806365e17c9d146102d957806383dbb27b14610308578063893d20e8146103395780638da5cb5b14610368578063a293d1e814610397578063b12de559146103c2578063d05c78da146103e6578063d0e30db014610411578063d58133231461041b578063dd93c74a14610445578063e6cb90131461046f578063ef3435881461049a578063f31174ee14610566578063f3fef3a31461058b578063f7213db6146105c1578063f7888aec146105e9575b341561013857600080fd5b5b600080fd5b005b341561014b57600080fd5b61013e6004351515610620565b005b341561016557600080fd5b61013e600160a060020a0360043516610630565b005b341561018657600080fd5b6101b6600160a060020a03600435811690602435906044351660643560ff6084351660a43560c43560e4356106b4565b604051901515815260200160405180910390f35b34156101d557600080fd5b6101e9600160a060020a0360043516610ad9565b60405190815260200160405180910390f35b341561020657600080fd5b61013e600160a060020a0360043516602435610aeb565b005b341561022a57600080fd5b6101b6600435610c62565b604051901515815260200160405180910390f35b341561025457600080fd5b6101b6600160a060020a0360043516610c77565b604051901515815260200160405180910390f35b341561028757600080fd5b61013e600160a060020a03600435166024351515610c8c565b005b34156102ad57600080fd5b6101e9600160a060020a0360043581169060243516610cd1565b60405190815260200160405180910390f35b34156102e457600080fd5b6102ec610cee565b604051600160a060020a03909116815260200160405180910390f35b341561031357600080fd5b6101e9600160a060020a0360043516610cfd565b60405190815260200160405180910390f35b341561034457600080fd5b6102ec610d0f565b604051600160a060020a03909116815260200160405180910390f35b341561037357600080fd5b6102ec610d1f565b604051600160a060020a03909116815260200160405180910390f35b34156103a257600080fd5b6101e9600435602435610d2e565b60405190815260200160405180910390f35b34156103cd57600080fd5b61013e600160a060020a0360043516602435610d47565b005b34156103f157600080fd5b6101e9600435602435610dcf565b60405190815260200160405180910390f35b61013e610dfe565b005b341561042657600080fd5b6101b6600435610eea565b604051901515815260200160405180910390f35b341561045057600080fd5b6101b6600435610eff565b604051901515815260200160405180910390f35b341561047a57600080fd5b6101e9600435602435610f61565b60405190815260200160405180910390f35b34156104a557600080fd5b6101b6600461010481600861010060405190810160405291908282610100808284378201915050505050919080608001906004806020026040519081016040529190828260808082843782019150505050509190806040019060028060200260405190810160405280929190826002602002808284378201915050505050919080608001906004806020026040519081016040529190828260808082843750939550610f89945050505050565b604051901515815260200160405180910390f35b341561057157600080fd5b6101e9611a1a565b60405190815260200160405180910390f35b341561059657600080fd5b6101b6600160a060020a0360043516602435611a20565b604051901515815260200160405180910390f35b34156105cc57600080fd5b6101e9600435611c32565b60405190815260200160405180910390f35b34156105f457600080fd5b6101e9600160a060020a0360043581169060243516611c44565b60405190815260200160405180910390f35b80151561062c57600080fd5b5b50565b60005461064b9033600160a060020a03908116911614610620565b600054600160a060020a0380831691167fcbf985117192c8f614a58aaf97226bb80a754772f5f6edf06f87c675f2e6c66360405160405180910390a36000805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0383161790555b5b50565b60008054819033600160a060020a039081169116148015906106ef5750600160a060020a03331660009081526003602052604090205460ff16155b156106f957600080fd5b308a8a8a8a6040516c01000000000000000000000000600160a060020a039687168102825294861685026014820152602881019390935293169091026048820152605c810191909152607c0160405190819003902060008181526009602052604090205490915060ff161561076d57600080fd5b60008181526009602052604090819020805460ff19166001908117909155600160a060020a038a16918390517f19457468657265756d205369676e6564204d6573736167653a0a3332000000008152601c810191909152603c0160405180910390208888886040516000815260200160405260006040516020015260405193845260ff90921660208085019190915260408085019290925260608401929092526080909201915160208103908084039060008661646e5a03f1151561083157600080fd5b505060206040510351600160a060020a03161461084d57600080fd5b66b1a2bc2ec500008311156108675766b1a2bc2ec5000092505b600160a060020a03808b166000908152600260209081526040808320938c16835292905220548990101561089a57600080fd5b600160a060020a03808b166000908152600260209081526040808320938c16835292905220546108ca908a610d2e565b600160a060020a038b811660009081526002602090815260408083208d85168452909152808220939093556006549091168152205461092590670de0b6b3a7640000610916868d610dcf565b81151561091f57fe5b04610f61565b600160a060020a03808c16600090815260026020908152604080832060065490941683529290522055670de0b6b3a76400006109638482038b610dcf565b81151561096c57fe5b049850600160a060020a038a1615156109b557600160a060020a03881689156108fc028a604051600060405180830381858888f1935050505015156109b057600080fd5b610a38565b89600160a060020a031663a9059cbb898b60006040516020015260405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b1515610a1257600080fd5b6102c65a03f11515610a2357600080fd5b505050604051805190501515610a3857600080fd5b5b600160a060020a038089166000818152600460209081526040808320439055938e1682526002815283822092825291909152819020547ff341246adaac6f497bc2a656f546ab9e182111d630394f0c57c710a59a2cb567918c918b918d919051600160a060020a0394851681529290931660208301526040808301919091526060820192909252608001905180910390a15b5b5098975050505050505050565b60046020526000908152604090205481565b600160a060020a0380831660009081526002602090815260408083203390941683529290522054610b1c9082610f61565b600160a060020a0380841660008181526002602090815260408083203395861684528252808320959095556004905283812043905590926323b872dd92913091869190516020015260405160e060020a63ffffffff8616028152600160a060020a0393841660048201529190921660248201526044810191909152606401602060405180830381600087803b1515610bb357600080fd5b6102c65a03f11515610bc457600080fd5b505050604051805190501515610bd957600080fd5b600160a060020a03808316600090815260026020908152604080832033948516845290915290819020547fdcbc1c05240f31ff3ad067ef1ee35ce4997762752e3a095284754544f4c709d79285929091859151600160a060020a0394851681529290931660208301526040808301919091526060820192909252608001905180910390a15b5050565b60096020526000908152604090205460ff1681565b60036020526000908152604090205460ff1681565b600054610ca79033600160a060020a03908116911614610620565b600160a060020a0382166000908152600360205260409020805460ff19168215151790555b5b5050565b600260209081526000928352604080842090915290825290205481565b600654600160a060020a031681565b60016020526000908152604090205481565b600054600160a060020a03165b90565b600054600160a060020a031681565b6000610d3c83831115610620565b508082035b92915050565b60005433600160a060020a03908116911614801590610d7f5750600160a060020a03331660009081526003602052604090205460ff16155b15610d8957600080fd5b600160a060020a038216600090815260016020526040902054811015610dae57600080fd5b600160a060020a03821660009081526001602052604090208190555b5b5050565b6000828202610df3841580610dee5750838583811515610deb57fe5b04145b610620565b8091505b5092915050565b33600160a060020a031660009081527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b6020526040902054610e409034610f61565b33600160a060020a03811660008181527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b60208181526040808420968755600482528084204390559383525292547fdcbc1c05240f31ff3ad067ef1ee35ce4997762752e3a095284754544f4c709d793929134919051600160a060020a0394851681529290931660208301526040808301919091526060820192909252608001905180910390a15b565b60086020526000908152604090205460ff1681565b6000805433600160a060020a03908116911614801590610f385750600160a060020a03331660009081526003602052604090205460ff16155b15610f4257600080fd5b620f4240821115610f5257600080fd5b50600781905560015b5b919050565b6000828201610df3848210801590610dee5750838210155b610620565b8091505b5092915050565b600080548190819033600160a060020a03908116911614801590610fc65750600160a060020a03331660009081526003602052604090205460ff16155b15610fd057600080fd5b8660035b6020020151600160008860025b6020020151600160a060020a0316600160a060020a0316815260200190815260200160002054111561101257600080fd5b308660005b60200201518860005b60200201518860015b60200201518a60015b60200201518b60025b60200201518c60035b60200201518c60025b60200201516040516c01000000000000000000000000600160a060020a03998a168102825297891688026014820152602881019690965293871686026048860152605c850192909252607c840152609c8301529092160260bc82015260d00160405190819003902091508560025b6020020151600160a060020a03166001836040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000008152601c810191909152603c016040519081900390208760005b60200201518760005b60200201518860015b60200201516040516000815260200160405260006040516020015260405193845260ff90921660208085019190915260408085019290925260608401929092526080909201915160208103908084039060008661646e5a03f1151561118057600080fd5b505060206040510351600160a060020a03161461119c57600080fd5b818760045b60200201518760035b60200201518960055b60200201516040519384526020840192909252600160a060020a03166c010000000000000000000000000260408084019190915260548301919091526074909101905190819003902090508560035b6020020151600160a060020a03166001826040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000008152601c810191909152603c016040519081900390208760015b60200201518760025b60200201518860035b60200201516040516000815260200160405260006040516020015260405193845260ff90921660208085019190915260408085019290925260608401929092526080909201915160208103908084039060008661646e5a03f115156112c757600080fd5b505060206040510351600160a060020a0316146112e357600080fd5b60008181526008602052604090205460ff16156112ff57600080fd5b6000818152600860205260409020805460ff1916600117905567016345785d8a00008760065b602002015111156113435767016345785d8a00008760065b60200201525b67016345785d8a00008760075b6020020151111561136e5767016345785d8a00008760075b60200201525b8660005b6020020151600083815260056020526040902054611398908960045b6020020151610f61565b11156113a357600080fd5b8660045b60200201516002600088815b6020020151600160a060020a0316815260208101919091526040016000908120908860035b6020020151600160a060020a0316600160a060020a0316815260200190815260200160002054101561140957600080fd5b8660005b602002015161142c8860015b60200201518960045b6020020151610dcf565b81151561143557fe5b04600260008860015b6020020151600160a060020a0316815260208101919091526040016000908120908860025b6020020151600160a060020a0316600160a060020a0316815260200190815260200160002054101561149457600080fd5b6114f06002600088815b6020020151600160a060020a0316815260208101919091526040016000908120908860035b6020020151600160a060020a031681526020810191909152604001600020548860045b6020020151610d2e565b6002600088815b6020020151600160a060020a0316815260208101919091526040016000908120908860035b6020020151600160a060020a0316815260208101919091526040016000908120919091556115ca9060029088815b6020020151600160a060020a0316815260208101919091526040016000908120908860025b6020020151600160a060020a03168152602081019190915260400160002054670de0b6b3a76400006109168a60045b60200201518b60065b6020020151670de0b6b3a764000003610dcf565b81151561091f57fe5b04610f61565b6002600088815b6020020151600160a060020a0316815260208101919091526040016000908120908860025b6020020151600160a060020a03168152602081019190915260400160009081209190915561168c9060029088815b6020020151600160a060020a0390811682526020808301939093526040918201600090812060065490921681529252902054670de0b6b3a76400006109168a60045b60200201518b6006611422565b6020020151610dcf565b81151561091f57fe5b04610f61565b6002600088815b6020020151600160a060020a039081168252602080830193909352604091820160009081206006549092168152925281209190915561174f906002908860015b6020020151600160a060020a0316815260208101919091526040016000908120908860025b6020020151600160a060020a0316815260208101919091526040016000908120549089905b60200201516117408a60015b60200201518b6004611422565b6020020151610dcf565b81151561174957fe5b04610d2e565b600260008860015b6020020151600160a060020a0316815260208101919091526040016000908120908860025b6020020151600160a060020a03168152602081019190915260400160009081209190915561185a906002908860015b6020020151600160a060020a0316815260208101919091526040016000908120908860035b6020020151600160a060020a03168152602081019190915260400160009081205490670de0b6b3a7640000908a905b602002015161184161182f8c60075b6020020151670de0b6b3a7640000038d6001611422565b6020020151610dcf565b8c6004611422565b6020020151610dcf565b81151561184a57fe5b0481151561091f57fe5b04610f61565b600260008860015b6020020151600160a060020a0316815260208101919091526040016000908120908860035b6020020151600160a060020a031681526020810191909152604001600090812091909155611947906002908860015b6020020151600160a060020a039081168252602080830193909352604091820160009081206006549092168152925281205490670de0b6b3a7640000908a905b602002015161184161182f8c60075b60200201518d6001611422565b6020020151610dcf565b8c6004611422565b6020020151610dcf565b81151561184a57fe5b0481151561091f57fe5b04610f61565b600260008860015b6020020151600160a060020a0390811682526020808301939093526040918201600090812060065490921681529083528181209390935584835260059091529020546119a79088600461138e565b6020020151610f61565b60008381526005602052604081209190915543906004908860025b6020020151600160a060020a03168152602081019190915260400160009081209190915543906004908860035b6020020151600160a060020a031681526020810191909152604001600020555b5b5050949350505050565b60075481565b600754600160a060020a033316600090815260046020526040812054909190611a4a904390610d2e565b1015611a5557600080fd5b600160a060020a038084166000908152600260209081526040808320339094168352929052205482901015611a8957600080fd5b600160a060020a0380841660009081526002602090815260408083203390941683529290522054611aba9083610d2e565b600160a060020a03808516600081815260026020908152604080832033909516835293905291909120919091551515611b2357600160a060020a03331682156108fc0283604051600060405180830381858888f193505050501515611b1e57600080fd5b611ba6565b82600160a060020a031663a9059cbb338460006040516020015260405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b1515611b8057600080fd5b6102c65a03f11515611b9157600080fd5b505050604051805190501515611ba657600080fd5b5b600160a060020a03808416600090815260026020908152604080832033948516845290915290819020547ff341246adaac6f497bc2a656f546ab9e182111d630394f0c57c710a59a2cb5679286929091869151600160a060020a0394851681529290931660208301526040808301919091526060820192909252608001905180910390a15b92915050565b60056020526000908152604090205481565b600160a060020a038083166000908152600260209081526040808320938516835292905220545b929150505600a165627a7a7230582011e441ee389dad20321e055f3c597af6c5b1c374e4c13ea473f285fc075e8dbc0029000000000000000000000000034767f3c519f361c5ecf46ebfc08981c629d381

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

-----Decoded View---------------
Found 1 constructor arguments :
Arg [0] : 000000000000000000000000034767f3c519f361c5ecf46ebfc08981c629d381


   Swarm Source:
bzzr://11e441ee389dad20321e055f3c597af6c5b1c374e4c13ea473f285fc075e8dbc

 

View All
Block Age txn Difficulty GasUsed Reward
View All
Block Age UncleNumber Difficulty GasUsed Reward
Make sure to use the "downvote" button for any spammy posts, and the "upvote" for interesting conversations.