Token MCDEX Token

 

Overview ERC20

Price
$4.42 @ 0.003418 ETH (+5.15%)
Fully Diluted Market Cap
Total Supply:
3,293,164.216689 MCB

Holders:
3,595 addresses
Balance
3,109.134261160975344528 MCB

Value
$13,750.53 ( ~10.6283 ETH) [0.0944%]
0xdcc3ac7668d46f44434bf1ffe57a37e25ca3acf3
Loading
[ Download CSV Export  ] 
Loading
[ Download CSV Export  ] 
Loading

OVERVIEW

Monte Carlo Decentralized Exchange is a crypto trading platform. MCDEX is powered by the Mai Protocol smart contracts deployed on the Ethereum blockchain. The Mai Protocol smart contracts are fully audited by Open Zeppelin, Consensys, and Chain Security.

Market

Volume (24H):$71,729.89
Market Capitalization:$8,200,326.83
Circulating Supply:1,854,178.00 MCB
Market Data Source: Coinmarketcap


Update? Click here to update the token ICO / general information
# Exchange Pair Price  24H Volume % Volume

Contract Source Code Verified (Exact Match)

Contract Name:
TransparentUpgradeableProxy

Compiler Version
v0.7.6+commit.7338295f

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion, MIT license
/**
 *Submitted for verification at Etherscan.io on 2021-08-31
*/

/**
 *Submitted for verification at arbiscan.io on 2021-08-31
*/

pragma solidity >=0.6.0 <0.8.0;


