false
false

Contract Address Details

0xCC25Bcd56E425B13AbB6C8C653C50A1F6Adb7b18

Contract Name
LPoolDepositorDelegator
Creator
0x68b6f4–0b8438 at 0x83dcc2–f9e9a0
Implementation
LPoolDepositor | 0xc7c3333f713eb2b100dc6bdc9f79fa43a2a5ddc8
Balance
0 KCS
Tokens
Fetching tokens...
Transactions
4,397 Transactions
Transfers
0 Transfers
Gas Used
726,490,225
Last Balance Update
47828707
Warning! Contract bytecode has been changed and doesn't match the verified one. Therefore, interaction with this smart contract may be risky.
Contract name:
LPoolDepositorDelegator




Optimization enabled
true
Compiler version
v0.7.6+commit.7338295f




Optimization runs
200
Verified at
2022-03-31T12:35:55.985973Z

Constructor Arguments

000000000000000000000000c7c3333f713eb2b100dc6bdc9f79fa43a2a5ddc8000000000000000000000000ad0bfa476fb71215ba026ebe60ffa9b31d98efe7

Arg [0] (address) : 0xc7c3333f713eb2b100dc6bdc9f79fa43a2a5ddc8
Arg [1] (address) : 0xad0bfa476fb71215ba026ebe60ffa9b31d98efe7

              

project:/contracts/liquidity/LPoolDepositorDelegator.sol

// SPDX-License-Identifier: BUSL-1.1
pragma solidity 0.7.6;

import "../Adminable.sol";
import "../DelegatorInterface.sol";

contract LPoolDepositorDelegator is DelegatorInterface, Adminable {

    constructor(address implementation_, address payable admin_) {
        admin = admin_;
        implementation = implementation_;
    }

    function setImplementation(address implementation_) public override onlyAdmin {
        address oldImplementation = implementation;
        implementation = implementation_;
        emit NewImplementation(oldImplementation, implementation);
    }
}
        

project:/contracts/Adminable.sol

// SPDX-License-Identifier: BUSL-1.1


pragma solidity 0.7.6;

abstract contract Adminable {
    address payable public admin;
    address payable public pendingAdmin;
    address payable public developer;

    event NewPendingAdmin(address oldPendingAdmin, address newPendingAdmin);

    event NewAdmin(address oldAdmin, address newAdmin);
    constructor () {
        developer = msg.sender;
    }

    modifier onlyAdmin() {
        require(msg.sender == admin, "caller must be admin");
        _;
    }
    modifier onlyAdminOrDeveloper() {
        require(msg.sender == admin || msg.sender == developer, "caller must be admin or developer");
        _;
    }

    function setPendingAdmin(address payable newPendingAdmin) external virtual onlyAdmin {
        // Save current value, if any, for inclusion in log
        address oldPendingAdmin = pendingAdmin;
        // Store pendingAdmin with value newPendingAdmin
        pendingAdmin = newPendingAdmin;
        // Emit NewPendingAdmin(oldPendingAdmin, newPendingAdmin)
        emit NewPendingAdmin(oldPendingAdmin, newPendingAdmin);
    }

    function acceptAdmin() external virtual {
        require(msg.sender == pendingAdmin, "only pendingAdmin can accept admin");
        // Save current values for inclusion in log
        address oldAdmin = admin;
        address oldPendingAdmin = pendingAdmin;
        // Store admin with value pendingAdmin
        admin = pendingAdmin;
        // Clear the pending value
        pendingAdmin = address(0);
        emit NewAdmin(oldAdmin, admin);
        emit NewPendingAdmin(oldPendingAdmin, pendingAdmin);
    }

}
          

project:/contracts/DelegatorInterface.sol

// SPDX-License-Identifier: BUSL-1.1
pragma solidity 0.7.6;


