ETH Price: $2,111.30 (+4.16%)

Contract

0x9a3c5ec5De774E30074E623e2BF35395Beee3C98
 

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

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
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:
DiamondCutFacet

Compiler Version
v0.8.12+commit.f00d7308

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
// SPDX-License-Identifier: CC0-1.0
pragma solidity ^0.8.0;

/******************************************************************************\
* Author: Nick Mudge <[email protected]>, Twitter/Github: @mudgen
* EIP-2535 Diamonds
/******************************************************************************/

import { IDiamondCut } from "../interfaces/IDiamondCut.sol";
import { LibDiamond } from "../libraries/LibDiamond.sol";

// Remember to add the loupe functions from DiamondLoupeFacet to the diamond.
// The loupe functions are required by the EIP2535 Diamonds standard

contract DiamondCutFacet is IDiamondCut {
  /// @notice Add/replace/remove any number of functions and optionally execute
  ///         a function with delegatecall
  /// @param _diamondCut Contains the facet addresses and function selectors
  /// @param _init The address of the contract or facet to execute _calldata
  /// @param _calldata A function call, including function selector and arguments
  ///                  _calldata is executed with delegatecall on _init
  function diamondCut(
    FacetCut[] calldata _diamondCut,
    address _init,
    bytes calldata _calldata
  ) external override {
    LibDiamond.enforceIsContractOwner();
    LibDiamond.diamondCut(_diamondCut, _init, _calldata);
  }
}

// SPDX-License-Identifier: CC0-1.0
pragma solidity ^0.8.0;

/******************************************************************************\
* Author: Nick Mudge <[email protected]>, Twitter/Github: @mudgen
* EIP-2535 Diamonds
/******************************************************************************/

import { IDiamond } from "./IDiamond.sol";

interface IDiamondCut is IDiamond {
  /// @notice Add/replace/remove any number of functions and optionally execute
  ///         a function with delegatecall
  /// @param _diamondCut Contains the facet addresses and function selectors
  /// @param _init The address of the contract or facet to execute _calldata
  /// @param _calldata A function call, including function selector and arguments
  ///                  _calldata is executed with delegatecall on _init
  function diamondCut(
    FacetCut[] calldata _diamondCut,
    address _init,
    bytes calldata _calldata
  ) external;
}

// SPDX-License-Identifier: CC0-1.0
pragma solidity ^0.8.0;

/******************************************************************************\
* Author: Nick Mudge <[email protected]>, Twitter/Github: @mudgen
* EIP-2535 Diamonds
/******************************************************************************/
import { IDiamond } from "../interfaces/IDiamond.sol";
import { IDiamondCut } from "../interfaces/IDiamondCut.sol";

// solhint-disable avoid-low-level-calls
// solhint-disable no-inline-assembly

// Remember to add the loupe functions from DiamondLoupeFacet to the diamond.
// The loupe functions are required by the EIP2535 Diamonds standard

error NoSelectorsGivenToAdd();
error NotContractOwner(address _user, address _contractOwner);
error NoSelectorsProvidedForFacetForCut(address _facetAddress);
error CannotAddSelectorsToZeroAddress(bytes4[] _selectors);
error NoBytecodeAtAddress(address _contractAddress, string _message);
error IncorrectFacetCutAction(uint8 _action);
error CannotAddFunctionToDiamondThatAlreadyExists(bytes4 _selector);
error CannotReplaceFunctionsFromFacetWithZeroAddress(bytes4[] _selectors);
error CannotReplaceImmutableFunction(bytes4 _selector);
error CannotReplaceFunctionWithTheSameFunctionFromTheSameFacet(bytes4 _selector);
error CannotReplaceFunctionThatDoesNotExists(bytes4 _selector);
error RemoveFacetAddressMustBeZeroAddress(address _facetAddress);
error CannotRemoveFunctionThatDoesNotExist(bytes4 _selector);
error CannotRemoveImmutableFunction(bytes4 _selector);
error InitializationFunctionReverted(address _initializationContractAddress, bytes _calldata);