abstract contract Proxy {
    
    function _delegate(address implementation) internal virtual {
        
        assembly {
            
            
            
            calldatacopy(0, 0, calldatasize())

            
            
            let result := delegatecall(gas(), implementation, 0, calldatasize(), 0, 0)

            
            returndatacopy(0, 0, returndatasize())

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

    
    function _implementation() internal view virtual returns (address);

    
    function _fallback() internal virtual {
        _beforeFallback();
        _delegate(_implementation());
    }

    
    fallback () external payable virtual {
        _fallback();
    }

    
    receive () external payable virtual {
        _fallback();
    }

    
    function _beforeFallback() internal virtual {
    }
}

library Address {
    
    function isContract(address account) internal view returns (bool) {
        
        
        

        uint256 size;
        
        assembly { size := extcodesize(account) }
        return size > 0;
    }

    
    function sendValue(address payable recipient, uint256 amount) internal {
        require(address(this).balance >= amount, "Address: insufficient balance");

        
        (bool success, ) = recipient.call{ value: amount }("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }

    
    function functionCall(address target, bytes memory data) internal returns (bytes memory) {
      return functionCall(target, data, "Address: low-level call failed");
    }

    
    function functionCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) {
        return functionCallWithValue(target, data, 0, errorMessage);
    }

    
    function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) {
        return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
    }

    
    function functionCallWithValue(address target, bytes memory data, uint256 value, string memory errorMessage) internal returns (bytes memory) {
        require(address(this).balance >= value, "Address: insufficient balance for call");
        require(isContract(target), "Address: call to non-contract");

        
        (bool success, bytes memory returndata) = target.call{ value: value }(data);
        return _verifyCallResult(success, returndata, errorMessage);
    }

    
    function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
        return functionStaticCall(target, data, "Address: low-level static call failed");
    }

    
    function functionStaticCall(address target, bytes memory data, string memory errorMessage) internal view returns (bytes memory) {
        require(isContract(target), "Address: static call to non-contract");

        
        (bool success, bytes memory returndata) = target.staticcall(data);
        return _verifyCallResult(success, returndata, errorMessage);
    }

    
    function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionDelegateCall(target, data, "Address: low-level delegate call failed");
    }

    
    function functionDelegateCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) {
        require(isContract(target), "Address: delegate call to non-contract");

        
        (bool success, bytes memory returndata) = target.delegatecall(data);
        return _verifyCallResult(success, returndata, errorMessage);
    }

    function _verifyCallResult(bool success, bytes memory returndata, string memory errorMessage) private pure returns(bytes memory) {
        if (success) {
            return returndata;
        } else {
            
            if (returndata.length > 0) {
                

                
                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}

contract UpgradeableProxy is Proxy {
    
    constructor(address _logic, bytes memory _data) public payable {
        assert(_IMPLEMENTATION_SLOT == bytes32(uint256(keccak256("eip1967.proxy.implementation")) - 1));
        _setImplementation(_logic);
        if(_data.length > 0) {
            Address.functionDelegateCall(_logic, _data);
        }
    }

    
    event Upgraded(address indexed implementation);

    
    bytes32 private constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;

    
    function _implementation() internal view virtual override returns (address impl) {
        bytes32 slot = _IMPLEMENTATION_SLOT;
        
        assembly {
            impl := sload(slot)
        }
    }

    
    function _upgradeTo(address newImplementation) internal virtual {
        _setImplementation(newImplementation);
        emit Upgraded(newImplementation);
    }

    
    function _setImplementation(address newImplementation) private {
        require(Address.isContract(newImplementation), "UpgradeableProxy: new implementation is not a contract");

        bytes32 slot = _IMPLEMENTATION_SLOT;

        
        assembly {
            sstore(slot, newImplementation)
        }
    }
}

contract TransparentUpgradeableProxy is UpgradeableProxy {
    
    constructor(address _logic, address admin_, bytes memory _data) public payable UpgradeableProxy(_logic, _data) {
        assert(_ADMIN_SLOT == bytes32(uint256(keccak256("eip1967.proxy.admin")) - 1));
        _setAdmin(admin_);
    }

    
    event AdminChanged(address previousAdmin, address newAdmin);

    
    bytes32 private constant _ADMIN_SLOT = 0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103;

    
    modifier ifAdmin() {
        if (msg.sender == _admin()) {
            _;
        } else {
            _fallback();
        }
    }

    
    function admin() external ifAdmin returns (address admin_) {
        admin_ = _admin();
    }

    
    function implementation() external ifAdmin returns (address implementation_) {
        implementation_ = _implementation();
    }

    
    function changeAdmin(address newAdmin) external virtual ifAdmin {
        require(newAdmin != address(0), "TransparentUpgradeableProxy: new admin is the zero address");
        emit AdminChanged(_admin(), newAdmin);
        _setAdmin(newAdmin);
    }

    
    function upgradeTo(address newImplementation) external virtual ifAdmin {
        _upgradeTo(newImplementation);
    }

    
    function upgradeToAndCall(address newImplementation, bytes calldata data) external payable virtual ifAdmin {
        _upgradeTo(newImplementation);
        Address.functionDelegateCall(newImplementation, data);
    }

    
    function _admin() internal view virtual returns (address adm) {
        bytes32 slot = _ADMIN_SLOT;
        
        assembly {
            adm := sload(slot)
        }
    }

    
    function _setAdmin(address newAdmin) private {
        bytes32 slot = _ADMIN_SLOT;

        
        assembly {
            sstore(slot, newAdmin)
        }
    }

    
    function _beforeFallback() internal virtual override {
        require(msg.sender != _admin(), "TransparentUpgradeableProxy: admin cannot fallback to proxy target");
        super._beforeFallback();
    }
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"_logic","type":"address"},{"internalType":"address","name":"admin_","type":"address"},{"internalType":"bytes","name":"_data","type":"bytes"}],"stateMutability":"payable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"previousAdmin","type":"address"},{"indexed":false,"internalType":"address","name":"newAdmin","type":"address"}],"name":"AdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"implementation","type":"address"}],"name":"Upgraded","type":"event"},{"stateMutability":"payable","type":"fallback"},{"inputs":[],"name":"admin","outputs":[{"internalType":"address","name":"admin_","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newAdmin","type":"address"}],"name":"changeAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"implementation","outputs":[{"internalType":"address","name":"implementation_","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newImplementation","type":"address"}],"name":"upgradeTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newImplementation","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"upgradeToAndCall","outputs":[],"stateMutability":"payable","type":"function"},{"stateMutability":"payable","type":"receive"}]