abstract contract DelegatorInterface {
    /**
     * Implementation address for this contract
     */
    address public implementation;

    /**
     * Emitted when implementation is changed
     */
    event NewImplementation(address oldImplementation, address newImplementation);

    /**
     * Called by the admin to update the implementation of the delegator
     * @param implementation_ The address of the new implementation for delegation
     */
    function setImplementation(address implementation_) public virtual;


    /**
    * Internal method to delegate execution to another contract
    * @dev It returns to the external caller whatever the implementation returns or forwards reverts
    * @param callee The contract to delegatecall
    * @param data The raw data to delegatecall
    * @return The returned bytes from the delegatecall
    */
    function delegateTo(address callee, bytes memory data) internal returns (bytes memory) {
        (bool success, bytes memory returnData) = callee.delegatecall(data);
        assembly {
            if eq(success, 0) {revert(add(returnData, 0x20), returndatasize())}
        }
        return returnData;
    }

    /**
     * Delegates execution to the implementation contract
     * @dev It returns to the external caller whatever the implementation returns or forwards reverts
     * @param data The raw data to delegatecall
     * @return The returned bytes from the delegatecall
     */
    function delegateToImplementation(bytes memory data) public returns (bytes memory) {
        return delegateTo(implementation, data);
    }

    /**
     * Delegates execution to an implementation contract
     * @dev It returns to the external caller whatever the implementation returns or forwards reverts
     *  There are an additional 2 prefix uints from the wrapper returndata, which we ignore since we make an extra hop.
     * @param data The raw data to delegatecall
     * @return The returned bytes from the delegatecall
     */
    function delegateToViewImplementation(bytes memory data) public view returns (bytes memory) {
        (bool success, bytes memory returnData) = address(this).staticcall(abi.encodeWithSignature("delegateToImplementation(bytes)", data));
        assembly {
            if eq(success, 0) {revert(add(returnData, 0x20), returndatasize())}
        }
        return abi.decode(returnData, (bytes));
    }
    /**
    * Delegates execution to an implementation contract
    * @dev It returns to the external caller whatever the implementation returns or forwards reverts
    */
    fallback() external payable {
        _fallback();
    }

    receive() external payable {
        _fallback();
    }

    function _fallback() internal {
        // delegate all other functions to current implementation
        if (msg.data.length > 0) {
            (bool success,) = implementation.delegatecall(msg.data);
            assembly {
                let free_mem_ptr := mload(0x40)
                returndatacopy(free_mem_ptr, 0, returndatasize())
                switch success
                case 0 {revert(free_mem_ptr, returndatasize())}
                default {return (free_mem_ptr, returndatasize())}
            }
        }
    }
}
          

Contract ABI

[{"type":"constructor","stateMutability":"nonpayable","inputs":[{"type":"address","name":"implementation_","internalType":"address"},{"type":"address","name":"admin_","internalType":"address payable"}]},{"type":"event","name":"NewAdmin","inputs":[{"type":"address","name":"oldAdmin","internalType":"address","indexed":false},{"type":"address","name":"newAdmin","internalType":"address","indexed":false}],"anonymous":false},{"type":"event","name":"NewImplementation","inputs":[{"type":"address","name":"oldImplementation","internalType":"address","indexed":false},{"type":"address","name":"newImplementation","internalType":"address","indexed":false}],"anonymous":false},{"type":"event","name":"NewPendingAdmin","inputs":[{"type":"address","name":"oldPendingAdmin","internalType":"address","indexed":false},{"type":"address","name":"newPendingAdmin","internalType":"address","indexed":false}],"anonymous":false},{"type":"fallback","stateMutability":"payable"},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"acceptAdmin","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address payable"}],"name":"admin","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bytes","name":"","internalType":"bytes"}],"name":"delegateToImplementation","inputs":[{"type":"bytes","name":"data","internalType":"bytes"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bytes","name":"","internalType":"bytes"}],"name":"delegateToViewImplementation","inputs":[{"type":"bytes","name":"data","internalType":"bytes"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address payable"}],"name":"developer","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"implementation","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address payable"}],"name":"pendingAdmin","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setImplementation","inputs":[{"type":"address","name":"implementation_","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setPendingAdmin","inputs":[{"type":"address","name":"newPendingAdmin","internalType":"address payable"}]},{"type":"receive","stateMutability":"payable"}]
              

Contract Creation Code

