ETH Price: $2,319.05 (+1.74%)

Contract

0xA8B8D9dFD977Ef3b7D9E6048FC503E038b95073C
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

More Info

Private Name Tags

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To

There are no matching entries

Please try again later

Advanced mode:
Parent Transaction Hash Method Block
From
To
View All Internal Transactions
Loading...
Loading
Loading...
Loading
Cross-Chain Transactions

Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
Delegation

Compiler Version
v0.8.30+commit.73712a01

Optimization Enabled:
Yes with 420 runs

Other Settings:
default evmVersion, MIT license

Contract Source Code (Solidity Multiple files format)

File 1 of 3: Delegation.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

import "Proxy.sol";
import "Ownable.sol";

contract Delegation is Proxy, Ownable {

    bytes32 constant IMPLEMENTATION_SLOT = bytes32(0x8ba0ed1f62da1d3048614c2c1feb566f041c8467eb00fb8294776a9179dc1643);

    constructor(){}

    function setImplementation(address _newImplementation) external onlyOwner {
        bytes32 slot = IMPLEMENTATION_SLOT;
        assembly {
            sstore(slot, _newImplementation)
        }
    }

    function _implementation() override internal view returns (address implementation){
        bytes32 slot = IMPLEMENTATION_SLOT;
        assembly {
            implementation := sload(slot)
        }
    }

    receive() external payable { }
}

File 2 of 3: Ownable.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;


abstract contract Ownable {
    modifier onlyOwner() {
        require(msg.sender == owner());
        _;
    }

    function owner() public view returns (address) {
        return address(this);
    }
}

File 3 of 3: Proxy.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (proxy/Proxy.sol)

pragma solidity ^0.8.20;

/**
 * @dev This abstract contract provides a fallback function that delegates all calls to another contract using the EVM
 * instruction `delegatecall`. We refer to the second contract as the _implementation_ behind the proxy, and it has to
 * be specified by overriding the virtual {_implementation} function.
 *
 * Additionally, delegation to the implementation can be triggered manually through the {_fallback} function, or to a
 * different contract through the {_delegate} function.
 *
 * The success and return data of the delegated call will be returned back to the caller of the proxy.
 */
abstract contract Proxy {
    /**
     * @dev Delegates the current call to `implementation`.
     *
     * This function does not return to its internal call site, it will return directly to the external caller.
     */
    function _delegate(address implementation) internal virtual {
        assembly {
            // Copy msg.data. We take full control of memory in this inline assembly
            // block because it will not return to Solidity code. We overwrite the
            // Solidity scratch pad at memory position 0.
            calldatacopy(0, 0, calldatasize())

            // Call the implementation.
            // out and outsize are 0 because we don't know the size yet.
            let result := delegatecall(gas(), implementation, 0, calldatasize(), 0, 0)

            // Copy the returned data.
            returndatacopy(0, 0, returndatasize())

            switch result
            // delegatecall returns 0 on error.
            case 0 {
                revert(0, returndatasize())
            }
            default {
                return(0, returndatasize())
            }
        }
    }

    /**
     * @dev This is a virtual function that should be overridden so it returns the address to which the fallback
     * function and {_fallback} should delegate.
     */
    function _implementation() internal view virtual returns (address);

    /**
     * @dev Delegates the current call to the address returned by `_implementation()`.
     *
     * This function does not return to its internal call site, it will return directly to the external caller.
     */
    function _fallback() internal virtual {
        _delegate(_implementation());
    }

    /**
     * @dev Fallback function that delegates calls to the address returned by `_implementation()`. Will run if no other
     * function in the contract matches the call data.
     */
    fallback() external payable virtual {
        _fallback();
    }
}

Contract Security Audit

Contract ABI

API
[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"stateMutability":"payable","type":"fallback"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_newImplementation","type":"address"}],"name":"setImplementation","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}]

6080604052348015600e575f5ffd5b5061016a8061001c5f395ff3fe60806040526004361061002c575f3560e01c80638da5cb5b1461003d578063d784d4261461005c57610033565b3661003357005b61003b61007b565b005b348015610048575f5ffd5b506040805130815290519081900360200190f35b348015610067575f5ffd5b5061003b6100763660046100fa565b6100ad565b6100ab6100a67f8ba0ed1f62da1d3048614c2c1feb566f041c8467eb00fb8294776a9179dc16435490565b6100dc565b565b3330146100b8575f5ffd5b7f8ba0ed1f62da1d3048614c2c1feb566f041c8467eb00fb8294776a9179dc164355565b365f5f375f5f365f845af43d5f5f3e8080156100f6573d5ff35b3d5ffd5b5f6020828403121561010a575f5ffd5b813573ffffffffffffffffffffffffffffffffffffffff8116811461012d575f5ffd5b939250505056fea26469706673582212204de5f5c28e57b426375ce6ec745dc0cf37ddd86d475c8dac2af59b4c2162deb864736f6c634300081e0033

Deployed Bytecode

0x60806040526004361061002c575f3560e01c80638da5cb5b1461003d578063d784d4261461005c57610033565b3661003357005b61003b61007b565b005b348015610048575f5ffd5b506040805130815290519081900360200190f35b348015610067575f5ffd5b5061003b6100763660046100fa565b6100ad565b6100ab6100a67f8ba0ed1f62da1d3048614c2c1feb566f041c8467eb00fb8294776a9179dc16435490565b6100dc565b565b3330146100b8575f5ffd5b7f8ba0ed1f62da1d3048614c2c1feb566f041c8467eb00fb8294776a9179dc164355565b365f5f375f5f365f845af43d5f5f3e8080156100f6573d5ff35b3d5ffd5b5f6020828403121561010a575f5ffd5b813573ffffffffffffffffffffffffffffffffffffffff8116811461012d575f5ffd5b939250505056fea26469706673582212204de5f5c28e57b426375ce6ec745dc0cf37ddd86d475c8dac2af59b4c2162deb864736f6c634300081e0033

Deployed Bytecode Sourcemap

106:655:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2715:11:2;:9;:11::i;:::-;106:655:0;185:86:1;;;;;;;;;;-1:-1:-1;185:86:1;;;258:4;160:74:3;;185:86:1;;;;;;148:2:3;185:86:1;;;299:204:0;;;;;;;;;;-1:-1:-1;299:204:0;;;;;:::i;:::-;;:::i;2380:85:2:-;2429:28;2439:17;200:66:0;691:11;;511:209;2439:17:2;2429:9;:28::i;:::-;2380:85::o;299:204:0:-;135:10:1;258:4;135:21;127:30;;;;;;200:66:0::1;453:32:::0;299:204::o;970:918:2:-;1313:14;1310:1;1307;1294:34;1531:1;1528;1512:14;1509:1;1493:14;1486:5;1473:60;1610:16;1607:1;1604;1589:38;1650:6;1719:68;;;;1838:16;1835:1;1828:27;1719:68;1755:16;1752:1;1745:27;245:309:3;304:6;357:2;345:9;336:7;332:23;328:32;325:52;;;373:1;370;363:12;325:52;412:9;399:23;462:42;455:5;451:54;444:5;441:65;431:93;;520:1;517;510:12;431:93;543:5;245:309;-1:-1:-1;;;245:309:3:o

Swarm Source

ipfs://4de5f5c28e57b426375ce6ec745dc0cf37ddd86d475c8dac2af59b4c2162deb8

Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading
Loading...
Loading
Loading...
Loading

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.