608060405260405162000c7c38038062000c7c833981810160405260608110156200002957600080fd5b815160208301516040808501805191519395929483019291846401000000008211156200005557600080fd5b9083019060208201858111156200006b57600080fd5b82516401000000008111828201881017156200008657600080fd5b82525081516020918201929091019080838360005b83811015620000b55781810151838201526020016200009b565b50505050905090810190601f168015620000e35780820380516001836020036101000a031916815260200191505b5060405250849150829050620000f98262000137565b8051156200011a57620001188282620001ae60201b620003841760201c565b505b50620001239050565b6200012e82620001dd565b505050620003be565b6200014d816200020160201b620003b01760201c565b6200018a5760405162461bcd60e51b815260040180806020018281038252603681526020018062000c206036913960400191505060405180910390fd5b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc55565b6060620001d6838360405180606001604052806027815260200162000bf96027913962000207565b9392505050565b7fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d610355565b3b151590565b6060620002148462000201565b620002515760405162461bcd60e51b815260040180806020018281038252602681526020018062000c566026913960400191505060405180910390fd5b600080856001600160a01b0316856040518082805190602001908083835b60208310620002905780518252601f1990920191602091820191016200026f565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855af49150503d8060008114620002f2576040519150601f19603f3d011682016040523d82523d6000602084013e620002f7565b606091505b5090925090506200030a82828662000314565b9695505050505050565b6060831562000325575081620001d6565b825115620003365782518084602001fd5b8160405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156200038257818101518382015260200162000368565b50505050905090810190601f168015620003b05780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b61082b80620003ce6000396000f3fe60806040526004361061004e5760003560e01c80633659cfe6146100655780634f1ef286146100985780635c60da1b146101185780638f28397014610149578063f851a4401461017c5761005d565b3661005d5761005b610191565b005b61005b610191565b34801561007157600080fd5b5061005b6004803603602081101561008857600080fd5b50356001600160a01b03166101ab565b61005b600480360360408110156100ae57600080fd5b6001600160a01b0382351691908101906040810160208201356401000000008111156100d957600080fd5b8201836020820111156100eb57600080fd5b8035906020019184600183028401116401000000008311171561010d57600080fd5b5090925090506101e5565b34801561012457600080fd5b5061012d610262565b604080516001600160a01b039092168252519081900360200190f35b34801561015557600080fd5b5061005b6004803603602081101561016c57600080fd5b50356001600160a01b031661029f565b34801561018857600080fd5b5061012d610359565b6101996103b6565b6101a96101a4610416565b61043b565b565b6101b361045f565b6001600160a01b0316336001600160a01b031614156101da576101d581610484565b6101e2565b6101e2610191565b50565b6101ed61045f565b6001600160a01b0316336001600160a01b031614156102555761020f83610484565b61024f8383838080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061038492505050565b5061025d565b61025d610191565b505050565b600061026c61045f565b6001600160a01b0316336001600160a01b031614156102945761028d610416565b905061029c565b61029c610191565b90565b6102a761045f565b6001600160a01b0316336001600160a01b031614156101da576001600160a01b0381166103055760405162461bcd60e51b815260040180806020018281038252603a8152602001806106f7603a913960400191505060405180910390fd5b7f7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f61032e61045f565b604080516001600160a01b03928316815291841660208301528051918290030190a16101d5816104c4565b600061036361045f565b6001600160a01b0316336001600160a01b031614156102945761028d61045f565b60606103a98383604051806060016040528060278152602001610731602791396104e8565b9392505050565b3b151590565b6103be61045f565b6001600160a01b0316336001600160a01b0316141561040e5760405162461bcd60e51b81526004018080602001828103825260428152602001806107b46042913960600191505060405180910390fd5b6101a96101a9565b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5490565b3660008037600080366000845af43d6000803e80801561045a573d6000f35b3d6000fd5b7fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b61048d816105ea565b6040516001600160a01b038216907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a250565b7fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d610355565b60606104f3846103b0565b61052e5760405162461bcd60e51b815260040180806020018281038252602681526020018061078e6026913960400191505060405180910390fd5b600080856001600160a01b0316856040518082805190602001908083835b6020831061056b5780518252601f19909201916020918201910161054c565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855af49150503d80600081146105cb576040519150601f19603f3d011682016040523d82523d6000602084013e6105d0565b606091505b50915091506105e0828286610652565b9695505050505050565b6105f3816103b0565b61062e5760405162461bcd60e51b81526004018080602001828103825260368152602001806107586036913960400191505060405180910390fd5b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc55565b606083156106615750816103a9565b8251156106715782518084602001fd5b8160405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156106bb5781810151838201526020016106a3565b50505050905090810190601f1680156106e85780820380516001836020036101000a031916815260200191505b509250505060405180910390fdfe5472616e73706172656e745570677261646561626c6550726f78793a206e65772061646d696e20697320746865207a65726f2061646472657373416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c65645570677261646561626c6550726f78793a206e657720696d706c656d656e746174696f6e206973206e6f74206120636f6e7472616374416464726573733a2064656c65676174652063616c6c20746f206e6f6e2d636f6e74726163745472616e73706172656e745570677261646561626c6550726f78793a2061646d696e2063616e6e6f742066616c6c6261636b20746f2070726f787920746172676574a26469706673582212207a144a54793e37cb77174133ac380e14d0716cc573c2b1e3575e4dcf49cf6c7464736f6c63430007060033416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c65645570677261646561626c6550726f78793a206e657720696d706c656d656e746174696f6e206973206e6f74206120636f6e7472616374416464726573733a2064656c65676174652063616c6c20746f206e6f6e2d636f6e747261637400000000000000000000000082050a5ab6f5d9186449e305b5bf05ab9019d3cb00000000000000000000000025c646adf184051b35a405b9aaeba321e8d5342a00000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000004e1c7392a00000000000000000000000000000000000000000000000000000000

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