library LibDiamond {
  bytes32 internal constant DIAMOND_STORAGE_POSITION = keccak256("diamond.standard.diamond.storage");

  struct FacetAddressAndSelectorPosition {
    address facetAddress;
    uint16 selectorPosition;
  }

  struct DiamondStorage {
    // function selector => facet address and selector position in selectors array
    mapping(bytes4 => FacetAddressAndSelectorPosition) facetAddressAndSelectorPosition;
    bytes4[] selectors;
    mapping(bytes4 => bool) supportedInterfaces;
    // owner of the contract
    address contractOwner;
  }

  function diamondStorage() internal pure returns (DiamondStorage storage ds) {
    bytes32 position = DIAMOND_STORAGE_POSITION;
    assembly {
      ds.slot := position
    }
  }

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

  function setContractOwner(address _newOwner) internal {
    DiamondStorage storage ds = diamondStorage();
    address previousOwner = ds.contractOwner;
    ds.contractOwner = _newOwner;
    emit OwnershipTransferred(previousOwner, _newOwner);
  }

  function contractOwner() internal view returns (address contractOwner_) {
    contractOwner_ = diamondStorage().contractOwner;
  }

  function enforceIsContractOwner() internal view {
    if (msg.sender != diamondStorage().contractOwner) {
      revert NotContractOwner(msg.sender, diamondStorage().contractOwner);
    }
  }

  event DiamondCut(IDiamondCut.FacetCut[] _diamondCut, address _init, bytes _calldata);

  // Internal function version of diamondCut
  function diamondCut(
    IDiamondCut.FacetCut[] memory _diamondCut,
    address _init,
    bytes memory _calldata
  ) internal {
    for (uint256 facetIndex; facetIndex < _diamondCut.length; facetIndex++) {
      bytes4[] memory functionSelectors = _diamondCut[facetIndex].functionSelectors;
      address facetAddress = _diamondCut[facetIndex].facetAddress;
      if (functionSelectors.length == 0) {
        revert NoSelectorsProvidedForFacetForCut(facetAddress);
      }
      IDiamondCut.FacetCutAction action = _diamondCut[facetIndex].action;
      if (action == IDiamond.FacetCutAction.Add) {
        addFunctions(facetAddress, functionSelectors);
      } else if (action == IDiamond.FacetCutAction.Replace) {
        replaceFunctions(facetAddress, functionSelectors);
      } else if (action == IDiamond.FacetCutAction.Remove) {
        removeFunctions(facetAddress, functionSelectors);
      } else {
        revert IncorrectFacetCutAction(uint8(action));
      }
    }
    emit DiamondCut(_diamondCut, _init, _calldata);
    initializeDiamondCut(_init, _calldata);
  }

  function addFunctions(address _facetAddress, bytes4[] memory _functionSelectors) internal {
    if (_facetAddress == address(0)) {
      revert CannotAddSelectorsToZeroAddress(_functionSelectors);
    }
    DiamondStorage storage ds = diamondStorage();
    uint16 selectorCount = uint16(ds.selectors.length);
    enforceHasContractCode(_facetAddress, "LibDiamondCut: Add facet has no code");
    for (uint256 selectorIndex; selectorIndex < _functionSelectors.length; selectorIndex++) {
      bytes4 selector = _functionSelectors[selectorIndex];
      address oldFacetAddress = ds.facetAddressAndSelectorPosition[selector].facetAddress;
      if (oldFacetAddress != address(0)) {
        revert CannotAddFunctionToDiamondThatAlreadyExists(selector);
      }
      ds.facetAddressAndSelectorPosition[selector] = FacetAddressAndSelectorPosition(_facetAddress, selectorCount);
      ds.selectors.push(selector);
      selectorCount++;
    }
  }

  function replaceFunctions(address _facetAddress, bytes4[] memory _functionSelectors) internal {
    DiamondStorage storage ds = diamondStorage();
    if (_facetAddress == address(0)) {
      revert CannotReplaceFunctionsFromFacetWithZeroAddress(_functionSelectors);
    }
    enforceHasContractCode(_facetAddress, "LibDiamondCut: Replace facet has no code");
    for (uint256 selectorIndex; selectorIndex < _functionSelectors.length; selectorIndex++) {
      bytes4 selector = _functionSelectors[selectorIndex];
      address oldFacetAddress = ds.facetAddressAndSelectorPosition[selector].facetAddress;
      // can't replace immutable functions -- functions defined directly in the diamond in this case
      if (oldFacetAddress == address(this)) {
        revert CannotReplaceImmutableFunction(selector);
      }
      if (oldFacetAddress == _facetAddress) {
        revert CannotReplaceFunctionWithTheSameFunctionFromTheSameFacet(selector);
      }
      if (oldFacetAddress == address(0)) {
        revert CannotReplaceFunctionThatDoesNotExists(selector);
      }
      // replace old facet address
      ds.facetAddressAndSelectorPosition[selector].facetAddress = _facetAddress;
    }
  }

  function removeFunctions(address _facetAddress, bytes4[] memory _functionSelectors) internal {
    DiamondStorage storage ds = diamondStorage();
    uint256 selectorCount = ds.selectors.length;
    if (_facetAddress != address(0)) {
      revert RemoveFacetAddressMustBeZeroAddress(_facetAddress);
    }
    for (uint256 selectorIndex; selectorIndex < _functionSelectors.length; selectorIndex++) {
      bytes4 selector = _functionSelectors[selectorIndex];
      FacetAddressAndSelectorPosition memory oldFacetAddressAndSelectorPosition = ds.facetAddressAndSelectorPosition[
        selector
      ];
      if (oldFacetAddressAndSelectorPosition.facetAddress == address(0)) {
        revert CannotRemoveFunctionThatDoesNotExist(selector);
      }

      // can't remove immutable functions -- functions defined directly in the diamond
      if (oldFacetAddressAndSelectorPosition.facetAddress == address(this)) {
        revert CannotRemoveImmutableFunction(selector);
      }
      // replace selector with last selector
      selectorCount--;
      if (oldFacetAddressAndSelectorPosition.selectorPosition != selectorCount) {
        bytes4 lastSelector = ds.selectors[selectorCount];
        ds.selectors[oldFacetAddressAndSelectorPosition.selectorPosition] = lastSelector;
        ds.facetAddressAndSelectorPosition[lastSelector].selectorPosition = oldFacetAddressAndSelectorPosition
          .selectorPosition;
      }
      // delete last selector
      ds.selectors.pop();
      delete ds.facetAddressAndSelectorPosition[selector];
    }
  }

  function initializeDiamondCut(address _init, bytes memory _calldata) internal {
    if (_init == address(0)) {
      return;
    }
    enforceHasContractCode(_init, "LibDiamondCut: _init address has no code");
    (bool success, bytes memory error) = _init.delegatecall(_calldata);
    if (!success) {
      if (error.length > 0) {
        // bubble up error
        /// @solidity memory-safe-assembly
        assembly {
          let returndata_size := mload(error)
          revert(add(32, error), returndata_size)
        }
      } else {
        revert InitializationFunctionReverted(_init, _calldata);
      }
    }
  }

  function enforceHasContractCode(address _contract, string memory _errorMessage) internal view {
    uint256 contractSize;
    assembly {
      contractSize := extcodesize(_contract)
    }
    if (contractSize == 0) {
      revert NoBytecodeAtAddress(_contract, _errorMessage);
    }
  }
}