0x608060405234801561001057600080fd5b50604051610a79380380610a798339818101604052604081101561003357600080fd5b508051602090910151600380546001600160a01b03199081163317909155600180546001600160a01b03938416908316179055600080549290931691161790556109f7806100826000396000f3fe60806040526004361061008a5760003560e01c80634dd18bf5116100595780634dd18bf5146102c25780635c60da1b146102f5578063ca4b208b1461030a578063d784d4261461031f578063f851a4401461035257610099565b80630933c1ed146100a15780630e18b681146101c957806326782247146101de5780634487152f1461020f57610099565b3661009957610097610367565b005b610097610367565b3480156100ad57600080fd5b50610154600480360360208110156100c457600080fd5b8101906020810181356401000000008111156100df57600080fd5b8201836020820111156100f157600080fd5b8035906020019184600183028401116401000000008311171561011357600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295506103f2945050505050565b6040805160208082528351818301528351919283929083019185019080838360005b8381101561018e578181015183820152602001610176565b50505050905090810190601f1680156101bb5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b3480156101d557600080fd5b50610097610411565b3480156101ea57600080fd5b506101f3610511565b604080516001600160a01b039092168252519081900360200190f35b34801561021b57600080fd5b506101546004803603602081101561023257600080fd5b81019060208101813564010000000081111561024d57600080fd5b82018360208201111561025f57600080fd5b8035906020019184600183028401116401000000008311171561028157600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550610520945050505050565b3480156102ce57600080fd5b50610097600480360360208110156102e557600080fd5b50356001600160a01b0316610740565b34801561030157600080fd5b506101f36107f9565b34801561031657600080fd5b506101f3610808565b34801561032b57600080fd5b506100976004803603602081101561034257600080fd5b50356001600160a01b0316610817565b34801561035e57600080fd5b506101f36108cf565b36156103f057600080546040516001600160a01b0390911690829036908083838082843760405192019450600093509091505080830381855af49150503d80600081146103d0576040519150601f19603f3d011682016040523d82523d6000602084013e6103d5565b606091505b505090506040513d6000823e8180156103ec573d82f35b3d82fd5b565b60005460609061040b906001600160a01b0316836108de565b92915050565b6002546001600160a01b0316331461045a5760405162461bcd60e51b81526004018080602001828103825260228152602001806109a06022913960400191505060405180910390fd5b60018054600280546001600160a01b038082166001600160a01b031980861682179687905590921690925560408051938316808552949092166020840152815190927ff9ffabca9c8276e99321725bcb43fb076a6c66a54b7f21c4e8146d8519b417dc92908290030190a1600254604080516001600160a01b038085168252909216602083015280517fca4f2f25d0898edd99413412fb94012f9e54ec8142f9b093e7720646a95b16a99281900390910190a15050565b6002546001600160a01b031681565b6060600080306001600160a01b0316846040516024018080602001828103825283818151815260200191508051906020019080838360005b83811015610570578181015183820152602001610558565b50505050905090810190601f16801561059d5780820380516001836020036101000a031916815260200191505b5060408051601f198184030181529181526020820180516001600160e01b0316630933c1ed60e01b178152905182519295509350839250908083835b602083106105f85780518252601f1990920191602091820191016105d9565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855afa9150503d8060008114610658576040519150601f19603f3d011682016040523d82523d6000602084013e61065d565b606091505b50915091506000821415610672573d60208201fd5b80806020019051602081101561068757600080fd5b81019080805160405193929190846401000000008211156106a757600080fd5b9083019060208201858111156106bc57600080fd5b82516401000000008111828201881017156106d657600080fd5b82525081516020918201929091019080838360005b838110156107035781810151838201526020016106eb565b50505050905090810190601f1680156107305780820380516001836020036101000a031916815260200191505b5060405250505092505050919050565b6001546001600160a01b03163314610796576040805162461bcd60e51b815260206004820152601460248201527331b0b63632b91036bab9ba1031329030b236b4b760611b604482015290519081900360640190fd5b600280546001600160a01b038381166001600160a01b0319831681179093556040805191909216808252602082019390935281517fca4f2f25d0898edd99413412fb94012f9e54ec8142f9b093e7720646a95b16a9929181900390910190a15050565b6000546001600160a01b031681565b6003546001600160a01b031681565b6001546001600160a01b0316331461086d576040805162461bcd60e51b815260206004820152601460248201527331b0b63632b91036bab9ba1031329030b236b4b760611b604482015290519081900360640190fd5b600080546001600160a01b038381166001600160a01b0319831617928390556040805192821680845293909116602083015280517fd604de94d45953f9138079ec1b82d533cb2160c906d1076d1f7ed54befbca97a9281900390910190a15050565b6001546001600160a01b031681565b6060600080846001600160a01b0316846040518082805190602001908083835b6020831061091d5780518252601f1990920191602091820191016108fe565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855af49150503d806000811461097d576040519150601f19603f3d011682016040523d82523d6000602084013e610982565b606091505b50915091506000821415610997573d60208201fd5b94935050505056fe6f6e6c792070656e64696e6741646d696e2063616e206163636570742061646d696ea2646970667358221220d3d7f66eae8c99629de9b1da5b8b46a7710acd1065a70e7a2cc5b99920909d8864736f6c63430007060033000000000000000000000000c7c3333f713eb2b100dc6bdc9f79fa43a2a5ddc8000000000000000000000000ad0bfa476fb71215ba026ebe60ffa9b31d98efe7

Deployed ByteCode

