More Info
Private Name Tags
ContractCreator
Latest 25 from a total of 45,302 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Upgrade | 11602280 | 1484 days ago | IN | 0 ETH | 0.01424356 | ||||
Submit | 11602232 | 1484 days ago | IN | 0 ETH | 0.02631249 | ||||
Submit | 11602193 | 1484 days ago | IN | 0 ETH | 0.02648505 | ||||
Submit | 11602154 | 1484 days ago | IN | 0 ETH | 0.02342908 | ||||
Submit | 11602116 | 1484 days ago | IN | 0 ETH | 0.02088244 | ||||
Submit | 11602077 | 1484 days ago | IN | 0 ETH | 0.01851916 | ||||
Submit | 11602025 | 1484 days ago | IN | 0 ETH | 0.01595894 | ||||
Submit | 11601987 | 1484 days ago | IN | 0 ETH | 0.01222387 | ||||
Submit | 11601948 | 1484 days ago | IN | 0 ETH | 0.01239364 | ||||
Submit | 11601910 | 1484 days ago | IN | 0 ETH | 0.01222257 | ||||
Submit | 11601871 | 1484 days ago | IN | 0 ETH | 0.01103544 | ||||
Submit | 11601833 | 1484 days ago | IN | 0 ETH | 0.01162965 | ||||
Submit | 11601795 | 1484 days ago | IN | 0 ETH | 0.021222 | ||||
Submit | 11601757 | 1484 days ago | IN | 0 ETH | 0.0248552 | ||||
Set Upgrade Oper... | 11601635 | 1484 days ago | IN | 0 ETH | 0.00624114 | ||||
Submit | 11601585 | 1484 days ago | IN | 0 ETH | 0.01766179 | ||||
Submit | 11600496 | 1484 days ago | IN | 0 ETH | 0.01205409 | ||||
Submit | 11599394 | 1485 days ago | IN | 0 ETH | 0.01544961 | ||||
Submit | 11598353 | 1485 days ago | IN | 0 ETH | 0.01714737 | ||||
Submit | 11597281 | 1485 days ago | IN | 0 ETH | 0.01443096 | ||||
Submit | 11596172 | 1485 days ago | IN | 0 ETH | 0.0127332 | ||||
Submit | 11595072 | 1485 days ago | IN | 0 ETH | 0.01842069 | ||||
Submit | 11593981 | 1485 days ago | IN | 0 ETH | 0.01171454 | ||||
Submit | 11592886 | 1486 days ago | IN | 0 ETH | 0.01918468 | ||||
Submit | 11591827 | 1486 days ago | IN | 0 ETH | 0.02801304 |
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Source Code Verified (Exact Match)
Contract Name:
SpotLogic
Compiler Version
v0.5.12+commit.7709ece9
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity)
/** *Submitted for verification at Etherscan.io on 2019-11-14 */ // File: contracts/common/Validating.sol pragma solidity 0.5.12; interface Validating { modifier notZero(uint number) { require(number > 0, "invalid 0 value"); _; } modifier notEmpty(string memory text) { require(bytes(text).length > 0, "invalid empty string"); _; } modifier validAddress(address value) { require(value != address(0x0), "invalid address"); _; } } // File: contracts/external/MerkleProof.sol pragma solidity 0.5.12; /// @notice can use a deployed https://github.com/OpenZeppelin/openzeppelin-solidity/blob/master/contracts/cryptography/MerkleProof.sol contract MerkleProof { /** * Verifies the inclusion of a leaf in a Merkle tree using a Merkle proof. * Based on https://github.com/ameensol/merkle-tree-solidity/src/MerkleProof.sol */ function checkProof(bytes memory proof, bytes32 root, bytes32 leaf) public pure returns (bool) { if (proof.length % 32 != 0) return false; // Check if proof is made of bytes32 slices bytes memory elements = proof; bytes32 element; bytes32 hash = leaf; for (uint i = 32; i <= proof.length; i += 32) { assembly { // Load the current element of the proofOfInclusion (optimal way to get a bytes32 slice) element := mload(add(elements, i)) } hash = keccak256(abi.encodePacked(hash < element ? abi.encodePacked(hash, element) : abi.encodePacked(element, hash))); } return hash == root; } // from StorJ -- https://github.com/nginnever/storj-audit-verifier/contracts/MerkleVerifyv3.sol function checkProofOrdered(bytes memory proof, bytes32 root, bytes32 leaf, uint index) public pure returns (bool) { if (proof.length % 32 != 0) return false; // Check if proof is made of bytes32 slices // use the index to determine the node ordering (index ranges 1 to n) bytes32 element; bytes32 hash = leaf; uint remaining; for (uint j = 32; j <= proof.length; j += 32) { assembly { element := mload(add(proof, j)) } // calculate remaining elements in proof remaining = (proof.length - j + 32) / 32; // we don't assume that the tree is padded to a power of 2 // if the index is odd then the proof will start with a hash at a higher layer, // so we have to adjust the index to be the index at that layer while (remaining > 0 && index % 2 == 1 && index > 2 ** remaining) { index = uint(index) / 2 + 1; } if (index % 2 == 0) { hash = keccak256(abi.encodePacked(abi.encodePacked(element, hash))); index = index / 2; } else { hash = keccak256(abi.encodePacked(abi.encodePacked(hash, element))); index = uint(index) / 2 + 1; } } return hash == root; } /** Verifies the inclusion of a leaf in a Merkle tree using a Merkle proof */ function verifyIncluded(bytes memory proof, bytes32 root, bytes32 leaf) public pure returns (bool) { return checkProof(proof, root, leaf); } /** Verifies the inclusion of a leaf is at a specific place in an ordered Merkle tree using a Merkle proof */ function verifyIncludedAtIndex(bytes memory proof, bytes32 root, bytes32 leaf, uint index) public pure returns (bool) { return checkProofOrdered(proof, root, leaf, index); } } // File: contracts/external/Token.sol pragma solidity 0.5.12; /* * Abstract contract for the full ERC 20 Token standard * https://github.com/ethereum/EIPs/issues/20 */ contract Token { /** This is a slight change to the ERC20 base standard. function totalSupply() view returns (uint supply); is replaced map: uint public totalSupply; This automatically creates a getter function for the totalSupply. This is moved to the base contract since public getter functions are not currently recognised as an implementation of the matching abstract function by the compiler. */ /// total amount of tokens uint public totalSupply; /// @param _owner The address from which the balance will be retrieved /// @return The balance function balanceOf(address _owner) public view returns (uint balance); /// @notice send `_value` token to `_to` from `msg.sender` /// @param _to The address of the recipient /// @param _value The amount of token to be transferred /// @return Whether the transfer was successful or not function transfer(address _to, uint _value) public returns (bool success); /// @notice send `_value` token to `_to` from `_from` on the condition it is approved by `_from` /// @param _from The address of the sender /// @param _to The address of the recipient /// @param _value The amount of token to be transferred /// @return Whether the transfer was successful or not function transferFrom(address _from, address _to, uint _value) public returns (bool success); /// @notice `msg.sender` approves `_spender` to spend `_value` tokens /// @param _spender The address of the account able to transfer the tokens /// @param _value The amount of tokens to be approved for transfer /// @return Whether the approval was successful or not function approve(address _spender, uint _value) public returns (bool success); /// @param _owner The address of the account owning tokens /// @param _spender The address of the account able to transfer the tokens /// @return Amount of remaining tokens allowed to spent function allowance(address _owner, address _spender) public view returns (uint remaining); event Transfer(address indexed _from, address indexed _to, uint _value); event Approval(address indexed _owner, address indexed _spender, uint _value); } // File: contracts/gluon/AppGovernance.sol pragma solidity 0.5.12; interface AppGovernance { function approve(uint32 id) external; function disapprove(uint32 id) external; function activate(uint32 id) external; } // File: contracts/gluon/AppLogic.sol pragma solidity 0.5.12; interface AppLogic { function upgrade() external; function credit(address account, address asset, uint quantity) external; function debit(address account, bytes calldata parameters) external returns (address asset, uint quantity); } // File: contracts/gluon/AppState.sol pragma solidity 0.5.12; contract AppState { enum State { OFF, ON, RETIRED } State public state = State.ON; event Off(); event Retired(); modifier whenOn() { require(state == State.ON, "must be on"); _; } modifier whenOff() { require(state == State.OFF, "must be off"); _; } modifier whenRetired() { require(state == State.RETIRED, "must be retired"); _; } function retire_() internal whenOn { state = State.RETIRED; emit Retired(); } function switchOff_() internal whenOn { state = State.OFF; emit Off(); } function isOn() external view returns (bool) { return state == State.ON; } } // File: contracts/gluon/GluonView.sol pragma solidity 0.5.12; interface GluonView { function app(uint32 id) external view returns (address current, address proposal, uint activationBlock); function current(uint32 id) external view returns (address); function history(uint32 id) external view returns (address[] memory); function getBalance(uint32 id, address asset) external view returns (uint); function isAnyLogic(uint32 id, address logic) external view returns (bool); function isAppOwner(uint32 id, address appOwner) external view returns (bool); function proposals(address logic) external view returns (bool); function totalAppsCount() external view returns(uint32); } // File: contracts/gluon/GluonCentric.sol pragma solidity 0.5.12; contract GluonCentric { uint32 internal constant REGISTRY_INDEX = 0; uint32 internal constant STAKE_INDEX = 1; uint32 public id; address public gluon; constructor(uint32 id_, address gluon_) public { id = id_; gluon = gluon_; } modifier onlyCurrentLogic { require(currentLogic() == msg.sender, "invalid sender; must be current logic contract"); _; } modifier onlyGluon { require(gluon == msg.sender, "invalid sender; must be gluon contract"); _; } modifier onlyOwner { require(GluonView(gluon).isAppOwner(id, msg.sender), "invalid sender; must be app owner"); _; } function currentLogic() public view returns (address) { return GluonView(gluon).current(id); } } // File: contracts/apps/registry/RegistryData.sol pragma solidity 0.5.12; contract RegistryData is GluonCentric { mapping(address => address) public accounts; constructor(address gluon) GluonCentric(REGISTRY_INDEX, gluon) public { } function addKey(address apiKey, address account) external onlyCurrentLogic { accounts[apiKey] = account; } } // File: contracts/gluon/Upgrading.sol pragma solidity 0.5.12; contract Upgrading { address public upgradeOperator; modifier onlyOwner { require(false, "modifier onlyOwner must be implemented"); _; } modifier onlyUpgradeOperator { require(upgradeOperator == msg.sender, "invalid sender; must be upgrade operator"); _; } function setUpgradeOperator(address upgradeOperator_) external onlyOwner { upgradeOperator = upgradeOperator_; } function upgrade_(AppGovernance appGovernance, uint32 id) internal { appGovernance.activate(id); delete upgradeOperator; } } // File: contracts/apps/registry/RegistryLogic.sol pragma solidity 0.5.12; contract RegistryLogic is Upgrading, Validating, AppLogic, AppState, GluonCentric { RegistryData public data; OldRegistry public old; event Registered(address apiKey, address indexed account); constructor(address gluon, address old_, address data_) GluonCentric(REGISTRY_INDEX, gluon) public { data = RegistryData(data_); old = OldRegistry(old_); } modifier isAbsent(address apiKey) { require(translate(apiKey) == address (0x0), "api key already in use"); _; } function register(address apiKey) external whenOn validAddress(apiKey) isAbsent(apiKey) { data.addKey(apiKey, msg.sender); emit Registered(apiKey, msg.sender); } function translate(address apiKey) public view returns (address) { address account = data.accounts(apiKey); if (account == address(0x0)) account = old.translate(apiKey); return account; } /**************************************************** AppLogic ****************************************************/ function upgrade() external onlyUpgradeOperator { retire_(); upgrade_(AppGovernance(gluon), id); } function credit(address, address, uint) external { revert("not supported"); } function debit(address, bytes calldata) external returns (address, uint) { revert("not supported"); } function switchOff() external onlyOwner { uint32 totalAppsCount = GluonView(gluon).totalAppsCount(); for (uint32 i = 2; i < totalAppsCount; i++) { AppState appState = AppState(GluonView(gluon).current(i)); require(!appState.isOn(), "One of the apps is still ON"); } switchOff_(); } } contract OldRegistry { function translate(address) public view returns (address); } // File: contracts/common/EvmTypes.sol pragma solidity 0.5.12; contract EvmTypes { uint constant internal ADDRESS = 20; uint constant internal UINT8 = 1; uint constant internal UINT32 = 4; uint constant internal UINT64 = 8; uint constant internal UINT128 = 16; uint constant internal UINT256 = 32; uint constant internal BYTES32 = 32; uint constant internal SIGNATURE_BYTES = 65; } // File: contracts/external/BytesLib.sol /* * @title Solidity Bytes Arrays Utils * @author Gonçalo Sá <[email protected]> * * @dev Bytes tightly packed arrays utility library for ethereum contracts written in Solidity. * The library lets you concatenate, slice and type cast bytes arrays both in memory and storage. */ pragma solidity 0.5.12; library BytesLib { function concat( bytes memory _preBytes, bytes memory _postBytes ) internal pure returns (bytes memory) { bytes memory tempBytes; assembly { // Get a location of some free memory and store it in tempBytes as // Solidity does for memory variables. tempBytes := mload(0x40) // Store the length of the first bytes array at the beginning of // the memory for tempBytes. let length := mload(_preBytes) mstore(tempBytes, length) // Maintain a memory counter for the current write location in the // temp bytes array by adding the 32 bytes for the array length to // the starting location. let mc := add(tempBytes, 0x20) // Stop copying when the memory counter reaches the length of the // first bytes array. let end := add(mc, length) for { // Initialize a copy counter to the start of the _preBytes data, // 32 bytes into its memory. let cc := add(_preBytes, 0x20) } lt(mc, end) { // Increase both counters by 32 bytes each iteration. mc := add(mc, 0x20) cc := add(cc, 0x20) } { // Write the _preBytes data into the tempBytes memory 32 bytes // at a time. mstore(mc, mload(cc)) } // Add the length of _postBytes to the current length of tempBytes // and store it as the new length in the first 32 bytes of the // tempBytes memory. length := mload(_postBytes) mstore(tempBytes, add(length, mload(tempBytes))) // Move the memory counter back from a multiple of 0x20 to the // actual end of the _preBytes data. mc := end // Stop copying when the memory counter reaches the new combined // length of the arrays. end := add(mc, length) for { let cc := add(_postBytes, 0x20) } lt(mc, end) { mc := add(mc, 0x20) cc := add(cc, 0x20) } { mstore(mc, mload(cc)) } // Update the free-memory pointer by padding our last write location // to 32 bytes: add 31 bytes to the end of tempBytes to move to the // next 32 byte block, then round down to the nearest multiple of // 32. If the sum of the length of the two arrays is zero then add // one before rounding down to leave a blank 32 bytes (the length block with 0). mstore(0x40, and( add(add(end, iszero(add(length, mload(_preBytes)))), 31), not(31) // Round down to the nearest 32 bytes. )) } return tempBytes; } function concatStorage(bytes storage _preBytes, bytes memory _postBytes) internal { assembly { // Read the first 32 bytes of _preBytes storage, which is the length // of the array. (We don't need to use the offset into the slot // because arrays use the entire slot.) let fslot := sload(_preBytes_slot) // Arrays of 31 bytes or less have an even value in their slot, // while longer arrays have an odd value. The actual length is // the slot divided by two for odd values, and the lowest order // byte divided by two for even values. // If the slot is even, bitwise and the slot with 255 and divide by // two to get the length. If the slot is odd, bitwise and the slot // with -1 and divide by two. let slength := div(and(fslot, sub(mul(0x100, iszero(and(fslot, 1))), 1)), 2) let mlength := mload(_postBytes) let newlength := add(slength, mlength) // slength can contain both the length and contents of the array // if length < 32 bytes so let's prepare for that // v. http://solidity.readthedocs.io/en/latest/miscellaneous.html#layout-of-state-variables-in-storage switch add(lt(slength, 32), lt(newlength, 32)) case 2 { // Since the new array still fits in the slot, we just need to // update the contents of the slot. // uint256(bytes_storage) = uint256(bytes_storage) + uint256(bytes_memory) + new_length sstore( _preBytes_slot, // all the modifications to the slot are inside this // next block add( // we can just add to the slot contents because the // bytes we want to change are the LSBs fslot, add( mul( div( // load the bytes from memory mload(add(_postBytes, 0x20)), // zero all bytes to the right exp(0x100, sub(32, mlength)) ), // and now shift left the number of bytes to // leave space for the length in the slot exp(0x100, sub(32, newlength)) ), // increase length by the double of the memory // bytes length mul(mlength, 2) ) ) ) } case 1 { // The stored value fits in the slot, but the combined value // will exceed it. // get the keccak hash to get the contents of the array mstore(0x0, _preBytes_slot) let sc := add(keccak256(0x0, 0x20), div(slength, 32)) // save new length sstore(_preBytes_slot, add(mul(newlength, 2), 1)) // The contents of the _postBytes array start 32 bytes into // the structure. Our first read should obtain the `submod` // bytes that can fit into the unused space in the last word // of the stored array. To get this, we read 32 bytes starting // from `submod`, so the data we read overlaps with the array // contents by `submod` bytes. Masking the lowest-order // `submod` bytes allows us to add that value directly to the // stored value. let submod := sub(32, slength) let mc := add(_postBytes, submod) let end := add(_postBytes, mlength) let mask := sub(exp(0x100, submod), 1) sstore( sc, add( and( fslot, 0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ), and(mload(mc), mask) ) ) for { mc := add(mc, 0x20) sc := add(sc, 1) } lt(mc, end) { sc := add(sc, 1) mc := add(mc, 0x20) } { sstore(sc, mload(mc)) } mask := exp(0x100, sub(mc, end)) sstore(sc, mul(div(mload(mc), mask), mask)) } default { // get the keccak hash to get the contents of the array mstore(0x0, _preBytes_slot) // Start copying to the last used word of the stored array. let sc := add(keccak256(0x0, 0x20), div(slength, 32)) // save new length sstore(_preBytes_slot, add(mul(newlength, 2), 1)) // Copy over the first `submod` bytes of the new data as in // case 1 above. let slengthmod := mod(slength, 32) let mlengthmod := mod(mlength, 32) let submod := sub(32, slengthmod) let mc := add(_postBytes, submod) let end := add(_postBytes, mlength) let mask := sub(exp(0x100, submod), 1) sstore(sc, add(sload(sc), and(mload(mc), mask))) for { sc := add(sc, 1) mc := add(mc, 0x20) } lt(mc, end) { sc := add(sc, 1) mc := add(mc, 0x20) } { sstore(sc, mload(mc)) } mask := exp(0x100, sub(mc, end)) sstore(sc, mul(div(mload(mc), mask), mask)) } } } function slice( bytes memory _bytes, uint _start, uint _length ) internal pure returns (bytes memory) { require(_bytes.length >= (_start + _length)); bytes memory tempBytes; assembly { switch iszero(_length) case 0 { // Get a location of some free memory and store it in tempBytes as // Solidity does for memory variables. tempBytes := mload(0x40) // The first word of the slice result is potentially a partial // word read from the original array. To read it, we calculate // the length of that partial word and start copying that many // bytes into the array. The first word we copy will start with // data we don't care about, but the last `lengthmod` bytes will // land at the beginning of the contents of the new array. When // we're done copying, we overwrite the full first word with // the actual length of the slice. let lengthmod := and(_length, 31) // The multiplication in the next line is necessary // because when slicing multiples of 32 bytes (lengthmod == 0) // the following copy loop was copying the origin's length // and then ending prematurely not copying everything it should. let mc := add(add(tempBytes, lengthmod), mul(0x20, iszero(lengthmod))) let end := add(mc, _length) for { // The multiplication in the next line has the same exact purpose // as the one above. let cc := add(add(add(_bytes, lengthmod), mul(0x20, iszero(lengthmod))), _start) } lt(mc, end) { mc := add(mc, 0x20) cc := add(cc, 0x20) } { mstore(mc, mload(cc)) } mstore(tempBytes, _length) // update free-memory pointer // allocating the array padded to 32 bytes like the compiler does now mstore(0x40, and(add(mc, 31), not(31))) } // if we want a zero-length slice let's just return a zero-length array default { tempBytes := mload(0x40) mstore(0x40, add(tempBytes, 0x20)) } } return tempBytes; } function toAddress(bytes memory _bytes, uint _start) internal pure returns (address) { require(_bytes.length >= (_start + 20)); address tempAddress; assembly { tempAddress := div(mload(add(add(_bytes, 0x20), _start)), 0x1000000000000000000000000) } return tempAddress; } function toUint8(bytes memory _bytes, uint _start) internal pure returns (uint8) { require(_bytes.length >= (_start + 1)); uint8 tempUint; assembly { tempUint := mload(add(add(_bytes, 0x1), _start)) } return tempUint; } function toUint16(bytes memory _bytes, uint _start) internal pure returns (uint16) { require(_bytes.length >= (_start + 2)); uint16 tempUint; assembly { tempUint := mload(add(add(_bytes, 0x2), _start)) } return tempUint; } function toUint32(bytes memory _bytes, uint _start) internal pure returns (uint32) { require(_bytes.length >= (_start + 4)); uint32 tempUint; assembly { tempUint := mload(add(add(_bytes, 0x4), _start)) } return tempUint; } function toUint64(bytes memory _bytes, uint _start) internal pure returns (uint64) { require(_bytes.length >= (_start + 8)); uint64 tempUint; assembly { tempUint := mload(add(add(_bytes, 0x8), _start)) } return tempUint; } function toUint96(bytes memory _bytes, uint _start) internal pure returns (uint96) { require(_bytes.length >= (_start + 12)); uint96 tempUint; assembly { tempUint := mload(add(add(_bytes, 0xc), _start)) } return tempUint; } function toUint128(bytes memory _bytes, uint _start) internal pure returns (uint128) { require(_bytes.length >= (_start + 16)); uint128 tempUint; assembly { tempUint := mload(add(add(_bytes, 0x10), _start)) } return tempUint; } function toUint(bytes memory _bytes, uint _start) internal pure returns (uint256) { require(_bytes.length >= (_start + 32)); uint256 tempUint; assembly { tempUint := mload(add(add(_bytes, 0x20), _start)) } return tempUint; } function toBytes32(bytes memory _bytes, uint _start) internal pure returns (bytes32) { require(_bytes.length >= (_start + 32)); bytes32 tempBytes32; assembly { tempBytes32 := mload(add(add(_bytes, 0x20), _start)) } return tempBytes32; } function equal(bytes memory _preBytes, bytes memory _postBytes) internal pure returns (bool) { bool success = true; assembly { let length := mload(_preBytes) // if lengths don't match the arrays are not equal switch eq(length, mload(_postBytes)) case 1 { // cb is a circuit breaker in the for loop since there's // no said feature for inline assembly loops // cb = 1 - don't breaker // cb = 0 - break let cb := 1 let mc := add(_preBytes, 0x20) let end := add(mc, length) for { let cc := add(_postBytes, 0x20) // the next line is the loop condition: // while(uint(mc < end) + cb == 2) } eq(add(lt(mc, end), cb), 2) { mc := add(mc, 0x20) cc := add(cc, 0x20) } { // if any of these checks fails then arrays are not equal if iszero(eq(mload(mc), mload(cc))) { // unsuccess: success := 0 cb := 0 } } } default { // unsuccess: success := 0 } } return success; } function equalStorage( bytes storage _preBytes, bytes memory _postBytes ) internal view returns (bool) { bool success = true; assembly { // we know _preBytes_offset is 0 let fslot := sload(_preBytes_slot) // Decode the length of the stored array like in concatStorage(). let slength := div(and(fslot, sub(mul(0x100, iszero(and(fslot, 1))), 1)), 2) let mlength := mload(_postBytes) // if lengths don't match the arrays are not equal switch eq(slength, mlength) case 1 { // slength can contain both the length and contents of the array // if length < 32 bytes so let's prepare for that // v. http://solidity.readthedocs.io/en/latest/miscellaneous.html#layout-of-state-variables-in-storage if iszero(iszero(slength)) { switch lt(slength, 32) case 1 { // blank the last byte which is the length fslot := mul(div(fslot, 0x100), 0x100) if iszero(eq(fslot, mload(add(_postBytes, 0x20)))) { // unsuccess: success := 0 } } default { // cb is a circuit breaker in the for loop since there's // no said feature for inline assembly loops // cb = 1 - don't breaker // cb = 0 - break let cb := 1 // get the keccak hash to get the contents of the array mstore(0x0, _preBytes_slot) let sc := keccak256(0x0, 0x20) let mc := add(_postBytes, 0x20) let end := add(mc, mlength) // the next line is the loop condition: // while(uint(mc < end) + cb == 2) for {} eq(add(lt(mc, end), cb), 2) { sc := add(sc, 1) mc := add(mc, 0x20) } { if iszero(eq(sload(sc), mload(mc))) { // unsuccess: success := 0 cb := 0 } } } } } default { // unsuccess: success := 0 } } return success; } } // File: contracts/apps/spot/WithDepositCommitmentRecord.sol pragma solidity 0.5.12; contract WithDepositCommitmentRecord is EvmTypes { using BytesLib for bytes; struct DepositCommitmentRecord { uint32 ledgerId; address account; address asset; uint quantity; uint32 nonce; uint32 designatedGblock; bytes32 hash; } uint constant private LEDGER_ID = 0; uint constant private ACCOUNT = LEDGER_ID + UINT32; uint constant private ASSET = ACCOUNT + ADDRESS; uint constant private QUANTITY = ASSET + ADDRESS; uint constant private NONCE = QUANTITY + UINT256; uint constant private DESIGNATED_GBLOCK = NONCE + UINT32; function parseDepositCommitmentRecord(bytes memory parameters) internal pure returns (DepositCommitmentRecord memory result) { result.ledgerId = parameters.toUint32(LEDGER_ID); result.account = parameters.toAddress(ACCOUNT); result.asset = parameters.toAddress(ASSET); result.quantity = parameters.toUint(QUANTITY); result.nonce = parameters.toUint32(NONCE); result.designatedGblock = parameters.toUint32(DESIGNATED_GBLOCK); result.hash = keccak256(encodePackedDeposit(result.ledgerId, result.account, result.asset, result.quantity, result.nonce, result.designatedGblock)); } function encodePackedDeposit(uint32 ledgerId, address account, address asset, uint quantity, uint32 nonce, uint32 designatedGblock) public pure returns(bytes memory) { return abi.encodePacked(ledgerId, account, asset, quantity, nonce, designatedGblock); } } // File: contracts/external/Cryptography.sol pragma solidity 0.5.12; contract Cryptography { /** * @dev Recover signer address from a message by using their signature * @param hash bytes32 message, the hash is the signed message. What is recovered is the signer address. * @param signature bytes generated using web3.eth.account.sign().signature * * Based on https://gist.github.com/axic/5b33912c6f61ae6fd96d6c4a47afde6d * TODO: Remove this library once solidity supports passing a signature to ecrecover. * See https://github.com/ethereum/solidity/issues/864 */ function recover(bytes32 hash, bytes memory signature) public pure returns (address) { bytes32 r; bytes32 s; uint8 v; if (signature.length != 65) return (address(0x0)); // Check the signature length // Divide the signature into r, s and v variables assembly { r := mload(add(signature, 32)) s := mload(add(signature, 64)) v := byte(0, mload(add(signature, 96))) } // Version of signature should be 27 or 28, but 0 and 1 are also possible versions if (v < 27) v += 27; // If the version is correct return the signer address return (v != 27 && v != 28) ? (address(0)) : ecrecover(hash, v, r, s); } } // File: contracts/apps/spot/WithEntry.sol pragma solidity 0.5.12; contract WithEntry is EvmTypes, Cryptography { using BytesLib for bytes; struct Entry { uint32 ledgerId; address account; address asset; EntryType entryType; uint8 action; uint timestamp; uint quantity; uint balance; uint previous; uint32 gblockNumber; bytes32 hash; bytes32 dataHash; bytes signature; address signer; bytes dataBytes; } uint constant private VERSION = 0; uint constant private LEDGER_ID = VERSION + UINT8; uint constant private ACCOUNT = LEDGER_ID + UINT32; uint constant private ASSET = ACCOUNT + ADDRESS; uint constant private ENTRY_TYPE = ASSET + ADDRESS; uint constant private ACTION = ENTRY_TYPE + UINT8; uint constant private TIMESTAMP = ACTION + UINT8; uint constant private QUANTITY = TIMESTAMP + UINT64; uint constant private BALANCE = QUANTITY + UINT256; uint constant private PREVIOUS = BALANCE + UINT256; uint constant private GBLOCK_NUMBER = PREVIOUS + UINT128; uint constant private DATA_HASH = GBLOCK_NUMBER + UINT32; uint constant private ENTRY_LENGTH = DATA_HASH + BYTES32; enum EntryType { Unknown, Origin, Deposit, Withdrawal, Exited, Trade, Fee } function parseEntry(bytes memory parameters, bytes memory signature) internal pure returns (Entry memory result) { result.ledgerId = parameters.toUint32(LEDGER_ID); result.account = parameters.toAddress(ACCOUNT); result.asset = parameters.toAddress(ASSET); result.entryType = EntryType(parameters.toUint8(ENTRY_TYPE)); result.action = parameters.toUint8(ACTION); result.timestamp = parameters.toUint64(TIMESTAMP); result.quantity = parameters.toUint(QUANTITY); result.balance = parameters.toUint(BALANCE); result.previous = parameters.toUint128(PREVIOUS); result.gblockNumber = parameters.toUint32(GBLOCK_NUMBER); result.dataHash = parameters.toBytes32(DATA_HASH); bytes memory entryBytes = parameters; if (parameters.length > ENTRY_LENGTH) { result.dataBytes = parameters.slice(ENTRY_LENGTH, parameters.length - ENTRY_LENGTH); require(result.dataHash == keccak256(result.dataBytes), "data hash mismatch"); entryBytes = parameters.slice(0, ENTRY_LENGTH); } result.hash = keccak256(entryBytes); result.signer = recover(result.hash, signature); } } // File: contracts/apps/spot/SpotData.sol pragma solidity 0.5.12; contract SpotData is GluonCentric { struct Gblock { bytes32 withdrawalsRoot; bytes32 depositsRoot; bytes32 balancesRoot; } uint32 public nonce = 0; uint32 public currentGblockNumber; uint public submissionBlock = block.number; mapping(uint32 => Gblock) public gblocksByNumber; mapping(bytes32 => bool) public deposits; mapping(bytes32 => bool) public withdrawn; mapping(bytes32 => uint) public exitClaims; // exit entry hash => confirmationThreshold mapping(address => mapping(address => bool)) public exited; // account => asset => has exited constructor(uint32 id, address gluon) GluonCentric(id, gluon) public { } function deposit(bytes32 hash) external onlyCurrentLogic { deposits[hash] = true; } function deleteDeposit(bytes32 hash) external onlyCurrentLogic { require(deposits[hash], "unknown deposit"); delete deposits[hash]; } function nextNonce() external onlyCurrentLogic returns (uint32) { return ++nonce; } function markExited(address account, address asset) external onlyCurrentLogic { exited[account][asset] = true; } function markWithdrawn(bytes32 hash) external onlyCurrentLogic {withdrawn[hash] = true;} function hasExited(address account, address asset) external view returns (bool) { return exited[account][asset]; } function hasWithdrawn(bytes32 hash) external view returns (bool) { return withdrawn[hash]; } function markExitClaim(bytes32 hash, uint confirmationThreshold) external onlyCurrentLogic { exitClaims[hash] = confirmationThreshold; } function deleteExitClaim(bytes32 hash) external onlyCurrentLogic { delete exitClaims[hash]; } function submit(uint32 gblockNumber, bytes32 withdrawalsRoot, bytes32 depositsRoot, bytes32 balancesRoot, uint submissionInterval) external onlyCurrentLogic { Gblock memory gblock = Gblock(withdrawalsRoot, depositsRoot, balancesRoot); gblocksByNumber[gblockNumber] = gblock; currentGblockNumber = gblockNumber; submissionBlock = block.number + submissionInterval; } function updateSubmissionBlock(uint submissionBlock_) external onlyCurrentLogic { submissionBlock = submissionBlock_; } function depositsRoot(uint32 gblockNumber) external view returns (bytes32) { return gblocksByNumber[gblockNumber].depositsRoot; } function withdrawalsRoot(uint32 gblockNumber) external view returns (bytes32) { return gblocksByNumber[gblockNumber].withdrawalsRoot; } function balancesRoot(uint32 gblockNumber) external view returns (bytes32) { return gblocksByNumber[gblockNumber].balancesRoot; } function isConfirmedGblock(uint32 gblockNumber) external view returns (bool) { return gblockNumber > 0 && gblockNumber < currentGblockNumber; } } // File: contracts/apps/spot/SpotLogic.sol pragma solidity 0.5.12; contract SpotLogic is Upgrading, Validating, MerkleProof, AppLogic, AppState, GluonCentric, WithDepositCommitmentRecord, WithEntry { struct ProofOfInclusionAtIndex { bytes32 leaf; uint index; bytes proof; } struct ProofOfExclusionOfDeposit { DepositCommitmentRecord excluded; ProofOfInclusionAtIndex predecessor; ProofOfInclusionAtIndex successor; } uint8 public constant confirmationDelay = 5; uint8 public constant visibilityDelay = 3; uint private constant ASSISTED_WITHDRAW = 1; uint private constant RECLAIM_DEPOSIT = 2; uint private constant CLAIM_EXIT = 3; uint private constant EXIT = 4; uint private constant EXIT_ON_HALT = 5; uint private constant RECLAIM_DEPOSIT_ON_HALT = 6; SpotData public data; address public operator; uint public submissionInterval; uint public abandonPoint; event Deposited(address indexed account, address indexed asset, uint quantity, uint32 nonce, uint32 designatedGblock); event DepositReclaimed(address indexed account, address indexed asset, uint quantity, uint32 nonce); event ExitClaimed(bytes32 hash, address indexed account, address indexed asset, uint quantity, uint timestamp, uint confirmationThreshold); event Exited(address indexed account, address indexed asset, uint quantity); event Withdrawn(bytes32 hash, address indexed account, address indexed asset, uint quantity); event Submitted(uint32 gblockNumber, bytes32 withdrawalsRoot, bytes32 depositsRoot, bytes32 balancesRoot); constructor(uint32 id, address gluon, address data_, address operator_, uint submissionInterval_, uint abandonPoint_) GluonCentric(id, gluon) public validAddress(gluon) validAddress(operator_) { operator = operator_; submissionInterval = submissionInterval_; data = SpotData(data_); abandonPoint = abandonPoint_; } /**************************************************** AppLogic ****************************************************/ function upgrade() external whenOn onlyUpgradeOperator { require(canSubmit(), "cannot upgrade yet"); retire_(); upgrade_(AppGovernance(gluon), id); } function credit(address account, address asset, uint quantity) external whenOn onlyGluon { require(!data.hasExited(account, asset), "previously exited"); uint32 nonce = data.nextNonce(); uint32 designatedGblock = data.currentGblockNumber() + visibilityDelay; bytes32 hash = keccak256(abi.encodePacked(id, account, asset, quantity, nonce, designatedGblock)); data.deposit(hash); emit Deposited(account, asset, quantity, nonce, designatedGblock); } function debit(address account, bytes calldata parameters) external onlyGluon returns (address asset, uint quantity) { uint action = parameters.toUint(0); if (action == ASSISTED_WITHDRAW) return assistedWithdraw(account, parameters); else if (action == RECLAIM_DEPOSIT) return reclaimDeposit(account, parameters); else if (action == CLAIM_EXIT) return claimExit(account, parameters); else if (action == EXIT) return exit(account, parameters); else if (action == EXIT_ON_HALT) return exitOnHalt(account, parameters); else if (action == RECLAIM_DEPOSIT_ON_HALT) return reclaimDepositOnHalt(account, parameters); else revert("invalid action"); } /**************************************************** Depositing ****************************************************/ function reclaimDeposit(address account, bytes memory parameters) private whenOn returns (address asset, uint quantity) { (, bytes memory entry_, bytes32[] memory leaves, uint[] memory indexes, bytes memory predecessor, bytes memory successor) = abi.decode(parameters, (uint, bytes, bytes32[], uint[], bytes, bytes)); ProofOfExclusionOfDeposit memory proof = extractProofOfExclusionOfDeposit(entry_, leaves, indexes, predecessor, successor); DepositCommitmentRecord memory record = proof.excluded; require(record.account == account, "claimant must be the original depositor"); require(data.currentGblockNumber() > record.designatedGblock && record.designatedGblock != 0, "designated gblock is unconfirmed or unknown"); require(proveIsExcludedFromDeposits(data.depositsRoot(record.designatedGblock), proof), "failed to proof exclusion of deposit"); return reclaimDeposit_(record); } function proveIsExcludedFromDeposits(bytes32 root, ProofOfExclusionOfDeposit memory proof) private pure returns (bool) { return proof.successor.index == proof.predecessor.index + 1 && // predecessor & successor must be consecutive proof.successor.leaf > proof.excluded.hash && proof.predecessor.leaf < proof.excluded.hash && verifyIncludedAtIndex(proof.predecessor.proof, root, proof.predecessor.leaf, proof.predecessor.index) && verifyIncludedAtIndex(proof.successor.proof, root, proof.successor.leaf, proof.successor.index); } function reclaimDepositOnHalt(address account, bytes memory parameters) private whenOff returns (address asset, uint quantity) { (, bytes memory commitmentRecord) = abi.decode(parameters, (uint, bytes)); DepositCommitmentRecord memory record = parseDepositCommitmentRecord(commitmentRecord); require(record.ledgerId == id, 'not from current ledger'); require(record.account == account, "claimant must be the original depositor"); require(record.designatedGblock >= data.currentGblockNumber(), "designated gblock is already confirmed; use exitOnHalt instead"); return reclaimDeposit_(record); } function encodedDepositOnHaltParameters(address account, address asset, uint quantity, uint32 nonce, uint32 designatedGblock) external view returns (bytes memory) { bytes memory encodedPackedDeposit = encodePackedDeposit(id, account, asset, quantity, nonce, designatedGblock); return abi.encode(RECLAIM_DEPOSIT_ON_HALT, encodedPackedDeposit); } function reclaimDeposit_(DepositCommitmentRecord memory record) private returns (address asset, uint quantity) { data.deleteDeposit(record.hash); emit DepositReclaimed(record.account, record.asset, record.quantity, record.nonce); return (record.asset, record.quantity); } function extractProofOfExclusionOfDeposit(bytes memory recordParameters, bytes32[] memory leaves, uint[] memory indexes, bytes memory predecessor, bytes memory successor) private view returns (ProofOfExclusionOfDeposit memory result) { result.excluded = parseDepositCommitmentRecord(recordParameters); require(result.excluded.ledgerId == id, 'not from current ledger'); result.predecessor = ProofOfInclusionAtIndex(leaves[0], indexes[0], predecessor); result.successor = ProofOfInclusionAtIndex(leaves[1], indexes[1], successor); } /**************************************************** Withdrawing ***************************************************/ function assistedWithdraw(address account, bytes memory parameters) private returns (address asset, uint quantity) { (, bytes memory entryBytes, bytes memory signature, bytes memory proof) = abi.decode(parameters, (uint, bytes, bytes, bytes)); Entry memory entry = parseAndValidateEntry(entryBytes, signature, account); require(entry.entryType == EntryType.Withdrawal, "entry must be of type Withdrawal"); require(proveInConfirmedWithdrawals(proof, entry.gblockNumber, entry.hash), "invalid entry proof"); require(!data.hasWithdrawn(entry.hash), "entry already withdrawn"); data.markWithdrawn(entry.hash); emit Withdrawn(entry.hash, entry.account, entry.asset, entry.quantity); return (entry.asset, entry.quantity); } function claimExit(address account, bytes memory parameters) private whenOn returns (address asset, uint quantity) { (, bytes memory entry_, bytes memory signature, bytes memory proof) = abi.decode(parameters, (uint, bytes, bytes, bytes)); Entry memory entry = parseAndValidateEntry(entry_, signature, account); require(!hasExited(entry.account, entry.asset), "previously exited"); require(proveInConfirmedBalances(proof, entry.hash), "invalid balance proof"); uint confirmationThreshold = data.currentGblockNumber() + confirmationDelay; data.markExitClaim(entry.hash, confirmationThreshold); emit ExitClaimed(entry.hash, entry.account, entry.asset, entry.balance, entry.timestamp, confirmationThreshold); return (entry.asset, 0); } function exit(address account, bytes memory parameters) private whenOn returns (address asset, uint quantity) { (, bytes memory entry_, bytes memory signature, bytes memory proof) = abi.decode(parameters, (uint, bytes, bytes, bytes)); Entry memory entry = parseAndValidateEntry(entry_, signature, account); require(!hasExited(entry.account, entry.asset), "previously exited"); require(canExit(entry.hash), "no prior claim found to withdraw OR balances are yet to be confirmed"); require(proveInUnconfirmedBalances(proof, entry.hash), "invalid balance proof"); data.deleteExitClaim(entry.hash); exit_(entry); return (entry.asset, entry.balance); } function exitOnHalt(address account, bytes memory parameters) private whenOff returns (address asset, uint quantity) { (, bytes memory entry_, bytes memory signature, bytes memory proof) = abi.decode(parameters, (uint, bytes, bytes, bytes)); Entry memory entry = parseAndValidateEntry(entry_, signature, account); require(!hasExited(entry.account, entry.asset), "previously exited"); require(proveInConfirmedBalances(proof, entry.hash), "invalid balance proof"); exit_(entry); return (entry.asset, entry.balance); } function exit_(Entry memory entry) private { data.markExited(entry.account, entry.asset); emit Exited(entry.account, entry.asset, entry.balance); } function hasExited(address account, address asset) public view returns (bool) { return data.hasExited(account, asset); } function canExit(bytes32 entryHash) public view returns (bool) { uint confirmationThreshold = data.exitClaims(entryHash); return confirmationThreshold != 0 && data.currentGblockNumber() >= confirmationThreshold; } /**************************************************** FraudProof ****************************************************/ function canSubmit() public view returns (bool) { return block.number > data.submissionBlock(); } function submit(uint32 gblockNumber, bytes32 withdrawalsRoot, bytes32 depositsRoot, bytes32 balancesRoot) public whenOn { require(canSubmit(), "cannot submit yet"); require(msg.sender == operator, "submitter must be the operator"); require(gblockNumber == data.currentGblockNumber() + 1, "gblock must be the next in sequence"); data.submit(gblockNumber, withdrawalsRoot, depositsRoot, balancesRoot, submissionInterval); emit Submitted(gblockNumber, withdrawalsRoot, depositsRoot, balancesRoot); } function proveInConfirmedWithdrawals(bytes memory proof, uint32 gblockNumber, bytes32 entryHash) public view returns (bool) { return data.isConfirmedGblock(gblockNumber) && verifyIncluded(proof, data.withdrawalsRoot(gblockNumber), entryHash); } function proveInConfirmedBalances(bytes memory proof, bytes32 entryHash) public view returns (bool) { uint32 gblockNumber = data.currentGblockNumber() - 1; return verifyIncluded(proof, data.balancesRoot(gblockNumber), entryHash); } function proveInUnconfirmedBalances(bytes memory proof, bytes32 entryHash) public view returns (bool) { uint32 gblockNumber = data.currentGblockNumber(); return verifyIncluded(proof, data.balancesRoot(gblockNumber), entryHash); } function parseAndValidateEntry(bytes memory entryBytes, bytes memory signature, address account) private view returns (Entry memory entry) { entry = parseEntry(entryBytes, signature); require(entry.ledgerId == id, 'entry is not from current ledger'); require(entry.signer == operator, "failed to verify signature"); require(entry.account == account, "entry account mismatch"); } /****************************************************** halting ******************************************************/ function hasBeenAbandoned() public view returns(bool) { return block.number > data.submissionBlock() + abandonPoint; } function abandon() external { require(hasBeenAbandoned(), "chain has not yet abandoned"); switchOff_(); } function switchOff() external onlyOwner { switchOff_(); } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"uint32","name":"id","type":"uint32"},{"internalType":"address","name":"gluon","type":"address"},{"internalType":"address","name":"data_","type":"address"},{"internalType":"address","name":"operator_","type":"address"},{"internalType":"uint256","name":"submissionInterval_","type":"uint256"},{"internalType":"uint256","name":"abandonPoint_","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"asset","type":"address"},{"indexed":false,"internalType":"uint256","name":"quantity","type":"uint256"},{"indexed":false,"internalType":"uint32","name":"nonce","type":"uint32"}],"name":"DepositReclaimed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"asset","type":"address"},{"indexed":false,"internalType":"uint256","name":"quantity","type":"uint256"},{"indexed":false,"internalType":"uint32","name":"nonce","type":"uint32"},{"indexed":false,"internalType":"uint32","name":"designatedGblock","type":"uint32"}],"name":"Deposited","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"hash","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"asset","type":"address"},{"indexed":false,"internalType":"uint256","name":"quantity","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"timestamp","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"confirmationThreshold","type":"uint256"}],"name":"ExitClaimed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"asset","type":"address"},{"indexed":false,"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"Exited","type":"event"},{"anonymous":false,"inputs":[],"name":"Off","type":"event"},{"anonymous":false,"inputs":[],"name":"Retired","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"gblockNumber","type":"uint32"},{"indexed":false,"internalType":"bytes32","name":"withdrawalsRoot","type":"bytes32"},{"indexed":false,"internalType":"bytes32","name":"depositsRoot","type":"bytes32"},{"indexed":false,"internalType":"bytes32","name":"balancesRoot","type":"bytes32"}],"name":"Submitted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"hash","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"asset","type":"address"},{"indexed":false,"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"Withdrawn","type":"event"},{"constant":false,"inputs":[],"name":"abandon","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"abandonPoint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"bytes32","name":"entryHash","type":"bytes32"}],"name":"canExit","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"canSubmit","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"bytes","name":"proof","type":"bytes"},{"internalType":"bytes32","name":"root","type":"bytes32"},{"internalType":"bytes32","name":"leaf","type":"bytes32"}],"name":"checkProof","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"pure","type":"function"},{"constant":true,"inputs":[{"internalType":"bytes","name":"proof","type":"bytes"},{"internalType":"bytes32","name":"root","type":"bytes32"},{"internalType":"bytes32","name":"leaf","type":"bytes32"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"checkProofOrdered","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"pure","type":"function"},{"constant":true,"inputs":[],"name":"confirmationDelay","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"address","name":"asset","type":"address"},{"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"credit","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"currentLogic","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"data","outputs":[{"internalType":"contract SpotData","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"bytes","name":"parameters","type":"bytes"}],"name":"debit","outputs":[{"internalType":"address","name":"asset","type":"address"},{"internalType":"uint256","name":"quantity","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"internalType":"uint32","name":"ledgerId","type":"uint32"},{"internalType":"address","name":"account","type":"address"},{"internalType":"address","name":"asset","type":"address"},{"internalType":"uint256","name":"quantity","type":"uint256"},{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint32","name":"designatedGblock","type":"uint32"}],"name":"encodePackedDeposit","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"payable":false,"stateMutability":"pure","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"address","name":"asset","type":"address"},{"internalType":"uint256","name":"quantity","type":"uint256"},{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint32","name":"designatedGblock","type":"uint32"}],"name":"encodedDepositOnHaltParameters","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"gluon","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"hasBeenAbandoned","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"address","name":"asset","type":"address"}],"name":"hasExited","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"id","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"isOn","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"operator","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"bytes","name":"proof","type":"bytes"},{"internalType":"bytes32","name":"entryHash","type":"bytes32"}],"name":"proveInConfirmedBalances","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"bytes","name":"proof","type":"bytes"},{"internalType":"uint32","name":"gblockNumber","type":"uint32"},{"internalType":"bytes32","name":"entryHash","type":"bytes32"}],"name":"proveInConfirmedWithdrawals","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"bytes","name":"proof","type":"bytes"},{"internalType":"bytes32","name":"entryHash","type":"bytes32"}],"name":"proveInUnconfirmedBalances","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"bytes32","name":"hash","type":"bytes32"},{"internalType":"bytes","name":"signature","type":"bytes"}],"name":"recover","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"pure","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"upgradeOperator_","type":"address"}],"name":"setUpgradeOperator","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"state","outputs":[{"internalType":"enum AppState.State","name":"","type":"uint8"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"submissionInterval","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"uint32","name":"gblockNumber","type":"uint32"},{"internalType":"bytes32","name":"withdrawalsRoot","type":"bytes32"},{"internalType":"bytes32","name":"depositsRoot","type":"bytes32"},{"internalType":"bytes32","name":"balancesRoot","type":"bytes32"}],"name":"submit","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"switchOff","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"upgrade","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"upgradeOperator","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"bytes","name":"proof","type":"bytes"},{"internalType":"bytes32","name":"root","type":"bytes32"},{"internalType":"bytes32","name":"leaf","type":"bytes32"}],"name":"verifyIncluded","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"pure","type":"function"},{"constant":true,"inputs":[{"internalType":"bytes","name":"proof","type":"bytes"},{"internalType":"bytes32","name":"root","type":"bytes32"},{"internalType":"bytes32","name":"leaf","type":"bytes32"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"verifyIncludedAtIndex","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"pure","type":"function"},{"constant":true,"inputs":[],"name":"visibilityDelay","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"payable":false,"stateMutability":"view","type":"function"}]
Contract Creation Code
60806040526000805460ff60a01b1916740100000000000000000000000000000000000000001790553480156200003557600080fd5b5060405162004c0538038062004c05833981810160405260c08110156200005b57600080fd5b508051602082015160408301516060840151608085015160a0909501516000805463ffffffff60a81b1916750100000000000000000000000000000000000000000063ffffffff881602179055600180546001600160a01b0319166001600160a01b038616908117909155949593949293919285906200013c57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600f60248201527f696e76616c696420616464726573730000000000000000000000000000000000604482015290519081900360640190fd5b836001600160a01b038116620001b357604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600f60248201527f696e76616c696420616464726573730000000000000000000000000000000000604482015290519081900360640190fd5b5050600380546001600160a01b039485166001600160a01b0319918216179091556004929092556002805494909316939091169290921790556005555050614a0480620002016000396000f3fe608060405234801561001057600080fd5b50600436106101fb5760003560e01c806373d4a13a1161011a578063b6ba5ae8116100ad578063d55ec6971161007c578063d55ec69714610a3d578063e1a41bcf14610a45578063e4e439f114610a4d578063fc5a948b14610af3578063ffbc9bd014610afb576101fb565b8063b6ba5ae8146108e1578063bab1f0d814610916578063bf0af1ba14610968578063c19d93fb14610a11576101fb565b806387cb37e3116100e957806387cb37e314610893578063883188341461089b578063985bcf34146108a3578063af640d0f146108c0576101fb565b806373d4a13a146107ac5780637de182c5146107b457806380de7f91146107ea578063853a7330146107f2576101fb565b806327869c57116101925780634878d26e116101615780634878d26e146106bb578063570ca735146106d557806358f4996f146106dd5780635f285ea614610786576101fb565b806327869c57146105275780632e8ff5bd1461052f57806338da5b071461054d57806345eedf00146105fc576101fb565b806319779b42116101ce57806319779b421461039c5780631a74d5361461044257806323a27bcd1461047057806325c99ae41461051f576101fb565b8063038d71ee146102005780630864e17c1461020a578063175bbecf146102cd57806319045a25146102d5575b600080fd5b610208610b03565b005b6102b96004803603606081101561022057600080fd5b810190602081018135600160201b81111561023a57600080fd5b82018360208201111561024c57600080fd5b803590602001918460018302840111600160201b8311171561026d57600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295505063ffffffff8335169350505060200135610bd4565b604080519115158252519081900360200190f35b6102b9610ceb565b610380600480360360408110156102eb57600080fd5b81359190810190604081016020820135600160201b81111561030c57600080fd5b82018360208201111561031e57600080fd5b803590602001918460018302840111600160201b8311171561033f57600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550610d0d945050505050565b604080516001600160a01b039092168252519081900360200190f35b6102b9600480360360408110156103b257600080fd5b810190602081018135600160201b8111156103cc57600080fd5b8201836020820111156103de57600080fd5b803590602001918460018302840111600160201b831117156103ff57600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295505091359250610ddb915050565b6102b96004803603604081101561045857600080fd5b506001600160a01b0381358116916020013516610ee9565b6102b96004803603608081101561048657600080fd5b810190602081018135600160201b8111156104a057600080fd5b8201836020820111156104b257600080fd5b803590602001918460018302840111600160201b831117156104d357600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295505082359350505060208101359060400135610f75565b61038061114c565b61038061115b565b61053761116a565b6040805160ff9092168252519081900360200190f35b6102b96004803603608081101561056357600080fd5b810190602081018135600160201b81111561057d57600080fd5b82018360208201111561058f57600080fd5b803590602001918460018302840111600160201b831117156105b057600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550508235935050506020810135906040013561116f565b610646600480360360a081101561061257600080fd5b506001600160a01b03813581169160208101359091169060408101359063ffffffff60608201358116916080013516611186565b6040805160208082528351818301528351919283929083019185019080838360005b83811015610680578181015183820152602001610668565b50505050905090810190601f1680156106ad5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6106c3611241565b60408051918252519081900360200190f35b610380611247565b6102b9600480360360608110156106f357600080fd5b810190602081018135600160201b81111561070d57600080fd5b82018360208201111561071f57600080fd5b803590602001918460018302840111600160201b8311171561074057600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295505082359350505060200135611256565b6102086004803603602081101561079c57600080fd5b50356001600160a01b0316611263565b61038061134c565b610208600480360360608110156107ca57600080fd5b506001600160a01b0381358116916020810135909116906040013561135b565b6105376116f0565b6108706004803603604081101561080857600080fd5b6001600160a01b038235169190810190604081016020820135600160201b81111561083257600080fd5b82018360208201111561084457600080fd5b803590602001918460018302840111600160201b8311171561086557600080fd5b5090925090506116f5565b604080516001600160a01b03909316835260208301919091528051918290030190f35b610380611997565b610208611a23565b6102b9600480360360208110156108b957600080fd5b5035611a7c565b6108c8611b84565b6040805163ffffffff9092168252519081900360200190f35b610208600480360360808110156108f757600080fd5b5063ffffffff8135169060208101359060408101359060600135611b97565b610646600480360360c081101561092c57600080fd5b5063ffffffff81358116916001600160a01b036020820135811692604083013590911691606081013591608082013581169160a0013516611e40565b6102b96004803603606081101561097e57600080fd5b810190602081018135600160201b81111561099857600080fd5b8201836020820111156109aa57600080fd5b803590602001918460018302840111600160201b831117156109cb57600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295505082359350505060200135611eb2565b610a19611fba565b60405180826002811115610a2957fe5b60ff16815260200191505060405180910390f35b610208611fca565b6106c36120e8565b6102b960048036036040811015610a6357600080fd5b810190602081018135600160201b811115610a7d57600080fd5b820183602082011115610a8f57600080fd5b803590602001918460018302840111600160201b83111715610ab057600080fd5b91908080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525092955050913592506120ee915050565b6102b96121ca565b6102b9612247565b6001546000546040805163b197919760e01b8152600160a81b90920463ffffffff166004830152336024830152516001600160a01b039092169163b197919791604480820192602092909190829003018186803b158015610b6357600080fd5b505afa158015610b77573d6000803e3d6000fd5b505050506040513d6020811015610b8d57600080fd5b5051610bca5760405162461bcd60e51b815260040180806020018281038252602181526020018061488a6021913960400191505060405180910390fd5b610bd26122bf565b565b6002546040805163f3674c8b60e01b815263ffffffff8516600482015290516000926001600160a01b03169163f3674c8b916024808301926020929190829003018186803b158015610c2557600080fd5b505afa158015610c39573d6000803e3d6000fd5b505050506040513d6020811015610c4f57600080fd5b50518015610ce15750600254604080516313c29da760e31b815263ffffffff861660048201529051610ce19287926001600160a01b0390911691639e14ed3891602480820192602092909190829003018186803b158015610caf57600080fd5b505afa158015610cc3573d6000803e3d6000fd5b505050506040513d6020811015610cd957600080fd5b505184611256565b90505b9392505050565b60006001600054600160a01b900460ff166002811115610d0757fe5b14905090565b6000806000808451604114610d285760009350505050610dd5565b50505060208201516040830151606084015160001a601b811015610d4a57601b015b8060ff16601b14158015610d6257508060ff16601c14155b610dcc576040805160008152602080820180845289905260ff8416828401526060820186905260808201859052915160019260a0808401939192601f1981019281900390910190855afa158015610dbd573d6000803e3d6000fd5b50505060206040510351610dcf565b60005b93505050505b92915050565b600080600260009054906101000a90046001600160a01b03166001600160a01b031663e13c96a96040518163ffffffff1660e01b815260040160206040518083038186803b158015610e2c57600080fd5b505afa158015610e40573d6000803e3d6000fd5b505050506040513d6020811015610e5657600080fd5b505160025460408051638293eef960e01b815263ffffffff841660048201529051929350610ee19287926001600160a01b031691638293eef9916024808301926020929190829003018186803b158015610eaf57600080fd5b505afa158015610ec3573d6000803e3d6000fd5b505050506040513d6020811015610ed957600080fd5b505185611256565b949350505050565b60025460408051630d3a6a9b60e11b81526001600160a01b038581166004830152848116602483015291516000939290921691631a74d53691604480820192602092909190829003018186803b158015610f4257600080fd5b505afa158015610f56573d6000803e3d6000fd5b505050506040513d6020811015610f6c57600080fd5b50519392505050565b60006020855181610f8257fe5b0615610f9057506000610ee1565b6000838160205b8851811161113e578089015193506020818a510360200181610fb557fe5b0491505b600082118015610fcc5750600286066001145b8015610fda57508160020a86115b15610fed57600286046001019550610fb9565b600286066110965760408051602080820187905281830186905282518083038401815260608301909352825160809092019182918401908083835b602083106110475780518252601f199092019160209182019101611028565b6001836020036101000a0380198251168184511680821785525050505050509050019150506040516020818303038152906040528051906020012092506002868161108e57fe5b049550611136565b60408051602080820186905281830187905282518083038401815260608301909352825160809092019182918401908083835b602083106110e85780518252601f1990920191602091820191016110c9565b6001836020036101000a0380198251168184511680821785525050505050509050019150506040516020818303038152906040528051906020012092506002868161112f57fe5b0460010195505b602001610f97565b505090941495945050505050565b6000546001600160a01b031681565b6001546001600160a01b031681565b600381565b600061117d85858585610f75565b95945050505050565b6060806111a9600060159054906101000a900463ffffffff168888888888611e40565b90506006816040516020018083815260200180602001828103825283818151815260200191508051906020019080838360005b838110156111f45781810151838201526020016111dc565b50505050905090810190601f1680156112215780820380516001836020036101000a031916815260200191505b5060408051601f198184030181529190529b9a5050505050505050505050565b60055481565b6003546001600160a01b031681565b6000610ce1848484611eb2565b6001546000546040805163b197919760e01b8152600160a81b90920463ffffffff166004830152336024830152516001600160a01b039092169163b197919791604480820192602092909190829003018186803b1580156112c357600080fd5b505afa1580156112d7573d6000803e3d6000fd5b505050506040513d60208110156112ed57600080fd5b505161132a5760405162461bcd60e51b815260040180806020018281038252602181526020018061488a6021913960400191505060405180910390fd5b600080546001600160a01b0319166001600160a01b0392909216919091179055565b6002546001600160a01b031681565b6001600054600160a01b900460ff16600281111561137557fe5b146113b4576040805162461bcd60e51b815260206004820152600a60248201526936bab9ba1031329037b760b11b604482015290519081900360640190fd5b6001546001600160a01b031633146113fd5760405162461bcd60e51b81526004018080602001828103825260268152602001806148cf6026913960400191505060405180910390fd5b60025460408051630d3a6a9b60e11b81526001600160a01b038681166004830152858116602483015291519190921691631a74d536916044808301926020929190829003018186803b15801561145257600080fd5b505afa158015611466573d6000803e3d6000fd5b505050506040513d602081101561147c57600080fd5b5051156114c4576040805162461bcd60e51b81526020600482015260116024820152701c1c995d9a5bdd5cdb1e48195e1a5d1959607a1b604482015290519081900360640190fd5b60025460408051630d69c3d360e41b815290516000926001600160a01b03169163d69c3d3091600480830192602092919082900301818787803b15801561150a57600080fd5b505af115801561151e573d6000803e3d6000fd5b505050506040513d602081101561153457600080fd5b50516002546040805163e13c96a960e01b815290519293506000926003926001600160a01b03169163e13c96a9916004808301926020929190829003018186803b15801561158157600080fd5b505afa158015611595573d6000803e3d6000fd5b505050506040513d60208110156115ab57600080fd5b505160008054604080516001600160e01b0319600160a81b90930460e090811b84166020838101919091526bffffffffffffffffffffffff1960608e811b821660248601528d901b166038840152604c83018b905289821b8516606c840152969095019485901b909216607083015280516054818403018152607483018083528151919096012060025463b214faa560e01b909652607883018190529051939550936001600160a01b03169263b214faa59260988084019391929182900301818387803b15801561167b57600080fd5b505af115801561168f573d6000803e3d6000fd5b50506040805187815263ffffffff808816602083015286168183015290516001600160a01b03808a1694508a1692507ff3574eec64c9c991123d25044e9f48773bbb54b323f7b7f5be684071e6857d299181900360600190a3505050505050565b600581565b60015460009081906001600160a01b031633146117435760405162461bcd60e51b81526004018080602001828103825260268152602001806148cf6026913960400191505060405180910390fd5b600061178f600086868080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929392505063ffffffff61234e169050565b905060018114156117e4576117da8686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061236a92505050565b925092505061198f565b600281141561182d576117da8686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061282492505050565b6003811415611876576117da8686868080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250612de892505050565b60048114156118bf576117da8686868080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506132bd92505050565b6005811415611908576117da8686868080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506136e192505050565b6006811415611951576117da8686868080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250613a3592505050565b6040805162461bcd60e51b815260206004820152600e60248201526d34b73b30b634b21030b1ba34b7b760911b604482015290519081900360640190fd5b935093915050565b60015460008054604080516320f49ddb60e01b8152600160a81b90920463ffffffff1660048301525191926001600160a01b0316916320f49ddb91602480820192602092909190829003018186803b1580156119f257600080fd5b505afa158015611a06573d6000803e3d6000fd5b505050506040513d6020811015611a1c57600080fd5b5051905090565b611a2b6121ca565b610bca576040805162461bcd60e51b815260206004820152601b60248201527f636861696e20686173206e6f7420796574206162616e646f6e65640000000000604482015290519081900360640190fd5b600254604080516306e265cf60e21b815260048101849052905160009283926001600160a01b0390911691631b89973c91602480820192602092909190829003018186803b158015611acd57600080fd5b505afa158015611ae1573d6000803e3d6000fd5b505050506040513d6020811015611af757600080fd5b505190508015801590610ce457506002546040805163e13c96a960e01b8152905183926001600160a01b03169163e13c96a9916004808301926020929190829003018186803b158015611b4957600080fd5b505afa158015611b5d573d6000803e3d6000fd5b505050506040513d6020811015611b7357600080fd5b505163ffffffff1610159392505050565b600054600160a81b900463ffffffff1681565b6001600054600160a01b900460ff166002811115611bb157fe5b14611bf0576040805162461bcd60e51b815260206004820152600a60248201526936bab9ba1031329037b760b11b604482015290519081900360640190fd5b611bf8612247565b611c3d576040805162461bcd60e51b815260206004820152601160248201527018d85b9b9bdd081cdd589b5a5d081e595d607a1b604482015290519081900360640190fd5b6003546001600160a01b03163314611c9c576040805162461bcd60e51b815260206004820152601e60248201527f7375626d6974746572206d75737420626520746865206f70657261746f720000604482015290519081900360640190fd5b600260009054906101000a90046001600160a01b03166001600160a01b031663e13c96a96040518163ffffffff1660e01b815260040160206040518083038186803b158015611cea57600080fd5b505afa158015611cfe573d6000803e3d6000fd5b505050506040513d6020811015611d1457600080fd5b505163ffffffff85811660019092011614611d605760405162461bcd60e51b815260040180806020018281038252602381526020018061491c6023913960400191505060405180910390fd5b6002546004805460408051631786ba3360e01b815263ffffffff8916938101939093526024830187905260448301869052606483018590526084830191909152516001600160a01b0390921691631786ba339160a48082019260009290919082900301818387803b158015611dd457600080fd5b505af1158015611de8573d6000803e3d6000fd5b50506040805163ffffffff88168152602081018790528082018690526060810185905290517fd48fb227199e496bc59e84f5777a330e8afdfd00efc7cd29d79c0fb2893411399350908190036080019150a150505050565b604080516001600160e01b031960e089811b821660208401526bffffffffffffffffffffffff1960608a811b8216602486015289901b166038840152604c830187905285811b8216606c84015284901b1660708201528151605481830301815260749091019091529695505050505050565b60006020845181611ebf57fe5b0615611ecd57506000610ce4565b8360008360205b87518111611fad57808401519250828210611f105760408051602081018590528082018490528151808203830181526060909101909152611f33565b604080516020810184905280820185905281518082038301815260609091019091525b6040516020018082805190602001908083835b60208310611f655780518252601f199092019160209182019101611f46565b6001836020036101000a038019825116818451168082178552505050505050905001915050604051602081830303815290604052805190602001209150602081019050611ed4565b5090941495945050505050565b600054600160a01b900460ff1681565b6001600054600160a01b900460ff166002811115611fe457fe5b14612023576040805162461bcd60e51b815260206004820152600a60248201526936bab9ba1031329037b760b11b604482015290519081900360640190fd5b6000546001600160a01b0316331461206c5760405162461bcd60e51b815260040180806020018281038252602881526020018061493f6028913960400191505060405180910390fd5b612074612247565b6120ba576040805162461bcd60e51b815260206004820152601260248201527118d85b9b9bdd081d5c19dc985919481e595d60721b604482015290519081900360640190fd5b6120c2613d06565b600154600054610bd2916001600160a01b031690600160a81b900463ffffffff16613d9b565b60045481565b6000806001600260009054906101000a90046001600160a01b03166001600160a01b031663e13c96a96040518163ffffffff1660e01b815260040160206040518083038186803b15801561214157600080fd5b505afa158015612155573d6000803e3d6000fd5b505050506040513d602081101561216b57600080fd5b505160025460408051638293eef960e01b815263ffffffff94909303938416600484015251929350610ee19287926001600160a01b0390921691638293eef9916024808301926020929190829003018186803b158015610eaf57600080fd5b6005546002546040805163413350bd60e01b81529051600093926001600160a01b03169163413350bd916004808301926020929190829003018186803b15801561221357600080fd5b505afa158015612227573d6000803e3d6000fd5b505050506040513d602081101561223d57600080fd5b5051014311905090565b6002546040805163413350bd60e01b815290516000926001600160a01b03169163413350bd916004808301926020929190829003018186803b15801561228c57600080fd5b505afa1580156122a0573d6000803e3d6000fd5b505050506040513d60208110156122b657600080fd5b50514311905090565b6001600054600160a01b900460ff1660028111156122d957fe5b14612318576040805162461bcd60e51b815260206004820152600a60248201526936bab9ba1031329037b760b11b604482015290519081900360640190fd5b6000805460ff60a01b191681556040517f369554cf721939830e3356301e1150520b7a57198eaabd24211952c158f3ba4e9190a1565b6000816020018351101561236157600080fd5b50016020015190565b600080606080606085806020019051608081101561238757600080fd5b815160208301805160405192949293830192919084600160201b8211156123ad57600080fd5b9083019060208201858111156123c257600080fd5b8251600160201b8111828201881017156123db57600080fd5b82525081516020918201929091019080838360005b838110156124085781810151838201526020016123f0565b50505050905090810190601f1680156124355780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b82111561245757600080fd5b90830190602082018581111561246c57600080fd5b8251600160201b81118282018810171561248557600080fd5b82525081516020918201929091019080838360005b838110156124b257818101518382015260200161249a565b50505050905090810190601f1680156124df5780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b82111561250157600080fd5b90830190602082018581111561251657600080fd5b8251600160201b81118282018810171561252f57600080fd5b82525081516020918201929091019080838360005b8381101561255c578181015183820152602001612544565b50505050905090810190601f1680156125895780820380516001836020036101000a031916815260200191505b506040525050509350935093505061259f61472a565b6125aa84848a613e14565b90506003816060015160068111156125be57fe5b14612610576040805162461bcd60e51b815260206004820181905260248201527f656e747279206d757374206265206f662074797065205769746864726177616c604482015290519081900360640190fd5b61262582826101200151836101400151610bd4565b61266c576040805162461bcd60e51b815260206004820152601360248201527234b73b30b634b21032b73a393c90383937b7b360691b604482015290519081900360640190fd5b60025461014082015160408051636dba4b0f60e01b81526004810192909252516001600160a01b0390921691636dba4b0f91602480820192602092909190829003018186803b1580156126be57600080fd5b505afa1580156126d2573d6000803e3d6000fd5b505050506040513d60208110156126e857600080fd5b50511561273c576040805162461bcd60e51b815260206004820152601760248201527f656e74727920616c72656164792077697468647261776e000000000000000000604482015290519081900360640190fd5b6002546101408201516040805163bb55b89360e01b81526004810192909252516001600160a01b039092169163bb55b8939160248082019260009290919082900301818387803b15801561278f57600080fd5b505af11580156127a3573d6000803e3d6000fd5b5050505080604001516001600160a01b031681602001516001600160a01b03167fa6786aab7dbbc48b4b0387488b407bd81448030ab207b50bea7dbb5fbc1cd9eb8361014001518460c00151604051808381526020018281526020019250505060405180910390a380604001518160c0015195509550505050509250929050565b6000806001600054600160a01b900460ff16600281111561284157fe5b14612880576040805162461bcd60e51b815260206004820152600a60248201526936bab9ba1031329037b760b11b604482015290519081900360640190fd5b60608060608060608780602001905160c081101561289d57600080fd5b815160208301805160405192949293830192919084600160201b8211156128c357600080fd5b9083019060208201858111156128d857600080fd5b8251600160201b8111828201881017156128f157600080fd5b82525081516020918201929091019080838360005b8381101561291e578181015183820152602001612906565b50505050905090810190601f16801561294b5780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b82111561296d57600080fd5b90830190602082018581111561298257600080fd5b82518660208202830111600160201b8211171561299e57600080fd5b82525081516020918201928201910280838360005b838110156129cb5781810151838201526020016129b3565b5050505090500160405260200180516040519392919084600160201b8211156129f357600080fd5b908301906020820185811115612a0857600080fd5b82518660208202830111600160201b82111715612a2457600080fd5b82525081516020918201928201910280838360005b83811015612a51578181015183820152602001612a39565b5050505090500160405260200180516040519392919084600160201b821115612a7957600080fd5b908301906020820185811115612a8e57600080fd5b8251600160201b811182820188101715612aa757600080fd5b82525081516020918201929091019080838360005b83811015612ad4578181015183820152602001612abc565b50505050905090810190601f168015612b015780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b821115612b2357600080fd5b908301906020820185811115612b3857600080fd5b8251600160201b811182820188101715612b5157600080fd5b82525081516020918201929091019080838360005b83811015612b7e578181015183820152602001612b66565b50505050905090810190601f168015612bab5780820380516001836020036101000a031916815260200191505b506040525050509550955095509550955050612bc56147b8565b612bd28686868686613f5c565b9050612bdc6147ea565b50805160208101516001600160a01b038c8116911614612c2d5760405162461bcd60e51b81526004018080602001828103825260278152602001806148f56027913960400191505060405180910390fd5b8060a0015163ffffffff16600260009054906101000a90046001600160a01b03166001600160a01b031663e13c96a96040518163ffffffff1660e01b815260040160206040518083038186803b158015612c8657600080fd5b505afa158015612c9a573d6000803e3d6000fd5b505050506040513d6020811015612cb057600080fd5b505163ffffffff16118015612cce575060a081015163ffffffff1615155b612d095760405162461bcd60e51b815260040180806020018281038252602b815260200180614967602b913960400191505060405180910390fd5b60025460a082015160408051630638dde560e11b815263ffffffff909216600483015251612d92926001600160a01b031691630c71bbca916024808301926020929190829003018186803b158015612d6057600080fd5b505afa158015612d74573d6000803e3d6000fd5b505050506040513d6020811015612d8a57600080fd5b505183614071565b612dcd5760405162461bcd60e51b81526004018080602001828103825260248152602001806148ab6024913960400191505060405180910390fd5b612dd6816140fc565b98509850505050505050509250929050565b6000806001600054600160a01b900460ff166002811115612e0557fe5b14612e44576040805162461bcd60e51b815260206004820152600a60248201526936bab9ba1031329037b760b11b604482015290519081900360640190fd5b6060806060858060200190516080811015612e5e57600080fd5b815160208301805160405192949293830192919084600160201b821115612e8457600080fd5b908301906020820185811115612e9957600080fd5b8251600160201b811182820188101715612eb257600080fd5b82525081516020918201929091019080838360005b83811015612edf578181015183820152602001612ec7565b50505050905090810190601f168015612f0c5780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b821115612f2e57600080fd5b908301906020820185811115612f4357600080fd5b8251600160201b811182820188101715612f5c57600080fd5b82525081516020918201929091019080838360005b83811015612f89578181015183820152602001612f71565b50505050905090810190601f168015612fb65780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b821115612fd857600080fd5b908301906020820185811115612fed57600080fd5b8251600160201b81118282018810171561300657600080fd5b82525081516020918201929091019080838360005b8381101561303357818101518382015260200161301b565b50505050905090810190601f1680156130605780820380516001836020036101000a031916815260200191505b506040525050509350935093505061307661472a565b61308184848a613e14565b905061309581602001518260400151610ee9565b156130db576040805162461bcd60e51b81526020600482015260116024820152701c1c995d9a5bdd5cdb1e48195e1a5d1959607a1b604482015290519081900360640190fd5b6130ea828261014001516120ee565b613133576040805162461bcd60e51b815260206004820152601560248201527434b73b30b634b2103130b630b731b290383937b7b360591b604482015290519081900360640190fd5b6000600560ff16600260009054906101000a90046001600160a01b03166001600160a01b031663e13c96a96040518163ffffffff1660e01b815260040160206040518083038186803b15801561318857600080fd5b505afa15801561319c573d6000803e3d6000fd5b505050506040513d60208110156131b257600080fd5b505160025461014085015160408051630c9caaf560e31b815260048101929092529390920163ffffffff166024830181905292519293506001600160a01b0316916364e557a89160448082019260009290919082900301818387803b15801561321a57600080fd5b505af115801561322e573d6000803e3d6000fd5b5050505081604001516001600160a01b031682602001516001600160a01b03167f033fd1dc81f5c58d2987171bd5432008ce60e028fd6b687900ef31dcbeee03348461014001518560e001518660a00151866040518085815260200184815260200183815260200182815260200194505050505060405180910390a35060400151976000975095505050505050565b6000806001600054600160a01b900460ff1660028111156132da57fe5b14613319576040805162461bcd60e51b815260206004820152600a60248201526936bab9ba1031329037b760b11b604482015290519081900360640190fd5b606080606085806020019051608081101561333357600080fd5b815160208301805160405192949293830192919084600160201b82111561335957600080fd5b90830190602082018581111561336e57600080fd5b8251600160201b81118282018810171561338757600080fd5b82525081516020918201929091019080838360005b838110156133b457818101518382015260200161339c565b50505050905090810190601f1680156133e15780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b82111561340357600080fd5b90830190602082018581111561341857600080fd5b8251600160201b81118282018810171561343157600080fd5b82525081516020918201929091019080838360005b8381101561345e578181015183820152602001613446565b50505050905090810190601f16801561348b5780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b8211156134ad57600080fd5b9083019060208201858111156134c257600080fd5b8251600160201b8111828201881017156134db57600080fd5b82525081516020918201929091019080838360005b838110156135085781810151838201526020016134f0565b50505050905090810190601f1680156135355780820380516001836020036101000a031916815260200191505b506040525050509350935093505061354b61472a565b61355684848a613e14565b905061356a81602001518260400151610ee9565b156135b0576040805162461bcd60e51b81526020600482015260116024820152701c1c995d9a5bdd5cdb1e48195e1a5d1959607a1b604482015290519081900360640190fd5b6135be816101400151611a7c565b6135f95760405162461bcd60e51b81526004018080602001828103825260448152602001806148466044913960600191505060405180910390fd5b61360882826101400151610ddb565b613651576040805162461bcd60e51b815260206004820152601560248201527434b73b30b634b2103130b630b731b290383937b7b360591b604482015290519081900360640190fd5b600254610140820151604080516001622a21a160e01b031981526004810192909252516001600160a01b039092169163ffd5de5f9160248082019260009290919082900301818387803b1580156136a757600080fd5b505af11580156136bb573d6000803e3d6000fd5b505050506136c8816141ea565b80604001518160e0015195509550505050509250929050565b60008080600054600160a01b900460ff1660028111156136fd57fe5b1461373d576040805162461bcd60e51b815260206004820152600b60248201526a36bab9ba1031329037b33360a91b604482015290519081900360640190fd5b606080606085806020019051608081101561375757600080fd5b815160208301805160405192949293830192919084600160201b82111561377d57600080fd5b90830190602082018581111561379257600080fd5b8251600160201b8111828201881017156137ab57600080fd5b82525081516020918201929091019080838360005b838110156137d85781810151838201526020016137c0565b50505050905090810190601f1680156138055780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b82111561382757600080fd5b90830190602082018581111561383c57600080fd5b8251600160201b81118282018810171561385557600080fd5b82525081516020918201929091019080838360005b8381101561388257818101518382015260200161386a565b50505050905090810190601f1680156138af5780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b8211156138d157600080fd5b9083019060208201858111156138e657600080fd5b8251600160201b8111828201881017156138ff57600080fd5b82525081516020918201929091019080838360005b8381101561392c578181015183820152602001613914565b50505050905090810190601f1680156139595780820380516001836020036101000a031916815260200191505b506040525050509350935093505061396f61472a565b61397a84848a613e14565b905061398e81602001518260400151610ee9565b156139d4576040805162461bcd60e51b81526020600482015260116024820152701c1c995d9a5bdd5cdb1e48195e1a5d1959607a1b604482015290519081900360640190fd5b6139e3828261014001516120ee565b613a2c576040805162461bcd60e51b815260206004820152601560248201527434b73b30b634b2103130b630b731b290383937b7b360591b604482015290519081900360640190fd5b6136c8816141ea565b60008080600054600160a01b900460ff166002811115613a5157fe5b14613a91576040805162461bcd60e51b815260206004820152600b60248201526a36bab9ba1031329037b33360a91b604482015290519081900360640190fd5b6060838060200190516040811015613aa857600080fd5b815160208301805160405192949293830192919084600160201b821115613ace57600080fd5b908301906020820185811115613ae357600080fd5b8251600160201b811182820188101715613afc57600080fd5b82525081516020918201929091019080838360005b83811015613b29578181015183820152602001613b11565b50505050905090810190601f168015613b565780820380516001836020036101000a031916815260200191505b50604052505050915050613b686147ea565b613b71826142bb565b6000548151919250600160a81b900463ffffffff908116911614613bd6576040805162461bcd60e51b81526020600482015260176024820152763737ba10333937b69031bab93932b73a103632b233b2b960491b604482015290519081900360640190fd5b856001600160a01b031681602001516001600160a01b031614613c2a5760405162461bcd60e51b81526004018080602001828103825260278152602001806148f56027913960400191505060405180910390fd5b600260009054906101000a90046001600160a01b03166001600160a01b031663e13c96a96040518163ffffffff1660e01b815260040160206040518083038186803b158015613c7857600080fd5b505afa158015613c8c573d6000803e3d6000fd5b505050506040513d6020811015613ca257600080fd5b505160a082015163ffffffff91821691161015613cf05760405162461bcd60e51b815260040180806020018281038252603e815260200180614992603e913960400191505060405180910390fd5b613cf9816140fc565b9350935050509250929050565b6001600054600160a01b900460ff166002811115613d2057fe5b14613d5f576040805162461bcd60e51b815260206004820152600a60248201526936bab9ba1031329037b760b11b604482015290519081900360640190fd5b6000805460ff60a01b1916600160a11b1781556040517fc15f68f0a72806ff3f8bf2435385a67c4c22413f1c7931ef7bcea718e6ffcf039190a1565b60408051631a93ec9560e01b815263ffffffff8316600482015290516001600160a01b03841691631a93ec9591602480830192600092919082900301818387803b158015613de857600080fd5b505af1158015613dfc573d6000803e3d6000fd5b5050600080546001600160a01b031916905550505050565b613e1c61472a565b613e26848461439b565b6000548151919250600160a81b900463ffffffff908116911614613e91576040805162461bcd60e51b815260206004820181905260248201527f656e747279206973206e6f742066726f6d2063757272656e74206c6564676572604482015290519081900360640190fd5b6003546101a08201516001600160a01b03908116911614613ef9576040805162461bcd60e51b815260206004820152601a60248201527f6661696c656420746f20766572696679207369676e6174757265000000000000604482015290519081900360640190fd5b816001600160a01b031681602001516001600160a01b031614610ce4576040805162461bcd60e51b81526020600482015260166024820152750cadce8e4f240c2c6c6deeadce840dad2e6dac2e8c6d60531b604482015290519081900360640190fd5b613f646147b8565b613f6d866142bb565b808252600054905163ffffffff908116600160a81b9092041614613fd2576040805162461bcd60e51b81526020600482015260176024820152763737ba10333937b69031bab93932b73a103632b233b2b960491b604482015290519081900360640190fd5b604051806060016040528086600081518110613fea57fe5b602002602001015181526020018560008151811061400457fe5b6020026020010151815260200184815250816020018190525060405180606001604052808660018151811061403557fe5b602002602001015181526020018560018151811061404f57fe5b6020026020010151815260200183815250816040018190525095945050505050565b600081602001516020015160010182604001516020015114801561409e5750815160c00151604083015151115b80156140b35750815160c00151602083015151105b80156140d857506020808301516040810151815191909201516140d89291869161116f565b8015610ce45750604080830151908101518151602090920151610ce492869161116f565b60025460c0820151604080516352a0c8f160e11b815260048101929092525160009283926001600160a01b039091169163a54191e291602480820192869290919082900301818387803b15801561415257600080fd5b505af1158015614166573d6000803e3d6000fd5b5050505082604001516001600160a01b031683602001516001600160a01b03167f9355bbbbf685556a4760195fdf1f0d211bfd2324584092e8c28d70bfa6b7d3fa85606001518660800151604051808381526020018263ffffffff1663ffffffff1681526020019250505060405180910390a3505060408101516060820151915091565b6002546020820151604080840151815163c1308df360e01b81526001600160a01b03938416600482015290831660248201529051919092169163c1308df391604480830192600092919082900301818387803b15801561424957600080fd5b505af115801561425d573d6000803e3d6000fd5b5050505080604001516001600160a01b031681602001516001600160a01b03167f104ad9ab27213fcc307f2308fc015959def8986f04d9475d82c5f32ab9c8d83b8360e001516040518082815260200191505060405180910390a350565b6142c36147ea565b6142d482600063ffffffff61461716565b63ffffffff90811682526142ed90839060049061463316565b6001600160a01b0316602082015261430c82601863ffffffff61463316565b6001600160a01b0316604082015261432b82602c63ffffffff61234e16565b606082015261434182604c63ffffffff61461716565b63ffffffff908116608083015261435d90839060509061461716565b63ffffffff1660a082018190528151602083015160408401516060850151608086015161438995611e40565b805160209091012060c0820152919050565b6143a361472a565b6143b483600163ffffffff61461716565b63ffffffff90811682526143cd90849060059061463316565b6001600160a01b031660208201526143ec83601963ffffffff61463316565b6001600160a01b0316604082015261440b83602d63ffffffff61465616565b60ff16600681111561441957fe5b8160600190600681111561442957fe5b9081600681111561443657fe5b90525061444a83602e63ffffffff61465616565b60ff16608082015261446383602f63ffffffff61467216565b67ffffffffffffffff1660a082015261448383603763ffffffff61234e16565b60c082015261449983605763ffffffff61234e16565b60e08201526144af83607763ffffffff61468e16565b6fffffffffffffffffffffffffffffffff166101008201526144d883608763ffffffff61461716565b63ffffffff9081166101208301526144f5908490608b9061234e16565b6101608201528251839060ab10156145e857835161452190859060ab9060aa190163ffffffff6146aa16565b6101c083018190526040518151819060208401908083835b602083106145585780518252601f199092019160209182019101614539565b6001836020036101000a0380198251168184511680821785525050505050509050019150506040518091039020826101600151146145d2576040805162461bcd60e51b81526020600482015260126024820152710c8c2e8c240d0c2e6d040dad2e6dac2e8c6d60731b604482015290519081900360640190fd5b6145e584600060ab63ffffffff6146aa16565b90505b8051602082012061014083018190526146019084610d0d565b6001600160a01b03166101a08301525092915050565b6000816004018351101561462a57600080fd5b50016004015190565b6000816014018351101561464657600080fd5b500160200151600160601b900490565b6000816001018351101561466957600080fd5b50016001015190565b6000816008018351101561468557600080fd5b50016008015190565b600081601001835110156146a157600080fd5b50016010015190565b6060818301845110156146bc57600080fd5b6060821580156146d757604051915060208201604052614721565b6040519150601f8416801560200281840101858101878315602002848b0101015b818310156147105780518352602092830192016146f8565b5050858452601f01601f1916604052505b50949350505050565b604080516101e0810182526000808252602082018190529181018290529060608201908152602001600060ff16815260200160008152602001600081526020016000815260200160008152602001600063ffffffff16815260200160008019168152602001600080191681526020016060815260200160006001600160a01b03168152602001606081525090565b60405180606001604052806147cb6147ea565b81526020016147d8614826565b81526020016147e5614826565b905290565b6040805160e081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c081019190915290565b604080516060808201835260008083526020830152918101919091529056fe6e6f207072696f7220636c61696d20666f756e6420746f207769746864726177204f522062616c616e636573206172652079657420746f20626520636f6e6669726d6564696e76616c69642073656e6465723b206d75737420626520617070206f776e65726661696c656420746f2070726f6f66206578636c7573696f6e206f66206465706f736974696e76616c69642073656e6465723b206d75737420626520676c756f6e20636f6e7472616374636c61696d616e74206d75737420626520746865206f726967696e616c206465706f7369746f7267626c6f636b206d75737420626520746865206e65787420696e2073657175656e6365696e76616c69642073656e6465723b206d7573742062652075706772616465206f70657261746f7264657369676e617465642067626c6f636b20697320756e636f6e6669726d6564206f7220756e6b6e6f776e64657369676e617465642067626c6f636b20697320616c726561647920636f6e6669726d65643b2075736520657869744f6e48616c7420696e7374656164a265627a7a7231582004bd562715ccf4de686c0b152448638a6ba647e5c549aea1369ac5a976b24faa64736f6c634300050c0032000000000000000000000000000000000000000000000000000000000000000200000000000000000000000075ace7a086ea0fb1a79e43cc6331ad053d8c67cb0000000000000000000000000d283d685f0a741c463846176e4c8eff90d3f9ec0000000000000000000000005ccaaae7bea14e8e04fb0fc7ed16df49d5678eb800000000000000000000000000000000000000000000000000000000000000240000000000000000000000000000000000000000000000000000000000009d80
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106101fb5760003560e01c806373d4a13a1161011a578063b6ba5ae8116100ad578063d55ec6971161007c578063d55ec69714610a3d578063e1a41bcf14610a45578063e4e439f114610a4d578063fc5a948b14610af3578063ffbc9bd014610afb576101fb565b8063b6ba5ae8146108e1578063bab1f0d814610916578063bf0af1ba14610968578063c19d93fb14610a11576101fb565b806387cb37e3116100e957806387cb37e314610893578063883188341461089b578063985bcf34146108a3578063af640d0f146108c0576101fb565b806373d4a13a146107ac5780637de182c5146107b457806380de7f91146107ea578063853a7330146107f2576101fb565b806327869c57116101925780634878d26e116101615780634878d26e146106bb578063570ca735146106d557806358f4996f146106dd5780635f285ea614610786576101fb565b806327869c57146105275780632e8ff5bd1461052f57806338da5b071461054d57806345eedf00146105fc576101fb565b806319779b42116101ce57806319779b421461039c5780631a74d5361461044257806323a27bcd1461047057806325c99ae41461051f576101fb565b8063038d71ee146102005780630864e17c1461020a578063175bbecf146102cd57806319045a25146102d5575b600080fd5b610208610b03565b005b6102b96004803603606081101561022057600080fd5b810190602081018135600160201b81111561023a57600080fd5b82018360208201111561024c57600080fd5b803590602001918460018302840111600160201b8311171561026d57600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295505063ffffffff8335169350505060200135610bd4565b604080519115158252519081900360200190f35b6102b9610ceb565b610380600480360360408110156102eb57600080fd5b81359190810190604081016020820135600160201b81111561030c57600080fd5b82018360208201111561031e57600080fd5b803590602001918460018302840111600160201b8311171561033f57600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550610d0d945050505050565b604080516001600160a01b039092168252519081900360200190f35b6102b9600480360360408110156103b257600080fd5b810190602081018135600160201b8111156103cc57600080fd5b8201836020820111156103de57600080fd5b803590602001918460018302840111600160201b831117156103ff57600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295505091359250610ddb915050565b6102b96004803603604081101561045857600080fd5b506001600160a01b0381358116916020013516610ee9565b6102b96004803603608081101561048657600080fd5b810190602081018135600160201b8111156104a057600080fd5b8201836020820111156104b257600080fd5b803590602001918460018302840111600160201b831117156104d357600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295505082359350505060208101359060400135610f75565b61038061114c565b61038061115b565b61053761116a565b6040805160ff9092168252519081900360200190f35b6102b96004803603608081101561056357600080fd5b810190602081018135600160201b81111561057d57600080fd5b82018360208201111561058f57600080fd5b803590602001918460018302840111600160201b831117156105b057600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550508235935050506020810135906040013561116f565b610646600480360360a081101561061257600080fd5b506001600160a01b03813581169160208101359091169060408101359063ffffffff60608201358116916080013516611186565b6040805160208082528351818301528351919283929083019185019080838360005b83811015610680578181015183820152602001610668565b50505050905090810190601f1680156106ad5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6106c3611241565b60408051918252519081900360200190f35b610380611247565b6102b9600480360360608110156106f357600080fd5b810190602081018135600160201b81111561070d57600080fd5b82018360208201111561071f57600080fd5b803590602001918460018302840111600160201b8311171561074057600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295505082359350505060200135611256565b6102086004803603602081101561079c57600080fd5b50356001600160a01b0316611263565b61038061134c565b610208600480360360608110156107ca57600080fd5b506001600160a01b0381358116916020810135909116906040013561135b565b6105376116f0565b6108706004803603604081101561080857600080fd5b6001600160a01b038235169190810190604081016020820135600160201b81111561083257600080fd5b82018360208201111561084457600080fd5b803590602001918460018302840111600160201b8311171561086557600080fd5b5090925090506116f5565b604080516001600160a01b03909316835260208301919091528051918290030190f35b610380611997565b610208611a23565b6102b9600480360360208110156108b957600080fd5b5035611a7c565b6108c8611b84565b6040805163ffffffff9092168252519081900360200190f35b610208600480360360808110156108f757600080fd5b5063ffffffff8135169060208101359060408101359060600135611b97565b610646600480360360c081101561092c57600080fd5b5063ffffffff81358116916001600160a01b036020820135811692604083013590911691606081013591608082013581169160a0013516611e40565b6102b96004803603606081101561097e57600080fd5b810190602081018135600160201b81111561099857600080fd5b8201836020820111156109aa57600080fd5b803590602001918460018302840111600160201b831117156109cb57600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295505082359350505060200135611eb2565b610a19611fba565b60405180826002811115610a2957fe5b60ff16815260200191505060405180910390f35b610208611fca565b6106c36120e8565b6102b960048036036040811015610a6357600080fd5b810190602081018135600160201b811115610a7d57600080fd5b820183602082011115610a8f57600080fd5b803590602001918460018302840111600160201b83111715610ab057600080fd5b91908080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525092955050913592506120ee915050565b6102b96121ca565b6102b9612247565b6001546000546040805163b197919760e01b8152600160a81b90920463ffffffff166004830152336024830152516001600160a01b039092169163b197919791604480820192602092909190829003018186803b158015610b6357600080fd5b505afa158015610b77573d6000803e3d6000fd5b505050506040513d6020811015610b8d57600080fd5b5051610bca5760405162461bcd60e51b815260040180806020018281038252602181526020018061488a6021913960400191505060405180910390fd5b610bd26122bf565b565b6002546040805163f3674c8b60e01b815263ffffffff8516600482015290516000926001600160a01b03169163f3674c8b916024808301926020929190829003018186803b158015610c2557600080fd5b505afa158015610c39573d6000803e3d6000fd5b505050506040513d6020811015610c4f57600080fd5b50518015610ce15750600254604080516313c29da760e31b815263ffffffff861660048201529051610ce19287926001600160a01b0390911691639e14ed3891602480820192602092909190829003018186803b158015610caf57600080fd5b505afa158015610cc3573d6000803e3d6000fd5b505050506040513d6020811015610cd957600080fd5b505184611256565b90505b9392505050565b60006001600054600160a01b900460ff166002811115610d0757fe5b14905090565b6000806000808451604114610d285760009350505050610dd5565b50505060208201516040830151606084015160001a601b811015610d4a57601b015b8060ff16601b14158015610d6257508060ff16601c14155b610dcc576040805160008152602080820180845289905260ff8416828401526060820186905260808201859052915160019260a0808401939192601f1981019281900390910190855afa158015610dbd573d6000803e3d6000fd5b50505060206040510351610dcf565b60005b93505050505b92915050565b600080600260009054906101000a90046001600160a01b03166001600160a01b031663e13c96a96040518163ffffffff1660e01b815260040160206040518083038186803b158015610e2c57600080fd5b505afa158015610e40573d6000803e3d6000fd5b505050506040513d6020811015610e5657600080fd5b505160025460408051638293eef960e01b815263ffffffff841660048201529051929350610ee19287926001600160a01b031691638293eef9916024808301926020929190829003018186803b158015610eaf57600080fd5b505afa158015610ec3573d6000803e3d6000fd5b505050506040513d6020811015610ed957600080fd5b505185611256565b949350505050565b60025460408051630d3a6a9b60e11b81526001600160a01b038581166004830152848116602483015291516000939290921691631a74d53691604480820192602092909190829003018186803b158015610f4257600080fd5b505afa158015610f56573d6000803e3d6000fd5b505050506040513d6020811015610f6c57600080fd5b50519392505050565b60006020855181610f8257fe5b0615610f9057506000610ee1565b6000838160205b8851811161113e578089015193506020818a510360200181610fb557fe5b0491505b600082118015610fcc5750600286066001145b8015610fda57508160020a86115b15610fed57600286046001019550610fb9565b600286066110965760408051602080820187905281830186905282518083038401815260608301909352825160809092019182918401908083835b602083106110475780518252601f199092019160209182019101611028565b6001836020036101000a0380198251168184511680821785525050505050509050019150506040516020818303038152906040528051906020012092506002868161108e57fe5b049550611136565b60408051602080820186905281830187905282518083038401815260608301909352825160809092019182918401908083835b602083106110e85780518252601f1990920191602091820191016110c9565b6001836020036101000a0380198251168184511680821785525050505050509050019150506040516020818303038152906040528051906020012092506002868161112f57fe5b0460010195505b602001610f97565b505090941495945050505050565b6000546001600160a01b031681565b6001546001600160a01b031681565b600381565b600061117d85858585610f75565b95945050505050565b6060806111a9600060159054906101000a900463ffffffff168888888888611e40565b90506006816040516020018083815260200180602001828103825283818151815260200191508051906020019080838360005b838110156111f45781810151838201526020016111dc565b50505050905090810190601f1680156112215780820380516001836020036101000a031916815260200191505b5060408051601f198184030181529190529b9a5050505050505050505050565b60055481565b6003546001600160a01b031681565b6000610ce1848484611eb2565b6001546000546040805163b197919760e01b8152600160a81b90920463ffffffff166004830152336024830152516001600160a01b039092169163b197919791604480820192602092909190829003018186803b1580156112c357600080fd5b505afa1580156112d7573d6000803e3d6000fd5b505050506040513d60208110156112ed57600080fd5b505161132a5760405162461bcd60e51b815260040180806020018281038252602181526020018061488a6021913960400191505060405180910390fd5b600080546001600160a01b0319166001600160a01b0392909216919091179055565b6002546001600160a01b031681565b6001600054600160a01b900460ff16600281111561137557fe5b146113b4576040805162461bcd60e51b815260206004820152600a60248201526936bab9ba1031329037b760b11b604482015290519081900360640190fd5b6001546001600160a01b031633146113fd5760405162461bcd60e51b81526004018080602001828103825260268152602001806148cf6026913960400191505060405180910390fd5b60025460408051630d3a6a9b60e11b81526001600160a01b038681166004830152858116602483015291519190921691631a74d536916044808301926020929190829003018186803b15801561145257600080fd5b505afa158015611466573d6000803e3d6000fd5b505050506040513d602081101561147c57600080fd5b5051156114c4576040805162461bcd60e51b81526020600482015260116024820152701c1c995d9a5bdd5cdb1e48195e1a5d1959607a1b604482015290519081900360640190fd5b60025460408051630d69c3d360e41b815290516000926001600160a01b03169163d69c3d3091600480830192602092919082900301818787803b15801561150a57600080fd5b505af115801561151e573d6000803e3d6000fd5b505050506040513d602081101561153457600080fd5b50516002546040805163e13c96a960e01b815290519293506000926003926001600160a01b03169163e13c96a9916004808301926020929190829003018186803b15801561158157600080fd5b505afa158015611595573d6000803e3d6000fd5b505050506040513d60208110156115ab57600080fd5b505160008054604080516001600160e01b0319600160a81b90930460e090811b84166020838101919091526bffffffffffffffffffffffff1960608e811b821660248601528d901b166038840152604c83018b905289821b8516606c840152969095019485901b909216607083015280516054818403018152607483018083528151919096012060025463b214faa560e01b909652607883018190529051939550936001600160a01b03169263b214faa59260988084019391929182900301818387803b15801561167b57600080fd5b505af115801561168f573d6000803e3d6000fd5b50506040805187815263ffffffff808816602083015286168183015290516001600160a01b03808a1694508a1692507ff3574eec64c9c991123d25044e9f48773bbb54b323f7b7f5be684071e6857d299181900360600190a3505050505050565b600581565b60015460009081906001600160a01b031633146117435760405162461bcd60e51b81526004018080602001828103825260268152602001806148cf6026913960400191505060405180910390fd5b600061178f600086868080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929392505063ffffffff61234e169050565b905060018114156117e4576117da8686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061236a92505050565b925092505061198f565b600281141561182d576117da8686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061282492505050565b6003811415611876576117da8686868080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250612de892505050565b60048114156118bf576117da8686868080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506132bd92505050565b6005811415611908576117da8686868080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506136e192505050565b6006811415611951576117da8686868080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250613a3592505050565b6040805162461bcd60e51b815260206004820152600e60248201526d34b73b30b634b21030b1ba34b7b760911b604482015290519081900360640190fd5b935093915050565b60015460008054604080516320f49ddb60e01b8152600160a81b90920463ffffffff1660048301525191926001600160a01b0316916320f49ddb91602480820192602092909190829003018186803b1580156119f257600080fd5b505afa158015611a06573d6000803e3d6000fd5b505050506040513d6020811015611a1c57600080fd5b5051905090565b611a2b6121ca565b610bca576040805162461bcd60e51b815260206004820152601b60248201527f636861696e20686173206e6f7420796574206162616e646f6e65640000000000604482015290519081900360640190fd5b600254604080516306e265cf60e21b815260048101849052905160009283926001600160a01b0390911691631b89973c91602480820192602092909190829003018186803b158015611acd57600080fd5b505afa158015611ae1573d6000803e3d6000fd5b505050506040513d6020811015611af757600080fd5b505190508015801590610ce457506002546040805163e13c96a960e01b8152905183926001600160a01b03169163e13c96a9916004808301926020929190829003018186803b158015611b4957600080fd5b505afa158015611b5d573d6000803e3d6000fd5b505050506040513d6020811015611b7357600080fd5b505163ffffffff1610159392505050565b600054600160a81b900463ffffffff1681565b6001600054600160a01b900460ff166002811115611bb157fe5b14611bf0576040805162461bcd60e51b815260206004820152600a60248201526936bab9ba1031329037b760b11b604482015290519081900360640190fd5b611bf8612247565b611c3d576040805162461bcd60e51b815260206004820152601160248201527018d85b9b9bdd081cdd589b5a5d081e595d607a1b604482015290519081900360640190fd5b6003546001600160a01b03163314611c9c576040805162461bcd60e51b815260206004820152601e60248201527f7375626d6974746572206d75737420626520746865206f70657261746f720000604482015290519081900360640190fd5b600260009054906101000a90046001600160a01b03166001600160a01b031663e13c96a96040518163ffffffff1660e01b815260040160206040518083038186803b158015611cea57600080fd5b505afa158015611cfe573d6000803e3d6000fd5b505050506040513d6020811015611d1457600080fd5b505163ffffffff85811660019092011614611d605760405162461bcd60e51b815260040180806020018281038252602381526020018061491c6023913960400191505060405180910390fd5b6002546004805460408051631786ba3360e01b815263ffffffff8916938101939093526024830187905260448301869052606483018590526084830191909152516001600160a01b0390921691631786ba339160a48082019260009290919082900301818387803b158015611dd457600080fd5b505af1158015611de8573d6000803e3d6000fd5b50506040805163ffffffff88168152602081018790528082018690526060810185905290517fd48fb227199e496bc59e84f5777a330e8afdfd00efc7cd29d79c0fb2893411399350908190036080019150a150505050565b604080516001600160e01b031960e089811b821660208401526bffffffffffffffffffffffff1960608a811b8216602486015289901b166038840152604c830187905285811b8216606c84015284901b1660708201528151605481830301815260749091019091529695505050505050565b60006020845181611ebf57fe5b0615611ecd57506000610ce4565b8360008360205b87518111611fad57808401519250828210611f105760408051602081018590528082018490528151808203830181526060909101909152611f33565b604080516020810184905280820185905281518082038301815260609091019091525b6040516020018082805190602001908083835b60208310611f655780518252601f199092019160209182019101611f46565b6001836020036101000a038019825116818451168082178552505050505050905001915050604051602081830303815290604052805190602001209150602081019050611ed4565b5090941495945050505050565b600054600160a01b900460ff1681565b6001600054600160a01b900460ff166002811115611fe457fe5b14612023576040805162461bcd60e51b815260206004820152600a60248201526936bab9ba1031329037b760b11b604482015290519081900360640190fd5b6000546001600160a01b0316331461206c5760405162461bcd60e51b815260040180806020018281038252602881526020018061493f6028913960400191505060405180910390fd5b612074612247565b6120ba576040805162461bcd60e51b815260206004820152601260248201527118d85b9b9bdd081d5c19dc985919481e595d60721b604482015290519081900360640190fd5b6120c2613d06565b600154600054610bd2916001600160a01b031690600160a81b900463ffffffff16613d9b565b60045481565b6000806001600260009054906101000a90046001600160a01b03166001600160a01b031663e13c96a96040518163ffffffff1660e01b815260040160206040518083038186803b15801561214157600080fd5b505afa158015612155573d6000803e3d6000fd5b505050506040513d602081101561216b57600080fd5b505160025460408051638293eef960e01b815263ffffffff94909303938416600484015251929350610ee19287926001600160a01b0390921691638293eef9916024808301926020929190829003018186803b158015610eaf57600080fd5b6005546002546040805163413350bd60e01b81529051600093926001600160a01b03169163413350bd916004808301926020929190829003018186803b15801561221357600080fd5b505afa158015612227573d6000803e3d6000fd5b505050506040513d602081101561223d57600080fd5b5051014311905090565b6002546040805163413350bd60e01b815290516000926001600160a01b03169163413350bd916004808301926020929190829003018186803b15801561228c57600080fd5b505afa1580156122a0573d6000803e3d6000fd5b505050506040513d60208110156122b657600080fd5b50514311905090565b6001600054600160a01b900460ff1660028111156122d957fe5b14612318576040805162461bcd60e51b815260206004820152600a60248201526936bab9ba1031329037b760b11b604482015290519081900360640190fd5b6000805460ff60a01b191681556040517f369554cf721939830e3356301e1150520b7a57198eaabd24211952c158f3ba4e9190a1565b6000816020018351101561236157600080fd5b50016020015190565b600080606080606085806020019051608081101561238757600080fd5b815160208301805160405192949293830192919084600160201b8211156123ad57600080fd5b9083019060208201858111156123c257600080fd5b8251600160201b8111828201881017156123db57600080fd5b82525081516020918201929091019080838360005b838110156124085781810151838201526020016123f0565b50505050905090810190601f1680156124355780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b82111561245757600080fd5b90830190602082018581111561246c57600080fd5b8251600160201b81118282018810171561248557600080fd5b82525081516020918201929091019080838360005b838110156124b257818101518382015260200161249a565b50505050905090810190601f1680156124df5780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b82111561250157600080fd5b90830190602082018581111561251657600080fd5b8251600160201b81118282018810171561252f57600080fd5b82525081516020918201929091019080838360005b8381101561255c578181015183820152602001612544565b50505050905090810190601f1680156125895780820380516001836020036101000a031916815260200191505b506040525050509350935093505061259f61472a565b6125aa84848a613e14565b90506003816060015160068111156125be57fe5b14612610576040805162461bcd60e51b815260206004820181905260248201527f656e747279206d757374206265206f662074797065205769746864726177616c604482015290519081900360640190fd5b61262582826101200151836101400151610bd4565b61266c576040805162461bcd60e51b815260206004820152601360248201527234b73b30b634b21032b73a393c90383937b7b360691b604482015290519081900360640190fd5b60025461014082015160408051636dba4b0f60e01b81526004810192909252516001600160a01b0390921691636dba4b0f91602480820192602092909190829003018186803b1580156126be57600080fd5b505afa1580156126d2573d6000803e3d6000fd5b505050506040513d60208110156126e857600080fd5b50511561273c576040805162461bcd60e51b815260206004820152601760248201527f656e74727920616c72656164792077697468647261776e000000000000000000604482015290519081900360640190fd5b6002546101408201516040805163bb55b89360e01b81526004810192909252516001600160a01b039092169163bb55b8939160248082019260009290919082900301818387803b15801561278f57600080fd5b505af11580156127a3573d6000803e3d6000fd5b5050505080604001516001600160a01b031681602001516001600160a01b03167fa6786aab7dbbc48b4b0387488b407bd81448030ab207b50bea7dbb5fbc1cd9eb8361014001518460c00151604051808381526020018281526020019250505060405180910390a380604001518160c0015195509550505050509250929050565b6000806001600054600160a01b900460ff16600281111561284157fe5b14612880576040805162461bcd60e51b815260206004820152600a60248201526936bab9ba1031329037b760b11b604482015290519081900360640190fd5b60608060608060608780602001905160c081101561289d57600080fd5b815160208301805160405192949293830192919084600160201b8211156128c357600080fd5b9083019060208201858111156128d857600080fd5b8251600160201b8111828201881017156128f157600080fd5b82525081516020918201929091019080838360005b8381101561291e578181015183820152602001612906565b50505050905090810190601f16801561294b5780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b82111561296d57600080fd5b90830190602082018581111561298257600080fd5b82518660208202830111600160201b8211171561299e57600080fd5b82525081516020918201928201910280838360005b838110156129cb5781810151838201526020016129b3565b5050505090500160405260200180516040519392919084600160201b8211156129f357600080fd5b908301906020820185811115612a0857600080fd5b82518660208202830111600160201b82111715612a2457600080fd5b82525081516020918201928201910280838360005b83811015612a51578181015183820152602001612a39565b5050505090500160405260200180516040519392919084600160201b821115612a7957600080fd5b908301906020820185811115612a8e57600080fd5b8251600160201b811182820188101715612aa757600080fd5b82525081516020918201929091019080838360005b83811015612ad4578181015183820152602001612abc565b50505050905090810190601f168015612b015780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b821115612b2357600080fd5b908301906020820185811115612b3857600080fd5b8251600160201b811182820188101715612b5157600080fd5b82525081516020918201929091019080838360005b83811015612b7e578181015183820152602001612b66565b50505050905090810190601f168015612bab5780820380516001836020036101000a031916815260200191505b506040525050509550955095509550955050612bc56147b8565b612bd28686868686613f5c565b9050612bdc6147ea565b50805160208101516001600160a01b038c8116911614612c2d5760405162461bcd60e51b81526004018080602001828103825260278152602001806148f56027913960400191505060405180910390fd5b8060a0015163ffffffff16600260009054906101000a90046001600160a01b03166001600160a01b031663e13c96a96040518163ffffffff1660e01b815260040160206040518083038186803b158015612c8657600080fd5b505afa158015612c9a573d6000803e3d6000fd5b505050506040513d6020811015612cb057600080fd5b505163ffffffff16118015612cce575060a081015163ffffffff1615155b612d095760405162461bcd60e51b815260040180806020018281038252602b815260200180614967602b913960400191505060405180910390fd5b60025460a082015160408051630638dde560e11b815263ffffffff909216600483015251612d92926001600160a01b031691630c71bbca916024808301926020929190829003018186803b158015612d6057600080fd5b505afa158015612d74573d6000803e3d6000fd5b505050506040513d6020811015612d8a57600080fd5b505183614071565b612dcd5760405162461bcd60e51b81526004018080602001828103825260248152602001806148ab6024913960400191505060405180910390fd5b612dd6816140fc565b98509850505050505050509250929050565b6000806001600054600160a01b900460ff166002811115612e0557fe5b14612e44576040805162461bcd60e51b815260206004820152600a60248201526936bab9ba1031329037b760b11b604482015290519081900360640190fd5b6060806060858060200190516080811015612e5e57600080fd5b815160208301805160405192949293830192919084600160201b821115612e8457600080fd5b908301906020820185811115612e9957600080fd5b8251600160201b811182820188101715612eb257600080fd5b82525081516020918201929091019080838360005b83811015612edf578181015183820152602001612ec7565b50505050905090810190601f168015612f0c5780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b821115612f2e57600080fd5b908301906020820185811115612f4357600080fd5b8251600160201b811182820188101715612f5c57600080fd5b82525081516020918201929091019080838360005b83811015612f89578181015183820152602001612f71565b50505050905090810190601f168015612fb65780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b821115612fd857600080fd5b908301906020820185811115612fed57600080fd5b8251600160201b81118282018810171561300657600080fd5b82525081516020918201929091019080838360005b8381101561303357818101518382015260200161301b565b50505050905090810190601f1680156130605780820380516001836020036101000a031916815260200191505b506040525050509350935093505061307661472a565b61308184848a613e14565b905061309581602001518260400151610ee9565b156130db576040805162461bcd60e51b81526020600482015260116024820152701c1c995d9a5bdd5cdb1e48195e1a5d1959607a1b604482015290519081900360640190fd5b6130ea828261014001516120ee565b613133576040805162461bcd60e51b815260206004820152601560248201527434b73b30b634b2103130b630b731b290383937b7b360591b604482015290519081900360640190fd5b6000600560ff16600260009054906101000a90046001600160a01b03166001600160a01b031663e13c96a96040518163ffffffff1660e01b815260040160206040518083038186803b15801561318857600080fd5b505afa15801561319c573d6000803e3d6000fd5b505050506040513d60208110156131b257600080fd5b505160025461014085015160408051630c9caaf560e31b815260048101929092529390920163ffffffff166024830181905292519293506001600160a01b0316916364e557a89160448082019260009290919082900301818387803b15801561321a57600080fd5b505af115801561322e573d6000803e3d6000fd5b5050505081604001516001600160a01b031682602001516001600160a01b03167f033fd1dc81f5c58d2987171bd5432008ce60e028fd6b687900ef31dcbeee03348461014001518560e001518660a00151866040518085815260200184815260200183815260200182815260200194505050505060405180910390a35060400151976000975095505050505050565b6000806001600054600160a01b900460ff1660028111156132da57fe5b14613319576040805162461bcd60e51b815260206004820152600a60248201526936bab9ba1031329037b760b11b604482015290519081900360640190fd5b606080606085806020019051608081101561333357600080fd5b815160208301805160405192949293830192919084600160201b82111561335957600080fd5b90830190602082018581111561336e57600080fd5b8251600160201b81118282018810171561338757600080fd5b82525081516020918201929091019080838360005b838110156133b457818101518382015260200161339c565b50505050905090810190601f1680156133e15780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b82111561340357600080fd5b90830190602082018581111561341857600080fd5b8251600160201b81118282018810171561343157600080fd5b82525081516020918201929091019080838360005b8381101561345e578181015183820152602001613446565b50505050905090810190601f16801561348b5780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b8211156134ad57600080fd5b9083019060208201858111156134c257600080fd5b8251600160201b8111828201881017156134db57600080fd5b82525081516020918201929091019080838360005b838110156135085781810151838201526020016134f0565b50505050905090810190601f1680156135355780820380516001836020036101000a031916815260200191505b506040525050509350935093505061354b61472a565b61355684848a613e14565b905061356a81602001518260400151610ee9565b156135b0576040805162461bcd60e51b81526020600482015260116024820152701c1c995d9a5bdd5cdb1e48195e1a5d1959607a1b604482015290519081900360640190fd5b6135be816101400151611a7c565b6135f95760405162461bcd60e51b81526004018080602001828103825260448152602001806148466044913960600191505060405180910390fd5b61360882826101400151610ddb565b613651576040805162461bcd60e51b815260206004820152601560248201527434b73b30b634b2103130b630b731b290383937b7b360591b604482015290519081900360640190fd5b600254610140820151604080516001622a21a160e01b031981526004810192909252516001600160a01b039092169163ffd5de5f9160248082019260009290919082900301818387803b1580156136a757600080fd5b505af11580156136bb573d6000803e3d6000fd5b505050506136c8816141ea565b80604001518160e0015195509550505050509250929050565b60008080600054600160a01b900460ff1660028111156136fd57fe5b1461373d576040805162461bcd60e51b815260206004820152600b60248201526a36bab9ba1031329037b33360a91b604482015290519081900360640190fd5b606080606085806020019051608081101561375757600080fd5b815160208301805160405192949293830192919084600160201b82111561377d57600080fd5b90830190602082018581111561379257600080fd5b8251600160201b8111828201881017156137ab57600080fd5b82525081516020918201929091019080838360005b838110156137d85781810151838201526020016137c0565b50505050905090810190601f1680156138055780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b82111561382757600080fd5b90830190602082018581111561383c57600080fd5b8251600160201b81118282018810171561385557600080fd5b82525081516020918201929091019080838360005b8381101561388257818101518382015260200161386a565b50505050905090810190601f1680156138af5780820380516001836020036101000a031916815260200191505b5060405260200180516040519392919084600160201b8211156138d157600080fd5b9083019060208201858111156138e657600080fd5b8251600160201b8111828201881017156138ff57600080fd5b82525081516020918201929091019080838360005b8381101561392c578181015183820152602001613914565b50505050905090810190601f1680156139595780820380516001836020036101000a031916815260200191505b506040525050509350935093505061396f61472a565b61397a84848a613e14565b905061398e81602001518260400151610ee9565b156139d4576040805162461bcd60e51b81526020600482015260116024820152701c1c995d9a5bdd5cdb1e48195e1a5d1959607a1b604482015290519081900360640190fd5b6139e3828261014001516120ee565b613a2c576040805162461bcd60e51b815260206004820152601560248201527434b73b30b634b2103130b630b731b290383937b7b360591b604482015290519081900360640190fd5b6136c8816141ea565b60008080600054600160a01b900460ff166002811115613a5157fe5b14613a91576040805162461bcd60e51b815260206004820152600b60248201526a36bab9ba1031329037b33360a91b604482015290519081900360640190fd5b6060838060200190516040811015613aa857600080fd5b815160208301805160405192949293830192919084600160201b821115613ace57600080fd5b908301906020820185811115613ae357600080fd5b8251600160201b811182820188101715613afc57600080fd5b82525081516020918201929091019080838360005b83811015613b29578181015183820152602001613b11565b50505050905090810190601f168015613b565780820380516001836020036101000a031916815260200191505b50604052505050915050613b686147ea565b613b71826142bb565b6000548151919250600160a81b900463ffffffff908116911614613bd6576040805162461bcd60e51b81526020600482015260176024820152763737ba10333937b69031bab93932b73a103632b233b2b960491b604482015290519081900360640190fd5b856001600160a01b031681602001516001600160a01b031614613c2a5760405162461bcd60e51b81526004018080602001828103825260278152602001806148f56027913960400191505060405180910390fd5b600260009054906101000a90046001600160a01b03166001600160a01b031663e13c96a96040518163ffffffff1660e01b815260040160206040518083038186803b158015613c7857600080fd5b505afa158015613c8c573d6000803e3d6000fd5b505050506040513d6020811015613ca257600080fd5b505160a082015163ffffffff91821691161015613cf05760405162461bcd60e51b815260040180806020018281038252603e815260200180614992603e913960400191505060405180910390fd5b613cf9816140fc565b9350935050509250929050565b6001600054600160a01b900460ff166002811115613d2057fe5b14613d5f576040805162461bcd60e51b815260206004820152600a60248201526936bab9ba1031329037b760b11b604482015290519081900360640190fd5b6000805460ff60a01b1916600160a11b1781556040517fc15f68f0a72806ff3f8bf2435385a67c4c22413f1c7931ef7bcea718e6ffcf039190a1565b60408051631a93ec9560e01b815263ffffffff8316600482015290516001600160a01b03841691631a93ec9591602480830192600092919082900301818387803b158015613de857600080fd5b505af1158015613dfc573d6000803e3d6000fd5b5050600080546001600160a01b031916905550505050565b613e1c61472a565b613e26848461439b565b6000548151919250600160a81b900463ffffffff908116911614613e91576040805162461bcd60e51b815260206004820181905260248201527f656e747279206973206e6f742066726f6d2063757272656e74206c6564676572604482015290519081900360640190fd5b6003546101a08201516001600160a01b03908116911614613ef9576040805162461bcd60e51b815260206004820152601a60248201527f6661696c656420746f20766572696679207369676e6174757265000000000000604482015290519081900360640190fd5b816001600160a01b031681602001516001600160a01b031614610ce4576040805162461bcd60e51b81526020600482015260166024820152750cadce8e4f240c2c6c6deeadce840dad2e6dac2e8c6d60531b604482015290519081900360640190fd5b613f646147b8565b613f6d866142bb565b808252600054905163ffffffff908116600160a81b9092041614613fd2576040805162461bcd60e51b81526020600482015260176024820152763737ba10333937b69031bab93932b73a103632b233b2b960491b604482015290519081900360640190fd5b604051806060016040528086600081518110613fea57fe5b602002602001015181526020018560008151811061400457fe5b6020026020010151815260200184815250816020018190525060405180606001604052808660018151811061403557fe5b602002602001015181526020018560018151811061404f57fe5b6020026020010151815260200183815250816040018190525095945050505050565b600081602001516020015160010182604001516020015114801561409e5750815160c00151604083015151115b80156140b35750815160c00151602083015151105b80156140d857506020808301516040810151815191909201516140d89291869161116f565b8015610ce45750604080830151908101518151602090920151610ce492869161116f565b60025460c0820151604080516352a0c8f160e11b815260048101929092525160009283926001600160a01b039091169163a54191e291602480820192869290919082900301818387803b15801561415257600080fd5b505af1158015614166573d6000803e3d6000fd5b5050505082604001516001600160a01b031683602001516001600160a01b03167f9355bbbbf685556a4760195fdf1f0d211bfd2324584092e8c28d70bfa6b7d3fa85606001518660800151604051808381526020018263ffffffff1663ffffffff1681526020019250505060405180910390a3505060408101516060820151915091565b6002546020820151604080840151815163c1308df360e01b81526001600160a01b03938416600482015290831660248201529051919092169163c1308df391604480830192600092919082900301818387803b15801561424957600080fd5b505af115801561425d573d6000803e3d6000fd5b5050505080604001516001600160a01b031681602001516001600160a01b03167f104ad9ab27213fcc307f2308fc015959def8986f04d9475d82c5f32ab9c8d83b8360e001516040518082815260200191505060405180910390a350565b6142c36147ea565b6142d482600063ffffffff61461716565b63ffffffff90811682526142ed90839060049061463316565b6001600160a01b0316602082015261430c82601863ffffffff61463316565b6001600160a01b0316604082015261432b82602c63ffffffff61234e16565b606082015261434182604c63ffffffff61461716565b63ffffffff908116608083015261435d90839060509061461716565b63ffffffff1660a082018190528151602083015160408401516060850151608086015161438995611e40565b805160209091012060c0820152919050565b6143a361472a565b6143b483600163ffffffff61461716565b63ffffffff90811682526143cd90849060059061463316565b6001600160a01b031660208201526143ec83601963ffffffff61463316565b6001600160a01b0316604082015261440b83602d63ffffffff61465616565b60ff16600681111561441957fe5b8160600190600681111561442957fe5b9081600681111561443657fe5b90525061444a83602e63ffffffff61465616565b60ff16608082015261446383602f63ffffffff61467216565b67ffffffffffffffff1660a082015261448383603763ffffffff61234e16565b60c082015261449983605763ffffffff61234e16565b60e08201526144af83607763ffffffff61468e16565b6fffffffffffffffffffffffffffffffff166101008201526144d883608763ffffffff61461716565b63ffffffff9081166101208301526144f5908490608b9061234e16565b6101608201528251839060ab10156145e857835161452190859060ab9060aa190163ffffffff6146aa16565b6101c083018190526040518151819060208401908083835b602083106145585780518252601f199092019160209182019101614539565b6001836020036101000a0380198251168184511680821785525050505050509050019150506040518091039020826101600151146145d2576040805162461bcd60e51b81526020600482015260126024820152710c8c2e8c240d0c2e6d040dad2e6dac2e8c6d60731b604482015290519081900360640190fd5b6145e584600060ab63ffffffff6146aa16565b90505b8051602082012061014083018190526146019084610d0d565b6001600160a01b03166101a08301525092915050565b6000816004018351101561462a57600080fd5b50016004015190565b6000816014018351101561464657600080fd5b500160200151600160601b900490565b6000816001018351101561466957600080fd5b50016001015190565b6000816008018351101561468557600080fd5b50016008015190565b600081601001835110156146a157600080fd5b50016010015190565b6060818301845110156146bc57600080fd5b6060821580156146d757604051915060208201604052614721565b6040519150601f8416801560200281840101858101878315602002848b0101015b818310156147105780518352602092830192016146f8565b5050858452601f01601f1916604052505b50949350505050565b604080516101e0810182526000808252602082018190529181018290529060608201908152602001600060ff16815260200160008152602001600081526020016000815260200160008152602001600063ffffffff16815260200160008019168152602001600080191681526020016060815260200160006001600160a01b03168152602001606081525090565b60405180606001604052806147cb6147ea565b81526020016147d8614826565b81526020016147e5614826565b905290565b6040805160e081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c081019190915290565b604080516060808201835260008083526020830152918101919091529056fe6e6f207072696f7220636c61696d20666f756e6420746f207769746864726177204f522062616c616e636573206172652079657420746f20626520636f6e6669726d6564696e76616c69642073656e6465723b206d75737420626520617070206f776e65726661696c656420746f2070726f6f66206578636c7573696f6e206f66206465706f736974696e76616c69642073656e6465723b206d75737420626520676c756f6e20636f6e7472616374636c61696d616e74206d75737420626520746865206f726967696e616c206465706f7369746f7267626c6f636b206d75737420626520746865206e65787420696e2073657175656e6365696e76616c69642073656e6465723b206d7573742062652075706772616465206f70657261746f7264657369676e617465642067626c6f636b20697320756e636f6e6669726d6564206f7220756e6b6e6f776e64657369676e617465642067626c6f636b20697320616c726561647920636f6e6669726d65643b2075736520657869744f6e48616c7420696e7374656164a265627a7a7231582004bd562715ccf4de686c0b152448638a6ba647e5c549aea1369ac5a976b24faa64736f6c634300050c0032
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000000000000000000000000000000000000000000200000000000000000000000075ace7a086ea0fb1a79e43cc6331ad053d8c67cb0000000000000000000000000d283d685f0a741c463846176e4c8eff90d3f9ec0000000000000000000000005ccaaae7bea14e8e04fb0fc7ed16df49d5678eb800000000000000000000000000000000000000000000000000000000000000240000000000000000000000000000000000000000000000000000000000009d80
-----Decoded View---------------
Arg [0] : id (uint32): 2
Arg [1] : gluon (address): 0x75ACe7a086eA0FB1a79e43Cc6331Ad053d8C67cB
Arg [2] : data_ (address): 0x0d283D685F0A741C463846176e4c8EFF90D3F9EC
Arg [3] : operator_ (address): 0x5CcAAAE7Bea14E8e04FB0FC7ED16DF49d5678Eb8
Arg [4] : submissionInterval_ (uint256): 36
Arg [5] : abandonPoint_ (uint256): 40320
-----Encoded View---------------
6 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000002
Arg [1] : 00000000000000000000000075ace7a086ea0fb1a79e43cc6331ad053d8c67cb
Arg [2] : 0000000000000000000000000d283d685f0a741c463846176e4c8eff90d3f9ec
Arg [3] : 0000000000000000000000005ccaaae7bea14e8e04fb0fc7ed16df49d5678eb8
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000024
Arg [5] : 0000000000000000000000000000000000000000000000000000000000009d80
Swarm Source
bzzr://04bd562715ccf4de686c0b152448638a6ba647e5c549aea1369ac5a976b24faa
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
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.