File 4 of 4 : IDiamond.sol
// SPDX-License-Identifier: CC0-1.0
pragma solidity ^0.8.0;

/******************************************************************************\
* Author: Nick Mudge <[email protected]>, Twitter/Github: @mudgen
* EIP-2535 Diamonds
/******************************************************************************/

interface IDiamond {
  enum FacetCutAction {
    Add,
    Replace,
    Remove
  }
  // Add=0, Replace=1, Remove=2

  struct FacetCut {
    address facetAddress;
    FacetCutAction action;
    bytes4[] functionSelectors;
  }

  event DiamondCut(FacetCut[] _diamondCut, address _init, bytes _calldata);
}

Settings
{
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "libraries": {}
}

Contract Security Audit

Contract ABI

API
[{"inputs":[{"internalType":"bytes4","name":"_selector","type":"bytes4"}],"name":"CannotAddFunctionToDiamondThatAlreadyExists","type":"error"},{"inputs":[{"internalType":"bytes4[]","name":"_selectors","type":"bytes4[]"}],"name":"CannotAddSelectorsToZeroAddress","type":"error"},{"inputs":[{"internalType":"bytes4","name":"_selector","type":"bytes4"}],"name":"CannotRemoveFunctionThatDoesNotExist","type":"error"},{"inputs":[{"internalType":"bytes4","name":"_selector","type":"bytes4"}],"name":"CannotRemoveImmutableFunction","type":"error"},{"inputs":[{"internalType":"bytes4","name":"_selector","type":"bytes4"}],"name":"CannotReplaceFunctionThatDoesNotExists","type":"error"},{"inputs":[{"internalType":"bytes4","name":"_selector","type":"bytes4"}],"name":"CannotReplaceFunctionWithTheSameFunctionFromTheSameFacet","type":"error"},{"inputs":[{"internalType":"bytes4[]","name":"_selectors","type":"bytes4[]"}],"name":"CannotReplaceFunctionsFromFacetWithZeroAddress","type":"error"},{"inputs":[{"internalType":"bytes4","name":"_selector","type":"bytes4"}],"name":"CannotReplaceImmutableFunction","type":"error"},{"inputs":[{"internalType":"uint8","name":"_action","type":"uint8"}],"name":"IncorrectFacetCutAction","type":"error"},{"inputs":[{"internalType":"address","name":"_initializationContractAddress","type":"address"},{"internalType":"bytes","name":"_calldata","type":"bytes"}],"name":"InitializationFunctionReverted","type":"error"},{"inputs":[{"internalType":"address","name":"_contractAddress","type":"address"},{"internalType":"string","name":"_message","type":"string"}],"name":"NoBytecodeAtAddress","type":"error"},{"inputs":[{"internalType":"address","name":"_facetAddress","type":"address"}],"name":"NoSelectorsProvidedForFacetForCut","type":"error"},{"inputs":[{"internalType":"address","name":"_user","type":"address"},{"internalType":"address","name":"_contractOwner","type":"address"}],"name":"NotContractOwner","type":"error"},{"inputs":[{"internalType":"address","name":"_facetAddress","type":"address"}],"name":"RemoveFacetAddressMustBeZeroAddress","type":"error"},{"anonymous":false,"inputs":[{"components":[{"internalType":"address","name":"facetAddress","type":"address"},{"internalType":"enum IDiamond.FacetCutAction","name":"action","type":"uint8"},{"internalType":"bytes4[]","name":"functionSelectors","type":"bytes4[]"}],"indexed":false,"internalType":"struct IDiamond.FacetCut[]","name":"_diamondCut","type":"tuple[]"},{"indexed":false,"internalType":"address","name":"_init","type":"address"},{"indexed":false,"internalType":"bytes","name":"_calldata","type":"bytes"}],"name":"DiamondCut","type":"event"},{"inputs":[{"components":[{"internalType":"address","name":"facetAddress","type":"address"},{"internalType":"enum IDiamond.FacetCutAction","name":"action","type":"uint8"},{"internalType":"bytes4[]","name":"functionSelectors","type":"bytes4[]"}],"internalType":"struct IDiamond.FacetCut[]","name":"_diamondCut","type":"tuple[]"},{"internalType":"address","name":"_init","type":"address"},{"internalType":"bytes","name":"_calldata","type":"bytes"}],"name":"diamondCut","outputs":[],"stateMutability":"nonpayable","type":"function"}]