00000000000000000000000082050a5ab6f5d9186449e305b5bf05ab9019d3cb00000000000000000000000025c646adf184051b35a405b9aaeba321e8d5342a00000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000004e1c7392a00000000000000000000000000000000000000000000000000000000

-----Decoded View---------------
Arg [0] : _logic (address): 0x82050a5ab6f5d9186449e305b5bf05ab9019d3cb
Arg [1] : admin_ (address): 0x25c646adf184051b35a405b9aaeba321e8d5342a
Arg [2] : _data (bytes): 0xe1c7392a

-----Encoded View---------------
5 Constructor Arguments found :
Arg [0] : 00000000000000000000000082050a5ab6f5d9186449e305b5bf05ab9019d3cb
Arg [1] : 00000000000000000000000025c646adf184051b35a405b9aaeba321e8d5342a
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000060
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000004
Arg [4] : e1c7392a00000000000000000000000000000000000000000000000000000000


Deployed ByteCode Sourcemap

5915:2139:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1027:11;:9;:11::i;:::-;5915:2139;;947:11;:9;:11::i;7101:119::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;7101:119:0;-1:-1:-1;;;;;7101:119:0;;:::i;7234:219::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;7234:219:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;7234:219:0;;-1:-1:-1;7234:219:0;-1:-1:-1;7234:219:0;:::i;6688:131::-;;;;;;;;;;;;;:::i;:::-;;;;-1:-1:-1;;;;;6688:131:0;;;;;;;;;;;;;;6833:254;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;6833:254:0;-1:-1:-1;;;;;6833:254:0;;:::i;6579:95::-;;;;;;;;;;;;;:::i;772:113::-;821:17;:15;:17::i;:::-;849:28;859:17;:15;:17::i;:::-;849:9;:28::i;:::-;772:113::o;7101:119::-;6476:8;:6;:8::i;:::-;-1:-1:-1;;;;;6462:22:0;:10;-1:-1:-1;;;;;6462:22:0;;6458:100;;;7183:29:::1;7194:17;7183:10;:29::i;:::-;6458:100:::0;;;6535:11;:9;:11::i;:::-;7101:119;:::o;7234:219::-;6476:8;:6;:8::i;:::-;-1:-1:-1;;;;;6462:22:0;:10;-1:-1:-1;;;;;6462:22:0;;6458:100;;;7352:29:::1;7363:17;7352:10;:29::i;:::-;7392:53;7421:17;7440:4;;7392:53;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;::::1;::::0;;;;-1:-1:-1;7392:28:0::1;::::0;-1:-1:-1;;;7392:53:0:i:1;:::-;;6458:100:::0;;;6535:11;:9;:11::i;:::-;7234:219;;;:::o;6688:131::-;6740:23;6476:8;:6;:8::i;:::-;-1:-1:-1;;;;;6462:22:0;:10;-1:-1:-1;;;;;6462:22:0;;6458:100;;;6794:17:::1;:15;:17::i;:::-;6776:35;;6458:100:::0;;;6535:11;:9;:11::i;:::-;6688:131;:::o;6833:254::-;6476:8;:6;:8::i;:::-;-1:-1:-1;;;;;6462:22:0;:10;-1:-1:-1;;;;;6462:22:0;;6458:100;;;-1:-1:-1;;;;;6916:22:0;::::1;6908:93;;;;-1:-1:-1::0;;;6908:93:0::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7017:32;7030:8;:6;:8::i;:::-;7017:32;::::0;;-1:-1:-1;;;;;7017:32:0;;::::1;::::0;;;;::::1;;::::0;::::1;::::0;;;;;;;;;::::1;7060:19;7070:8;7060:9;:19::i;6579:95::-:0;6622:14;6476:8;:6;:8::i;:::-;-1:-1:-1;;;;;6462:22:0;:10;-1:-1:-1;;;;;6462:22:0;;6458:100;;;6658:8:::1;:6;:8::i;3450:200::-:0;3533:12;3565:77;3586:6;3594:4;3565:77;;;;;;;;;;;;;;;;;:20;:77::i;:::-;3558:84;3450:200;-1:-1:-1;;;3450:200:0:o;1148:216::-;1309:20;1348:8;;;1148:216::o;7844:207::-;7930:8;:6;:8::i;:::-;-1:-1:-1;;;;;7916:22:0;:10;-1:-1:-1;;;;;7916:22:0;;;7908:101;;;;-1:-1:-1;;;7908:101:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8020:23;:21;:23::i;5186:209::-;5105:66;5366:11;;5343:45::o;144:533::-;310:14;307:1;304;291:34;441:1;438;422:14;419:1;403:14;396:5;383:60;494:16;491:1;488;473:38;534:6;568:38;;;;640:16;637:1;630:27;568:38;587:16;584:1;577:27;7467:180;6347:66;7618:11;;7596:44::o;5409:163::-;5484:37;5503:17;5484:18;:37::i;:::-;5537:27;;-1:-1:-1;;;;;5537:27:0;;;;;;;;5409:163;:::o;7661:169::-;6347:66;7790:22;7775:48::o;3664:373::-;3775:12;3808:18;3819:6;3808:10;:18::i;:::-;3800:69;;;;-1:-1:-1;;;3800:69:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3893:12;3907:23;3934:6;-1:-1:-1;;;;;3934:19:0;3954:4;3934:25;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;3934:25:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3892:67;;;;3977:52;3995:7;4004:10;4016:12;3977:17;:52::i;:::-;3970:59;3664:373;-1:-1:-1;;;;;;3664:373:0:o;5586:322::-;5668:37;5687:17;5668:18;:37::i;:::-;5660:104;;;;-1:-1:-1;;;5660:104:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5105:66;5859:31;5844:57::o;4045:567::-;4160:12;4189:7;4185:420;;;-1:-1:-1;4220:10:0;4213:17;;4185:420;4281:17;;:21;4277:317;;4422:10;4416:17;4483:15;4470:10;4466:2;4462:19;4455:44;4370:148;4565:12;4558:20;;-1:-1:-1;;;4558:20:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

Metadata Hash

ipfs://7a144a54793e37cb77174133ac380e14d0716cc573c2b1e3575e4dcf49cf6c74
Loading