0x60806040526004361061008a5760003560e01c80634dd18bf5116100595780634dd18bf5146102c25780635c60da1b146102f5578063ca4b208b1461030a578063d784d4261461031f578063f851a4401461035257610099565b80630933c1ed146100a15780630e18b681146101c957806326782247146101de5780634487152f1461020f57610099565b3661009957610097610367565b005b610097610367565b3480156100ad57600080fd5b50610154600480360360208110156100c457600080fd5b8101906020810181356401000000008111156100df57600080fd5b8201836020820111156100f157600080fd5b8035906020019184600183028401116401000000008311171561011357600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295506103f2945050505050565b6040805160208082528351818301528351919283929083019185019080838360005b8381101561018e578181015183820152602001610176565b50505050905090810190601f1680156101bb5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b3480156101d557600080fd5b50610097610411565b3480156101ea57600080fd5b506101f3610511565b604080516001600160a01b039092168252519081900360200190f35b34801561021b57600080fd5b506101546004803603602081101561023257600080fd5b81019060208101813564010000000081111561024d57600080fd5b82018360208201111561025f57600080fd5b8035906020019184600183028401116401000000008311171561028157600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550610520945050505050565b3480156102ce57600080fd5b50610097600480360360208110156102e557600080fd5b50356001600160a01b0316610740565b34801561030157600080fd5b506101f36107f9565b34801561031657600080fd5b506101f3610808565b34801561032b57600080fd5b506100976004803603602081101561034257600080fd5b50356001600160a01b0316610817565b34801561035e57600080fd5b506101f36108cf565b36156103f057600080546040516001600160a01b0390911690829036908083838082843760405192019450600093509091505080830381855af49150503d80600081146103d0576040519150601f19603f3d011682016040523d82523d6000602084013e6103d5565b606091505b505090506040513d6000823e8180156103ec573d82f35b3d82fd5b565b60005460609061040b906001600160a01b0316836108de565b92915050565b6002546001600160a01b0316331461045a5760405162461bcd60e51b81526004018080602001828103825260228152602001806109a06022913960400191505060405180910390fd5b60018054600280546001600160a01b038082166001600160a01b031980861682179687905590921690925560408051938316808552949092166020840152815190927ff9ffabca9c8276e99321725bcb43fb076a6c66a54b7f21c4e8146d8519b417dc92908290030190a1600254604080516001600160a01b038085168252909216602083015280517fca4f2f25d0898edd99413412fb94012f9e54ec8142f9b093e7720646a95b16a99281900390910190a15050565b6002546001600160a01b031681565b6060600080306001600160a01b0316846040516024018080602001828103825283818151815260200191508051906020019080838360005b83811015610570578181015183820152602001610558565b50505050905090810190601f16801561059d5780820380516001836020036101000a031916815260200191505b5060408051601f198184030181529181526020820180516001600160e01b0316630933c1ed60e01b178152905182519295509350839250908083835b602083106105f85780518252601f1990920191602091820191016105d9565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855afa9150503d8060008114610658576040519150601f19603f3d011682016040523d82523d6000602084013e61065d565b606091505b50915091506000821415610672573d60208201fd5b80806020019051602081101561068757600080fd5b81019080805160405193929190846401000000008211156106a757600080fd5b9083019060208201858111156106bc57600080fd5b82516401000000008111828201881017156106d657600080fd5b82525081516020918201929091019080838360005b838110156107035781810151838201526020016106eb565b50505050905090810190601f1680156107305780820380516001836020036101000a031916815260200191505b5060405250505092505050919050565b6001546001600160a01b03163314610796576040805162461bcd60e51b815260206004820152601460248201527331b0b63632b91036bab9ba1031329030b236b4b760611b604482015290519081900360640190fd5b600280546001600160a01b038381166001600160a01b0319831681179093556040805191909216808252602082019390935281517fca4f2f25d0898edd99413412fb94012f9e54ec8142f9b093e7720646a95b16a9929181900390910190a15050565b6000546001600160a01b031681565b6003546001600160a01b031681565b6001546001600160a01b0316331461086d576040805162461bcd60e51b815260206004820152601460248201527331b0b63632b91036bab9ba1031329030b236b4b760611b604482015290519081900360640190fd5b600080546001600160a01b038381166001600160a01b0319831617928390556040805192821680845293909116602083015280517fd604de94d45953f9138079ec1b82d533cb2160c906d1076d1f7ed54befbca97a9281900390910190a15050565b6001546001600160a01b031681565b6060600080846001600160a01b0316846040518082805190602001908083835b6020831061091d5780518252601f1990920191602091820191016108fe565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855af49150503d806000811461097d576040519150601f19603f3d011682016040523d82523d6000602084013e610982565b606091505b50915091506000821415610997573d60208201fd5b94935050505056fe6f6e6c792070656e64696e6741646d696e2063616e206163636570742061646d696ea2646970667358221220d3d7f66eae8c99629de9b1da5b8b46a7710acd1065a70e7a2cc5b99920909d8864736f6c63430007060033