Contract 0x944644ea989ec64c2ab9ef341d383cef586a5777

 
Ad
Crypto.com
Txn Hash Method
Block
From
To
Value
0xcd18f5f2b7c5be612deecaac676767ac95e36c00f5faca16a7a380fbbba0fb8aWithdraw From Me...(pending)2021-07-25 2:30:551 day 59 mins ago0x2004de6c092acbacce29244d45d7abadd5084ac7 IN LoopringDEX: Beta 10 Ether(Pending)(Pending)
0xe150e27d8746b64965453ec097a11548170aa5865688362f3fc75a0a2414b9e3Withdraw123454802021-05-01 1:58:3486 days 1 hr ago0x2584cd4eac415b8fc5acc02cc6e552b13110592f IN  LoopringDEX: Beta 10 Ether0.0024171330
0x64fbe5c786fe39afce140ce63f958429b804403d8951ac42ce99eedbb13078ecDrain120107992021-03-10 12:30:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.006855955115
0x939d1ba4843797a203210d034230590ad4db2cb65debf077c0efd95f10117afcDrain120107992021-03-10 12:30:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.007094005115
0x3070487547c92f70633f649546bce8bf6ea679b6f3c1697ca67d6d96c13f21faDrain120107992021-03-10 12:30:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.00595677115
0x27d340fb8a2f8b8658848e3170c26aeb1e57ddba1dbda84798d83c66edc0c4b8Drain120107992021-03-10 12:30:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.007202105115
0xb2a528d113de2da8c92995ecad8352d3d3397c2bd1b545b4e074cde984124284Drain120107992021-03-10 12:30:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.00615572115
0x4f1dfb2785f21fd4457ce2995ab29ad4909621136d7009139c11e1eb67d4a537Drain120107992021-03-10 12:30:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.006356625115
0xe51fbd55478e52b677b590d5892c43c29073fbe12893c2e0829d8e6e1bbe2577Drain120107992021-03-10 12:30:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.006121335115
0x8d3c47c9790d89acedce8aa032ae0a33e3e02b21626c2d2b49d0db896bc9f4bdDrain120107992021-03-10 12:30:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.005973675115
0x6e795ed1ec0870bbb739e52df2968c4816a4d55ee9e3610d6131d3ea72bcef65Drain120107992021-03-10 12:30:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.010283185115
0xdd51cb8f5db9e6f403895cbb46f8c4aaf7ee284ef891b27ea372cf7475e782f7Drain120107992021-03-10 12:30:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.007307445115
0xb7054856f0fe291dc37bafb4e6c081d516c58c5060485af5956e865b9c8db861Drain120107992021-03-10 12:30:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.006496695115
0x53225a526dffa676654b6814e407c2c937ad6793d094c26d101556acc44321e4Drain120107992021-03-10 12:30:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.00616354115
0xb5466b98d4abe7abae87ffffcf464af7c2328dfcbeebb209773529efd58cfdf7Drain120107992021-03-10 12:30:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.00461909115
0x4b2bac20b5aac0803e02f3ed398d7c4d71e84b520b95f706bad4cb6800a4dc45Drain120107902021-03-10 12:26:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.00596206115
0xd5e8234c75e45dcc1969ab209c1d15f79c284205cb4940ec6bb958bddd49be1aDrain120107902021-03-10 12:26:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.007203025115
0xcd399585f98147a0859812447fefd8b4d7761fa86433b7920a4e465d0407715fDrain120107902021-03-10 12:26:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.006369965115
0x979a13cc76d6005813d3f19c142aa1a9173385740f0597c22c71be214f60dd44Drain120107902021-03-10 12:26:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.0070035115
0x267d8ece3f86adc27e667d3d5486c4b10dca618c52fc619dfb17ce9f480306ddDrain120107902021-03-10 12:26:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.00602991115
0xc084d89570872375352972cfa79701e923e2a015cb068772d593ee78663ccd6bDrain120107902021-03-10 12:26:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.004231885115
0x8dfd7f5745bf6895a620f5eaea6e97d8b40077e2793b69407532ec851853fa38Drain120107902021-03-10 12:26:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.0061088115
0xf68c2b57eb2097b613c662ccec38573a318f20a58f3fb543e70e21234c27c0cdDrain120107902021-03-10 12:26:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.01336208115
0x0a3b3a7b0144926861e5d0f0a99259b127e9144d84086970ee885d3719740ff6Drain120107902021-03-10 12:26:14137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.00621115115
0x0a2e0ec037cf9e97957f1ac46c836362c89ae0c3d20a842388fe531e3bc642d6Drain120107802021-03-10 12:25:02137 days 15 hrs agoLoopring: Deployer 2 IN  LoopringDEX: Beta 10 Ether0.007410485115
[ Download CSV Export 
Latest 25 internal transaction
Parent Txn Hash Block From To Value
0xb5466b98d4abe7abae87ffffcf464af7c2328dfcbeebb209773529efd58cfdf7120107992021-03-10 12:30:14137 days 15 hrs ago LoopringDEX: Beta 10x3df7f4c6887c4e3ade159bc93b6732770d80cb2b374.646260287377009641 Ether
0xeb04fb97a13ee3a081703ecbc24a5893188b967395002ab9b7916c3b46d90de3117805312021-02-03 2:19:23173 days 1 hr ago LoopringDEX: Beta 1Vite: Deployer 10.01099999 Ether
0x061c06a874c9fc565f1e4ea75e4a50355be5caf5de7399ade66e7c0000b69b58117736332021-02-02 0:44:58174 days 2 hrs ago LoopringDEX: Beta 10x025cf74797327e5bb59aab867577bfae6d7336cf0.4899 Ether
0x31633995bbb3df5256fcfc597242ec7412516f95559ef0e6f7574cc71a930a82117634692021-01-31 11:11:55175 days 16 hrs ago LoopringDEX: Beta 10x931292c42a5f600e80d75b7c7743f0164240882c0.68 Ether
0xa27123d095b2c9bb8aca9b0d5e1318d20ae943cd8ab4cebd282457f0859585bb117567822021-01-30 10:40:19176 days 16 hrs ago LoopringDEX: Beta 10xe2f35b376461e7fdd2f2e45248e4c3cd9626a93326.7891 Ether
0xd512880842b024ba3b7a0073f0074ff01bc9e83f860105b1c0e30448b970a9d8117554512021-01-30 5:36:19176 days 21 hrs ago LoopringDEX: Beta 10xd36aab2f2e6b2192f7bb0c092ba332f7f558be7f0.311 Ether
0x4e43daf619d56fa0f9d0f7181c32efb98ad256968336f76372e8ab410ac37f2c117529022021-01-29 20:15:17177 days 7 hrs ago LoopringDEX: Beta 10x4a9287218aadfae67ff4440921c58b6d6ba8a20a0.0561 Ether
0xadb99c071b60facb07a38e52cbd961634ef015840dd40126723f8b7673cf4509117518192021-01-29 16:20:49177 days 11 hrs ago LoopringDEX: Beta 10x494a3c1a6c2b270f116173719b5b8c6622c9c8880.45 Ether
0xb887667de55df51fe64f50d987b9b81520a216c0bdf4edcaab91e47c73c35fef117490112021-01-29 5:49:57177 days 21 hrs ago LoopringDEX: Beta 10x878098db471d1bbc6a1cb76f118da5862f0376d60.1065 Ether
0xb887667de55df51fe64f50d987b9b81520a216c0bdf4edcaab91e47c73c35fef117490112021-01-29 5:49:57177 days 21 hrs ago LoopringDEX: Beta 1 0xd29a5c212723b0a51ded27623f48ce56ca2770f55.6615 Ether
0x4a2ae5bb56d5c25cffd6e5dcd24fcdc83f2b9e4fa2a516ce1a38875cf4bd2ff5117452832021-01-28 16:08:43178 days 11 hrs ago LoopringDEX: Beta 10x1f017da4a5aad0ad45c9f873048267d80307ef610.1123 Ether
0x4a2ae5bb56d5c25cffd6e5dcd24fcdc83f2b9e4fa2a516ce1a38875cf4bd2ff5117452832021-01-28 16:08:43178 days 11 hrs ago LoopringDEX: Beta 10xdf33b0500e6232904594704730e557683303dfd60.9999 Ether
0x4a2ae5bb56d5c25cffd6e5dcd24fcdc83f2b9e4fa2a516ce1a38875cf4bd2ff5117452832021-01-28 16:08:43178 days 11 hrs ago LoopringDEX: Beta 10x06f94772b2899737f110a15ebcecf15c0447928d1.5662 Ether
0x4a2ae5bb56d5c25cffd6e5dcd24fcdc83f2b9e4fa2a516ce1a38875cf4bd2ff5117452832021-01-28 16:08:43178 days 11 hrs ago LoopringDEX: Beta 10xa4af8ab8d4b63481a9994e6ac694a4abf0bd42ba0.09 Ether
0x3c5ebe8815153a1144437f7c9ee779ba7c9d6e8a6ad9c328bb62e4e076e00346117438122021-01-28 10:37:14178 days 16 hrs ago LoopringDEX: Beta 10x1941b8cdab08d5b3cd6b1a08f91a8201551ba1300.4998 Ether
0x5a236bb30aace491e85987ec09870e60b26eb0eaef4edb37ca96ae23b119b4ee117399092021-01-27 20:05:51179 days 7 hrs ago LoopringDEX: Beta 10x009b56330ae5ec5042b9ca46ddb3043cc0d006f30.2115 Ether
0x1f5cf8491c7398a7846e7ebe6daf83eb93dc25ad7cb1ad370e016b946a0732de117375462021-01-27 11:27:05179 days 16 hrs ago LoopringDEX: Beta 1ENS Name meowzit.eth0.48 Ether
0x1f5cf8491c7398a7846e7ebe6daf83eb93dc25ad7cb1ad370e016b946a0732de117375462021-01-27 11:27:05179 days 16 hrs ago LoopringDEX: Beta 10x34fc13afee91f5db6493e977fd18faef678aaa0620 Ether
0xf2adf4874dcda896de47d5a60909df379b4a4ae12a4d8996372c9deba548dd55117359882021-01-27 5:40:44179 days 21 hrs ago LoopringDEX: Beta 10x43dc2de6045dbf0f424fa30a7190d7dab0bfdd060.0513 Ether
0xf2adf4874dcda896de47d5a60909df379b4a4ae12a4d8996372c9deba548dd55117359882021-01-27 5:40:44179 days 21 hrs ago LoopringDEX: Beta 10x4c9f416d2a354087ce0a50352316262ade0aa51a0.05 Ether
0xf05c602bc93e2fa95bdd8aa4766a7b615fd32b0b5db7c6feb40b44f8fe59dabc117337802021-01-26 21:25:09180 days 6 hrs ago LoopringDEX: Beta 10x20ede6c4fc25dbe190d9dea7baa1b7b6782283750.0203 Ether
0xabefd1446e24f7611d274b404814e13e454e6bbe8c09a5e704915da9a6c3785b117307942021-01-26 10:39:11180 days 16 hrs ago LoopringDEX: Beta 10xd2073ca5a4c8382e34d921130960a23a646f94620.1213 Ether
0x366475edb34bbd44f2e82361bac9a572a9929ad442f346b5f4fbd5c1cce45023117126882021-01-23 15:41:33183 days 11 hrs ago LoopringDEX: Beta 10x7f4f269953eef504732ec8ab24b1b6daed6885ae0.105 Ether
0xae4073e95444d6038cc8e3b3cfe14ee4b01ee01a56879cb87b347c0578d1f57a117099732021-01-23 5:35:36183 days 21 hrs ago LoopringDEX: Beta 10xfcc993d70b19c78374cb280f952bac2aa589af991.1606 Ether
0x8d7eac53bd74f7b439ff3180f6ee7fd683e966343a757471a563a2d2f301a540117022542021-01-22 0:56:46185 days 2 hrs ago LoopringDEX: Beta 10xc8f7b747eefc216964e567c14ec823d17d25c9320.2101 Ether
[ Download CSV Export 
Loading

Contract Source Code Verified (Similar Match)
Note: This contract matches the deployed ByteCode of the Source Code for Contract 0xD97D09f3bd931a14382ac60f156C1285a56Bb51B

Contract Name:
AutoUpgradabilityProxy

Compiler Version
v0.5.11+commit.c082d0b4

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion, None license
/**
 *Submitted for verification at Etherscan.io on 2020-01-13
*/

/**
 *Submitted for verification at Etherscan.io on 2019-12-05
*/

/*

  Copyright 2017 Loopring Project Ltd (Loopring Foundation).

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

  http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
*/
pragma solidity ^0.5.11;


/// @title ReentrancyGuard
/// @author Brecht Devos - <[email protected]>
/// @dev Exposes a modifier that guards a function against reentrancy
///      Changing the value of the same storage value multiple times in a transaction
///      is cheap (starting from Istanbul) so there is no need to minimize
///      the number of times the value is changed
contract ReentrancyGuard
{
    //The default value must be 0 in order to work behind a proxy.
    uint private _guardValue;

    // Use this modifier on a function to prevent reentrancy
    modifier nonReentrant()
    {
        // Check if the guard value has its original value
        require(_guardValue == 0, "REENTRANCY");

        // Set the value to something else
        _guardValue = 1;

        // Function body
        _;

        // Set the value back
        _guardValue = 0;
    }
}
/*

  Copyright 2017 Loopring Project Ltd (Loopring Foundation).

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

  http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
*/


/*

  Copyright 2017 Loopring Project Ltd (Loopring Foundation).

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

  http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
*/



/// @title Ownable
/// @author Brecht Devos - <[email protected]>
/// @dev The Ownable contract has an owner address, and provides basic
///      authorization control functions, this simplifies the implementation of
///      "user permissions".
contract Ownable
{
    address public owner;

    event OwnershipTransferred(
        address indexed previousOwner,
        address indexed newOwner
    );

    /// @dev The Ownable constructor sets the original `owner` of the contract
    ///      to the sender.
    constructor()
        public
    {
        owner = msg.sender;
    }

    /// @dev Throws if called by any account other than the owner.
    modifier onlyOwner()
    {
        require(msg.sender == owner, "UNAUTHORIZED");
        _;
    }

    /// @dev Allows the current owner to transfer control of the contract to a
    ///      new owner.
    /// @param newOwner The address to transfer ownership to.
    function transferOwnership(
        address newOwner
        )
        public
        onlyOwner
    {
        require(newOwner != address(0), "ZERO_ADDRESS");
        emit OwnershipTransferred(owner, newOwner);
        owner = newOwner;
    }

    function renounceOwnership()
        public
        onlyOwner
    {
        emit OwnershipTransferred(owner, address(0));
        owner = address(0);
    }
}



/// @title Claimable
/// @author Brecht Devos - <[email protected]>
/// @dev Extension for the Ownable contract, where the ownership needs
///      to be claimed. This allows the new owner to accept the transfer.
contract Claimable is Ownable
{
    address public pendingOwner;

    /// @dev Modifier throws if called by any account other than the pendingOwner.
    modifier onlyPendingOwner() {
        require(msg.sender == pendingOwner, "UNAUTHORIZED");
        _;
    }

    /// @dev Allows the current owner to set the pendingOwner address.
    /// @param newOwner The address to transfer ownership to.
    function transferOwnership(
        address newOwner
        )
        public
        onlyOwner
    {
        require(newOwner != address(0) && newOwner != owner, "INVALID_ADDRESS");
        pendingOwner = newOwner;
    }

    /// @dev Allows the pendingOwner address to finalize the transfer.
    function claimOwnership()
        public
        onlyPendingOwner
    {
        emit OwnershipTransferred(owner, pendingOwner);
        owner = pendingOwner;
        pendingOwner = address(0);
    }
}
/*

  Copyright 2017 Loopring Project Ltd (Loopring Foundation).

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

  http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
*/






/// @title IUniversalRegistry
/// @dev This contract manages all registered ILoopring versions and all Loopring
///      based exchanges.
///
/// @author Daniel Wang  - <[email protected]>
contract IUniversalRegistry is Claimable, ReentrancyGuard
{
    enum ForgeMode {
        AUTO_UPGRADABLE,
        MANUAL_UPGRADABLE,
        PROXIED,
        NATIVE
    }

    /// === Events ===

    event ProtocolRegistered (
        address indexed protocol,
        address indexed implementationManager,
        string          version
    );

    event ProtocolEnabled (
        address indexed protocol
    );

    event ProtocolDisabled (
        address indexed protocol
    );

    event DefaultProtocolChanged (
        address indexed oldDefault,
        address indexed newDefault
    );

    event ExchangeForged (
        address indexed protocol,
        address indexed implementation,
        address indexed exchangeAddress,
        address         owner,
        ForgeMode       forgeMode,
        bool            onchainDataAvailability,
        uint            exchangeId,
        uint            amountLRCBurned
    );

    /// === Data ===

    address   public lrcAddress;
    address[] public exchanges;
    address[] public protocols;

    // IProtocol.version => IProtocol address
    mapping (string => address) public versionMap;

    /// === Functions ===

    /// @dev Registers a new protocol.
    /// @param protocol The address of the new protocol.
    /// @param implementation The new protocol's default implementation.
    /// @return implManager A new implementation manager to manage the protocol's implementations.
    function registerProtocol(
        address protocol,
        address implementation
        )
        external
        returns (address implManager);

    /// @dev Sets the default protocol.
    /// @param protocol The new default protocol.
    function setDefaultProtocol(
        address protocol
        )
        external;

    /// @dev Enables a protocol.
    /// @param protocol The address of the protocol.
    function enableProtocol(
        address protocol
        )
        external;

    /// @dev Disables a protocol.
    /// @param protocol The address of the protocol.
    function disableProtocol(
        address protocol
        )
        external;

    /// @dev Creates a new exchange using a specific protocol with msg.sender
    ///      as owner and operator.
    /// @param forgeMode The forge mode.
    /// @param onchainDataAvailability IF the on-chain DA is on
    /// @param protocol The protocol address, use 0x0 for default.
    /// @param implementation The implementation to use, use 0x0 for default.
    /// @return exchangeAddress The new exchange's address
    /// @return exchangeId The new exchange's ID.
    function forgeExchange(
        ForgeMode forgeMode,
        bool      onchainDataAvailability,
        address   protocol,
        address   implementation
        )
        external
        returns (
            address exchangeAddress,
            uint    exchangeId
        );

    /// @dev Returns information regarding the default protocol.
    /// @return protocol The address of the default protocol.
    /// @return implManager The address of the default protocol's implementation manager.
    /// @return defaultImpl The default protocol's default implementation address.
    /// @return defaultImplVersion The version of the default implementation.
    function defaultProtocol()
        public
        view
        returns (
            address protocol,
            address versionmanager,
            address defaultImpl,
            string  memory protocolVersion,
            string  memory defaultImplVersion
        );

    /// @dev Checks if a protocol has been registered.
    /// @param protocol The address of the protocol.
    /// @return registered True if the prococol is registered.
    function isProtocolRegistered(
        address protocol
        )
        public
        view
        returns (bool registered);

    /// @dev Checks if a protocol has been enabled.
    /// @param protocol The address of the protocol.
    /// @return enabled True if the prococol is registered and enabled.
    function isProtocolEnabled(
        address protocol
        )
        public
        view
        returns (bool enabled);

    /// @dev Checks if the addres is a registered Loopring exchange.
    /// @return registered True if the address is a registered exchange.
    function isExchangeRegistered(
        address exchange
        )
        public
        view
        returns (bool registered);

    /// @dev Checks if the given protocol and implementation are both registered and enabled.
    /// @param protocol The address of the protocol.
    /// @param implementation The address of the implementation.
    /// @return enabled True if both the protocol and the implementation are registered and enabled.
    function isProtocolAndImplementationEnabled(
        address protocol,
        address implementation
        )
        public
        view
        returns (bool enabled);

    /// @dev Returns the protocol associated with an exchange.
    /// @param exchangeAddress The address of the exchange.
    /// @return protocol The protocol address.
    /// @return implementation The protocol's implementation.
    /// @return enabled Whether the protocol is enabled.
    function getExchangeProtocol(
        address exchangeAddress
        )
        public
        view
        returns (
            address protocol,
            address implementation
        );
}/*

  Copyright 2017 Loopring Project Ltd (Loopring Foundation).

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

  http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
*/






/// @title IImplementationManager
/// @dev This contract manages implementation versions for a specific ILoopring
///      contract. The ILoopring contract can be considered as the "major" version
///      of a Loopring protocol and each IExchange implementation can be considered
///      as a "minor" version. Multiple IExchange contracts can use the same
///      ILoopring contracts.
///
/// @author Daniel Wang  - <[email protected]>
contract IImplementationManager is Claimable, ReentrancyGuard
{
    /// === Events ===

    event DefaultChanged (
        address indexed oldDefault,
        address indexed newDefault
    );

    event Registered (
        address indexed implementation,
        string          version
    );

    event Enabled (
        address indexed implementation
    );

    event Disabled (
        address indexed implementation
    );

    /// === Data ===

    address   public protocol;
    address   public defaultImpl;
    address[] public implementations;

    // version strings => IExchange addresses
    mapping (string => address) public versionMap;

    /// === Functions ===

    /// @dev Registers a new implementation.
    /// @param implementation The implemenation to add.
    function register(
        address implementation
        )
        external;

    /// @dev Sets the default implemenation.
    /// @param implementation The new default implementation.
    function setDefault(
        address implementation
        )
        external;

    /// @dev Enables an implemenation.
    /// @param implementation The implementation to be enabled.
    function enable(
        address implementation
        )
        external;

    /// @dev Disables an implemenation.
    /// @param implementation The implementation to be disabled.
    function disable(
        address implementation
        )
        external;

    /// @dev Returns version information.
    /// @return protocolVersion The protocol's version.
    /// @return defaultImplVersion The default implementation's version.
    function version()
        public
        view
        returns (
            string  memory protocolVersion,
            string  memory defaultImplVersion
        );

    /// @dev Returns the latest implemenation added.
    /// @param implementation The latest implemenation added.
    function latest()
        public
        view
        returns (address implementation);

    /// @dev Returns if an implementation has been registered.
    /// @param registered True if the implementation is registered.
    function isRegistered(
        address implementation
        )
        public
        view
        returns (bool registered);

    /// @dev Returns if an implementation has been registered and enabled.
    /// @param enabled True if the implementation is registered and enabled.
    function isEnabled(
        address implementation
        )
        public
        view
        returns (bool enabled);
}/*

  Copyright 2017 Loopring Project Ltd (Loopring Foundation).

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

  http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
*/


/*

  Copyright 2017 Loopring Project Ltd (Loopring Foundation).

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

  http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
*/


// This code is taken from https://github.com/OpenZeppelin/openzeppelin-labs
// with minor modifications.




/**
 * @title Proxy
 * @dev Gives the possibility to delegate any call to a foreign implementation.
 */
contract Proxy {
  /**
  * @dev Tells the address of the implementation where every call will be delegated.
  * @return address of the implementation to which it will be delegated
  */
  function implementation() public view returns (address);

  /**
  * @dev Fallback function allowing to perform a delegatecall to the given implementation.
  * This function will return whatever the implementation call returns
  */
  function () payable external {
    address _impl = implementation();
    require(_impl != address(0));

    assembly {
      let ptr := mload(0x40)
      calldatacopy(ptr, 0, calldatasize)
      let result := delegatecall(gas, _impl, ptr, calldatasize, 0, 0)
      let size := returndatasize
      returndatacopy(ptr, 0, size)

      switch result
      case 0 { revert(ptr, size) }
      default { return(ptr, size) }
    }
  }
}





/// @title IExchangeProxy
/// @author Daniel Wang  - <[email protected]>
contract IExchangeProxy is Proxy
{
    bytes32 private constant registryPosition = keccak256(
        "org.loopring.protocol.v3.registry"
    );

    constructor(address _registry)
        public
    {
        setRegistry(_registry);
    }

    /// @dev Returns the exchange's registry address.
    function registry()
        public
        view
        returns (address registryAddress)
    {
        bytes32 position = registryPosition;
        assembly { registryAddress := sload(position) }
    }

    /// @dev Returns the exchange's protocol address.
    function protocol()
        public
        view
        returns (address protocolAddress)
    {
        IUniversalRegistry r = IUniversalRegistry(registry());
        (protocolAddress, ) = r.getExchangeProtocol(address(this));
    }

    function setRegistry(address _registry)
        private
    {
        require(_registry != address(0), "ZERO_ADDRESS");
        bytes32 position = registryPosition;
        assembly { sstore(position, _registry) }
    }
}




/// @title AutoUpgradabilityProxy
/// @dev This proxy is designed to support automatic upgradability.
/// @author Daniel Wang  - <[email protected]>
contract AutoUpgradabilityProxy is IExchangeProxy
{
    constructor(address _registry) public IExchangeProxy(_registry) {}

    function implementation()
        public
        view
        returns (address)
    {
        IUniversalRegistry r = IUniversalRegistry(registry());
        (, address managerAddr) = r.getExchangeProtocol(address(this));
        return IImplementationManager(managerAddr).defaultImpl();
    }
}

Contract Security Audit

Contract ABI

[{"constant":true,"inputs":[],"name":"implementation","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"registry","outputs":[{"internalType":"address","name":"registryAddress","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"protocol","outputs":[{"internalType":"address","name":"protocolAddress","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_registry","type":"address"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"payable":true,"stateMutability":"payable","type":"fallback"}]

608060405234801561001057600080fd5b506040516103db3803806103db8339818101604052602081101561003357600080fd5b505180610048816001600160e01b0361004f16565b50506100e6565b6001600160a01b0381166100c457604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f5a45524f5f414444524553530000000000000000000000000000000000000000604482015290519081900360640190fd5b600060405180806103ba60219139604051908190036021019020929092555050565b6102c5806100f56000396000f3fe6080604052600436106100345760003560e01c80635c60da1b146100785780637b103999146100a95780638ce74426146100be575b600061003e6100d3565b90506001600160a01b03811661005357600080fd5b60405136600082376000803683855af43d806000843e818015610074578184f35b8184fd5b34801561008457600080fd5b5061008d6100d3565b604080516001600160a01b039092168252519081900360200190f35b3480156100b557600080fd5b5061008d6101c8565b3480156100ca57600080fd5b5061008d6101eb565b6000806100de6101c8565b60408051633a731b2f60e11b815230600482015281519293506000926001600160a01b038516926374e6365e9260248082019391829003018186803b15801561012657600080fd5b505afa15801561013a573d6000803e3d6000fd5b505050506040513d604081101561015057600080fd5b506020908101516040805163631ffbf360e01b815290519193506001600160a01b0384169263631ffbf392600480840193829003018186803b15801561019557600080fd5b505afa1580156101a9573d6000803e3d6000fd5b505050506040513d60208110156101bf57600080fd5b50519250505090565b600080604051808061027060219139604051908190036021019020549392505050565b6000806101f66101c8565b60408051633a731b2f60e11b815230600482015281519293506001600160a01b038416926374e6365e92602480840193919291829003018186803b15801561023d57600080fd5b505afa158015610251573d6000803e3d6000fd5b505050506040513d604081101561026757600080fd5b50519291505056fe6f72672e6c6f6f7072696e672e70726f746f636f6c2e76332e7265676973747279a265627a7a723158206b637acb6d50c12eb63348b284a4be3e4b2a319c97c1b962ebb15a959e9f327e64736f6c634300050b00326f72672e6c6f6f7072696e672e70726f746f636f6c2e76332e726567697374727900000000000000000000000036f568ef555df25be4b6e15d16994f3a8374214e

Deployed ByteCode Sourcemap

19180:435:0:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;17458:13;17474:16;:14;:16::i;:::-;17458:32;-1:-1:-1;;;;;;17505:19:0;;17497:28;;;;;;17569:4;17563:11;17603:12;17600:1;17595:3;17582:34;17685:1;17682;17668:12;17663:3;17656:5;17651:3;17638:49;17707:14;17752:4;17749:1;17744:3;17729:28;17774:6;17788:28;;;;17846:4;17841:3;17834:17;17788:28;17809:4;17804:3;17797:17;19312:300;;8:9:-1;5:2;;;30:1;27;20:12;5:2;19312:300:0;;;:::i;:::-;;;;-1:-1:-1;;;;;19312:300:0;;;;;;;;;;;;;;18269:209;;8:9:-1;5:2;;;30:1;27;20:12;5:2;18269:209:0;;;:::i;18541:239::-;;8:9:-1;5:2;;;30:1;27;20:12;5:2;18541:239:0;;;:::i;19312:300::-;19386:7;19411:20;19453:10;:8;:10::i;:::-;19501:36;;;-1:-1:-1;;;19501:36:0;;19531:4;19501:36;;;;;;19411:53;;-1:-1:-1;19478:19:0;;-1:-1:-1;;;;;19501:21:0;;;;;:36;;;;;;;;;;;:21;:36;;;5:2:-1;;;;30:1;27;20:12;5:2;19501:36:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;19501:36:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;19501:36:0;;;;;;19555:49;;-1:-1:-1;;;19555:49:0;;;;19501:36;;-1:-1:-1;;;;;;19555:47:0;;;;;:49;;;;;;;;;;:47;:49;;;5:2:-1;;;;30:1;27;20:12;5:2;19555:49:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;19555:49:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;19555:49:0;;-1:-1:-1;;;19312:300:0;:::o;18269:209::-;18337:23;18378:16;18042:62;;;;;;;;;;;;;;;;;;18454:15;;18433:38;-1:-1:-1;;;18433:38:0:o;18541:239::-;18609:23;18650:20;18692:10;:8;:10::i;:::-;18736:36;;;-1:-1:-1;;;18736:36:0;;18766:4;18736:36;;;;;;18650:53;;-1:-1:-1;;;;;;18736:21:0;;;;;:36;;;;;;;;;;;;;:21;:36;;;5:2:-1;;;;30:1;27;20:12;5:2;18736:36:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;18736:36:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;18736:36:0;;18541:239;-1:-1:-1;;18541:239:0:o

Swarm Source

bzzr://6b637acb6d50c12eb63348b284a4be3e4b2a319c97c1b962ebb15a959e9f327e
Block Transaction Difficulty Gas Used Reward
Block Uncle Number Difficulty Gas Used Reward
Loading
Loading
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.