608060405234801561001057600080fd5b50610fce806100206000396000f3fe608060405234801561001057600080fd5b506004361061002b5760003560e01c80631f931c1c14610030575b600080fd5b61004361003e3660046109cb565b610045565b005b61004d61009e565b61009761005a8587610b11565b8484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061011792505050565b5050505050565b600080516020610f05833981519152600301546001600160a01b03163314610115577fc8fcad8db84d3cc18b4c41d551ea0ee66dd599cde068d998e57d5e09332c131f54604051600162bed83560e01b031981523360048201526001600160a01b0390911660248201526044015b60405180910390fd5b565b60005b835181101561028057600084828151811061013757610137610c55565b6020026020010151604001519050600085838151811061015957610159610c55565b60200260200101516000015190508151600014156101955760405163e767f91f60e01b81526001600160a01b038216600482015260240161010c565b60008684815181106101a9576101a9610c55565b6020026020010151602001519050600060028111156101ca576101ca610c6b565b8160028111156101dc576101dc610c6b565b14156101f1576101ec82846102cb565b61026a565b600181600281111561020557610205610c6b565b1415610215576101ec828461047f565b600281600281111561022957610229610c6b565b1415610239576101ec82846105f6565b80600281111561024b5761024b610c6b565b604051633ff4d20f60e11b815260ff909116600482015260240161010c565b505050808061027890610c97565b91505061011a565b507f8faa70878671ccd212d20771b795c50af8fd3ff6cf27f4bde57e5d4de0aeb6738383836040516102b493929190610d0a565b60405180910390a16102c6828261087c565b505050565b6001600160a01b0382166102f457806040516302b8da0760e21b815260040161010c9190610e0a565b7fc8fcad8db84d3cc18b4c41d551ea0ee66dd599cde068d998e57d5e09332c131d5460408051606081019091526024808252600080516020610f05833981519152929161034b91869190610f256020830139610942565b60005b835181101561009757600084828151811061036b5761036b610c55565b6020908102919091018101516001600160e01b031981166000908152918690526040909120549091506001600160a01b031680156103be578160405163ebbf5d0760e01b815260040161010c9190610e58565b6040805180820182526001600160a01b03808a16825261ffff80881660208085019182526001600160e01b0319881660009081528b8252958620945185549251909316600160a01b026001600160b01b0319909216929093169190911717909155600180880180549182018155835291206008820401805460e085901c60046007909416939093026101000a92830263ffffffff90930219169190911790558361046781610e6d565b9450505050808061047790610c97565b91505061034e565b600080516020610f058339815191526001600160a01b0383166104b7578160405163cd98a96f60e01b815260040161010c9190610e0a565b6104d983604051806060016040528060288152602001610f7160289139610942565b60005b82518110156105f05760008382815181106104f9576104f9610c55565b6020908102919091018101516001600160e01b031981166000908152918590526040909120549091506001600160a01b03163081141561054e5781604051632901806d60e11b815260040161010c9190610e58565b856001600160a01b0316816001600160a01b031614156105835781604051631ac6ce8d60e11b815260040161010c9190610e58565b6001600160a01b0381166105ac5781604051637479f93960e01b815260040161010c9190610e58565b506001600160e01b031916600090815260208390526040902080546001600160a01b0319166001600160a01b038616179055806105e881610c97565b9150506104dc565b50505050565b7fc8fcad8db84d3cc18b4c41d551ea0ee66dd599cde068d998e57d5e09332c131d54600080516020610f05833981519152906001600160a01b0384161561065b5760405163d091bc8160e01b81526001600160a01b038516600482015260240161010c565b60005b835181101561009757600084828151811061067b5761067b610c55565b6020908102919091018101516001600160e01b0319811660009081528683526040908190208151808301909252546001600160a01b038116808352600160a01b90910461ffff1693820193909352909250906106ec5781604051637a08a22d60e01b815260040161010c9190610e58565b80516001600160a01b03163014156107195781604051630df5fd6160e31b815260040161010c9190610e58565b8361072381610e8f565b94505083816020015161ffff161461080157600085600101858154811061074c5761074c610c55565b90600052602060002090600891828204019190066004029054906101000a900460e01b90508086600101836020015161ffff168154811061078f5761078f610c55565b600091825260208083206008830401805463ffffffff60079094166004026101000a938402191660e09590951c92909202939093179055838201516001600160e01b03199390931681529087905260409020805461ffff60a01b1916600160a01b61ffff909316929092029190911790555b8460010180548061081457610814610ea6565b60008281526020808220600860001990940193840401805463ffffffff600460078716026101000a0219169055919092556001600160e01b0319909316815291859052506040902080546001600160b01b03191690558061087481610c97565b91505061065e565b6001600160a01b03821661088e575050565b6108b082604051806060016040528060288152602001610f4960289139610942565b600080836001600160a01b0316836040516108cb9190610ebc565b600060405180830381855af49150503d8060008114610906576040519150601f19603f3d011682016040523d82523d6000602084013e61090b565b606091505b5091509150816105f0578051156109255780518082602001fd5b838360405163192105d760e01b815260040161010c929190610ed8565b813b806102c657828260405163919834b960e01b815260040161010c929190610ed8565b80356001600160a01b038116811461097d57600080fd5b919050565b60008083601f84011261099457600080fd5b50813567ffffffffffffffff8111156109ac57600080fd5b6020830191508360208285010111156109c457600080fd5b9250929050565b6000806000806000606086880312156109e357600080fd5b853567ffffffffffffffff808211156109fb57600080fd5b818801915088601f830112610a0f57600080fd5b813581811115610a1e57600080fd5b8960208260051b8501011115610a3357600080fd5b60208301975080965050610a4960208901610966565b94506040880135915080821115610a5f57600080fd5b50610a6c88828901610982565b969995985093965092949392505050565b634e487b7160e01b600052604160045260246000fd5b6040516060810167ffffffffffffffff81118282101715610ab657610ab6610a7d565b60405290565b604051601f8201601f1916810167ffffffffffffffff81118282101715610ae557610ae5610a7d565b604052919050565b600067ffffffffffffffff821115610b0757610b07610a7d565b5060051b60200190565b6000610b24610b1f84610aed565b610abc565b83815260208082019190600586811b860136811115610b4257600080fd5b865b81811015610c4857803567ffffffffffffffff80821115610b655760008081fd5b818a01915060608236031215610b7b5760008081fd5b610b83610a93565b610b8c83610966565b81528683013560038110610ba05760008081fd5b8188015260408381013583811115610bb85760008081fd5b939093019236601f850112610bcf57600092508283fd5b83359250610bdf610b1f84610aed565b83815292871b84018801928881019036851115610bfc5760008081fd5b948901945b84861015610c315785356001600160e01b031981168114610c225760008081fd5b82529489019490890190610c01565b918301919091525088525050948301948301610b44565b5092979650505050505050565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052602160045260246000fd5b634e487b7160e01b600052601160045260246000fd5b6000600019821415610cab57610cab610c81565b5060010190565b60005b83811015610ccd578181015183820152602001610cb5565b838111156105f05750506000910152565b60008151808452610cf6816020860160208601610cb2565b601f01601f19169290920160200192915050565b60006060808301818452808751808352608092508286019150828160051b8701016020808b0160005b84811015610dda57898403607f19018652815180516001600160a01b03168552838101518986019060038110610d7957634e487b7160e01b600052602160045260246000fd5b868601526040918201519186018a905281519081905290840190600090898701905b80831015610dc55783516001600160e01b0319168252928601926001929092019190860190610d9b565b50978501979550505090820190600101610d33565b50506001600160a01b038a16908801528681036040880152610dfc8189610cde565b9a9950505050505050505050565b6020808252825182820181905260009190848201906040850190845b81811015610e4c5783516001600160e01b03191683529284019291840191600101610e26565b50909695505050505050565b6001600160e01b031991909116815260200190565b600061ffff80831681811415610e8557610e85610c81565b6001019392505050565b600081610e9e57610e9e610c81565b506000190190565b634e487b7160e01b600052603160045260246000fd5b60008251610ece818460208701610cb2565b9190910192915050565b6001600160a01b0383168152604060208201819052600090610efc90830184610cde565b94935050505056fec8fcad8db84d3cc18b4c41d551ea0ee66dd599cde068d998e57d5e09332c131c4c69624469616d6f6e644375743a2041646420666163657420686173206e6f20636f64654c69624469616d6f6e644375743a205f696e6974206164647265737320686173206e6f20636f64654c69624469616d6f6e644375743a205265706c61636520666163657420686173206e6f20636f6465a26469706673582212205e860e2285aa9c499f6fb394c8557b0ac5b7c6b5e51f41c1bf850fe92746ac6864736f6c634300080c0033

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061002b5760003560e01c80631f931c1c14610030575b600080fd5b61004361003e3660046109cb565b610045565b005b61004d61009e565b61009761005a8587610b11565b8484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061011792505050565b5050505050565b600080516020610f05833981519152600301546001600160a01b03163314610115577fc8fcad8db84d3cc18b4c41d551ea0ee66dd599cde068d998e57d5e09332c131f54604051600162bed83560e01b031981523360048201526001600160a01b0390911660248201526044015b60405180910390fd5b565b60005b835181101561028057600084828151811061013757610137610c55565b6020026020010151604001519050600085838151811061015957610159610c55565b60200260200101516000015190508151600014156101955760405163e767f91f60e01b81526001600160a01b038216600482015260240161010c565b60008684815181106101a9576101a9610c55565b6020026020010151602001519050600060028111156101ca576101ca610c6b565b8160028111156101dc576101dc610c6b565b14156101f1576101ec82846102cb565b61026a565b600181600281111561020557610205610c6b565b1415610215576101ec828461047f565b600281600281111561022957610229610c6b565b1415610239576101ec82846105f6565b80600281111561024b5761024b610c6b565b604051633ff4d20f60e11b815260ff909116600482015260240161010c565b505050808061027890610c97565b91505061011a565b507f8faa70878671ccd212d20771b795c50af8fd3ff6cf27f4bde57e5d4de0aeb6738383836040516102b493929190610d0a565b60405180910390a16102c6828261087c565b505050565b6001600160a01b0382166102f457806040516302b8da0760e21b815260040161010c9190610e0a565b7fc8fcad8db84d3cc18b4c41d551ea0ee66dd599cde068d998e57d5e09332c131d5460408051606081019091526024808252600080516020610f05833981519152929161034b91869190610f256020830139610942565b60005b835181101561009757600084828151811061036b5761036b610c55565b6020908102919091018101516001600160e01b031981166000908152918690526040909120549091506001600160a01b031680156103be578160405163ebbf5d0760e01b815260040161010c9190610e58565b6040805180820182526001600160a01b03808a16825261ffff80881660208085019182526001600160e01b0319881660009081528b8252958620945185549251909316600160a01b026001600160b01b0319909216929093169190911717909155600180880180549182018155835291206008820401805460e085901c60046007909416939093026101000a92830263ffffffff90930219169190911790558361046781610e6d565b9450505050808061047790610c97565b91505061034e565b600080516020610f058339815191526001600160a01b0383166104b7578160405163cd98a96f60e01b815260040161010c9190610e0a565b6104d983604051806060016040528060288152602001610f7160289139610942565b60005b82518110156105f05760008382815181106104f9576104f9610c55565b6020908102919091018101516001600160e01b031981166000908152918590526040909120549091506001600160a01b03163081141561054e5781604051632901806d60e11b815260040161010c9190610e58565b856001600160a01b0316816001600160a01b031614156105835781604051631ac6ce8d60e11b815260040161010c9190610e58565b6001600160a01b0381166105ac5781604051637479f93960e01b815260040161010c9190610e58565b506001600160e01b031916600090815260208390526040902080546001600160a01b0319166001600160a01b038616179055806105e881610c97565b9150506104dc565b50505050565b7fc8fcad8db84d3cc18b4c41d551ea0ee66dd599cde068d998e57d5e09332c131d54600080516020610f05833981519152906001600160a01b0384161561065b5760405163d091bc8160e01b81526001600160a01b038516600482015260240161010c565b60005b835181101561009757600084828151811061067b5761067b610c55565b6020908102919091018101516001600160e01b0319811660009081528683526040908190208151808301909252546001600160a01b038116808352600160a01b90910461ffff1693820193909352909250906106ec5781604051637a08a22d60e01b815260040161010c9190610e58565b80516001600160a01b03163014156107195781604051630df5fd6160e31b815260040161010c9190610e58565b8361072381610e8f565b94505083816020015161ffff161461080157600085600101858154811061074c5761074c610c55565b90600052602060002090600891828204019190066004029054906101000a900460e01b90508086600101836020015161ffff168154811061078f5761078f610c55565b600091825260208083206008830401805463ffffffff60079094166004026101000a938402191660e09590951c92909202939093179055838201516001600160e01b03199390931681529087905260409020805461ffff60a01b1916600160a01b61ffff909316929092029190911790555b8460010180548061081457610814610ea6565b60008281526020808220600860001990940193840401805463ffffffff600460078716026101000a0219169055919092556001600160e01b0319909316815291859052506040902080546001600160b01b03191690558061087481610c97565b91505061065e565b6001600160a01b03821661088e575050565b6108b082604051806060016040528060288152602001610f4960289139610942565b600080836001600160a01b0316836040516108cb9190610ebc565b600060405180830381855af49150503d8060008114610906576040519150601f19603f3d011682016040523d82523d6000602084013e61090b565b606091505b5091509150816105f0578051156109255780518082602001fd5b838360405163192105d760e01b815260040161010c929190610ed8565b813b806102c657828260405163919834b960e01b815260040161010c929190610ed8565b80356001600160a01b038116811461097d57600080fd5b919050565b60008083601f84011261099457600080fd5b50813567ffffffffffffffff8111156109ac57600080fd5b6020830191508360208285010111156109c457600080fd5b9250929050565b6000806000806000606086880312156109e357600080fd5b853567ffffffffffffffff808211156109fb57600080fd5b818801915088601f830112610a0f57600080fd5b813581811115610a1e57600080fd5b8960208260051b8501011115610a3357600080fd5b60208301975080965050610a4960208901610966565b94506040880135915080821115610a5f57600080fd5b50610a6c88828901610982565b969995985093965092949392505050565b634e487b7160e01b600052604160045260246000fd5b6040516060810167ffffffffffffffff81118282101715610ab657610ab6610a7d565b60405290565b604051601f8201601f1916810167ffffffffffffffff81118282101715610ae557610ae5610a7d565b604052919050565b600067ffffffffffffffff821115610b0757610b07610a7d565b5060051b60200190565b6000610b24610b1f84610aed565b610abc565b83815260208082019190600586811b860136811115610b4257600080fd5b865b81811015610c4857803567ffffffffffffffff80821115610b655760008081fd5b818a01915060608236031215610b7b5760008081fd5b610b83610a93565b610b8c83610966565b81528683013560038110610ba05760008081fd5b8188015260408381013583811115610bb85760008081fd5b939093019236601f850112610bcf57600092508283fd5b83359250610bdf610b1f84610aed565b83815292871b84018801928881019036851115610bfc5760008081fd5b948901945b84861015610c315785356001600160e01b031981168114610c225760008081fd5b82529489019490890190610c01565b918301919091525088525050948301948301610b44565b5092979650505050505050565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052602160045260246000fd5b634e487b7160e01b600052601160045260246000fd5b6000600019821415610cab57610cab610c81565b5060010190565b60005b83811015610ccd578181015183820152602001610cb5565b838111156105f05750506000910152565b60008151808452610cf6816020860160208601610cb2565b601f01601f19169290920160200192915050565b60006060808301818452808751808352608092508286019150828160051b8701016020808b0160005b84811015610dda57898403607f19018652815180516001600160a01b03168552838101518986019060038110610d7957634e487b7160e01b600052602160045260246000fd5b868601526040918201519186018a905281519081905290840190600090898701905b80831015610dc55783516001600160e01b0319168252928601926001929092019190860190610d9b565b50978501979550505090820190600101610d33565b50506001600160a01b038a16908801528681036040880152610dfc8189610cde565b9a9950505050505050505050565b6020808252825182820181905260009190848201906040850190845b81811015610e4c5783516001600160e01b03191683529284019291840191600101610e26565b50909695505050505050565b6001600160e01b031991909116815260200190565b600061ffff80831681811415610e8557610e85610c81565b6001019392505050565b600081610e9e57610e9e610c81565b506000190190565b634e487b7160e01b600052603160045260246000fd5b60008251610ece818460208701610cb2565b9190910192915050565b6001600160a01b0383168152604060208201819052600090610efc90830184610cde565b94935050505056fec8fcad8db84d3cc18b4c41d551ea0ee66dd599cde068d998e57d5e09332c131c4c69624469616d6f6e644375743a2041646420666163657420686173206e6f20636f64654c69624469616d6f6e644375743a205f696e6974206164647265737320686173206e6f20636f64654c69624469616d6f6e644375743a205265706c61636520666163657420686173206e6f20636f6465a26469706673582212205e860e2285aa9c499f6fb394c8557b0ac5b7c6b5e51f41c1bf850fe92746ac6864736f6c634300080c0033

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.