Cryo Explorer Ethereum Mainnet

Address Contract Verified

Address 0x705BfBcFCCde554E11DF213Bf6d463Ea00Dd57Cc
Balance 0 ETH
Nonce 1
Code Size 5127 bytes
Indexed Transactions 0
External Etherscan · Sourcify

Contract Bytecode

5127 bytes
0x6080604052600436106100965760003560e01c8063839df94511610069578063ceae4ad91161004e578063ceae4ad914610167578063f7a1696314610187578063f9cd32c51461019a57600080fd5b8063839df94514610127578063bf31e5301461014757600080fd5b80633223ded61461009b5780633d86c52f146100d15780633dbbcd8d146100ff57806379000a9014610114575b600080fd5b3480156100a757600080fd5b506100bb6100b6366004610e04565b6101f3565b6040516100c89190610e60565b60405180910390f35b3480156100dd57600080fd5b506100f16100ec366004610ee6565b610344565b6040519081526020016100c8565b61011261010d366004610f64565b61040f565b005b610112610122366004610fb0565b610682565b34801561013357600080fd5b506100f1610142366004611016565b6108f6565b34801561015357600080fd5b506100f1610162366004610f64565b6109ae565b34801561017357600080fd5b5061011261018236600461102f565b610aa6565b610112610195366004611071565b610b6e565b3480156101a657600080fd5b506101ce7f000000000000000000000000283af0b28c62c092c9727f1ee09c02ca627eb7f581565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100c8565b60608367ffffffffffffffff81111561020e5761020e6110fa565b604051908082528060200260200182016040528015610237578160200160208202803683370190505b50905060005b8481101561033b577f000000000000000000000000283af0b28c62c092c9727f1ee09c02ca627eb7f573ffffffffffffffffffffffffffffffffffffffff16633d86c52f87878481811061029357610293611129565b90506020028101906102a59190611158565b87876000806040518763ffffffff1660e01b81526004016102cb96959493929190611206565b602060405180830381865afa1580156102e8573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061030c919061125a565b82828151811061031e5761031e611129565b602090810291909101015280610333816112a2565b91505061023d565b50949350505050565b6040517f3d86c52f00000000000000000000000000000000000000000000000000000000815260009073ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000283af0b28c62c092c9727f1ee09c02ca627eb7f51690633d86c52f906103c3908a908a908a908a908a908a90600401611206565b602060405180830381865afa1580156103e0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610404919061125a565b979650505050505050565b6000805b838110156105b35760007f000000000000000000000000283af0b28c62c092c9727f1ee09c02ca627eb7f573ffffffffffffffffffffffffffffffffffffffff166383e7f6ff87878581811061046b5761046b611129565b905060200281019061047d9190611158565b876040518463ffffffff1660e01b815260040161049c939291906112db565b602060405180830381865afa1580156104b9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104dd919061125a565b90507f000000000000000000000000283af0b28c62c092c9727f1ee09c02ca627eb7f573ffffffffffffffffffffffffffffffffffffffff1663acf1a8418288888681811061052e5761052e611129565b90506020028101906105409190611158565b886040518563ffffffff1660e01b815260040161055f939291906112db565b6000604051808303818588803b15801561057857600080fd5b505af115801561058c573d6000803e3d6000fd5b5050505050808361059d91906112ff565b92505080806105ab906112a2565b915050610413565b508034111561067c576000336105c98334611317565b604051600081818185875af1925050503d8060008114610605576040519150601f19603f3d011682016040523d82523d6000602084013e61060a565b606091505b505090508061067a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4661696c656420746f2073656e6420457468657200000000000000000000000060448201526064015b60405180910390fd5b505b50505050565b6000805b8581101561082a5760007f000000000000000000000000283af0b28c62c092c9727f1ee09c02ca627eb7f573ffffffffffffffffffffffffffffffffffffffff166383e7f6ff8989858181106106de576106de611129565b90506020028101906106f09190611158565b886040518463ffffffff1660e01b815260040161070f939291906112db565b602060405180830381865afa15801561072c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610750919061125a565b90507f000000000000000000000000283af0b28c62c092c9727f1ee09c02ca627eb7f573ffffffffffffffffffffffffffffffffffffffff166385f6d155828a8a868181106107a1576107a1611129565b90506020028101906107b39190611158565b8a8a8a6040518763ffffffff1660e01b81526004016107d695949392919061132e565b6000604051808303818588803b1580156107ef57600080fd5b505af1158015610803573d6000803e3d6000fd5b5050505050808361081491906112ff565b9250508080610822906112a2565b915050610686565b50803411156108ee576000336108408334611317565b604051600081818185875af1925050503d806000811461087c576040519150601f19603f3d011682016040523d82523d6000602084013e610881565b606091505b50509050806108ec576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4661696c656420746f2073656e642045746865720000000000000000000000006044820152606401610671565b505b505050505050565b6040517f839df945000000000000000000000000000000000000000000000000000000008152600481018290526000907f000000000000000000000000283af0b28c62c092c9727f1ee09c02ca627eb7f573ffffffffffffffffffffffffffffffffffffffff169063839df94590602401602060405180830381865afa158015610984573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109a8919061125a565b92915050565b6000805b83811015610a9e5760007f000000000000000000000000283af0b28c62c092c9727f1ee09c02ca627eb7f573ffffffffffffffffffffffffffffffffffffffff166383e7f6ff878785818110610a0a57610a0a611129565b9050602002810190610a1c9190611158565b876040518463ffffffff1660e01b8152600401610a3b939291906112db565b602060405180830381865afa158015610a58573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a7c919061125a565b9050610a8881846112ff565b9250508080610a96906112a2565b9150506109b2565b509392505050565b60005b81811015610b69577f000000000000000000000000283af0b28c62c092c9727f1ee09c02ca627eb7f573ffffffffffffffffffffffffffffffffffffffff1663f14fcbc8848484818110610aff57610aff611129565b905060200201356040518263ffffffff1660e01b8152600401610b2491815260200190565b600060405180830381600087803b158015610b3e57600080fd5b505af1158015610b52573d6000803e3d6000fd5b505050508080610b61906112a2565b915050610aa9565b505050565b6040517f83e7f6ff00000000000000000000000000000000000000000000000000000000815260009073ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000283af0b28c62c092c9727f1ee09c02ca627eb7f516906383e7f6ff90610be7908b908b908a906004016112db565b602060405180830381865afa158015610c04573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c28919061125a565b90507f000000000000000000000000283af0b28c62c092c9727f1ee09c02ca627eb7f573ffffffffffffffffffffffffffffffffffffffff1663f7a16963828a8a8a8a8a8a8a6040518963ffffffff1660e01b8152600401610c909796959493929190611375565b6000604051808303818588803b158015610ca957600080fd5b505af1158015610cbd573d6000803e3d6000fd5b505050505080341115610d8557600033610cd78334611317565b604051600081818185875af1925050503d8060008114610d13576040519150601f19603f3d011682016040523d82523d6000602084013e610d18565b606091505b5050905080610d83576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4661696c656420746f2073656e642045746865720000000000000000000000006044820152606401610671565b505b5050505050505050565b60008083601f840112610da157600080fd5b50813567ffffffffffffffff811115610db957600080fd5b6020830191508360208260051b8501011115610dd457600080fd5b9250929050565b803573ffffffffffffffffffffffffffffffffffffffff81168114610dff57600080fd5b919050565b60008060008060608587031215610e1a57600080fd5b843567ffffffffffffffff811115610e3157600080fd5b610e3d87828801610d8f565b9095509350610e50905060208601610ddb565b9396929550929360400135925050565b6020808252825182820181905260009190848201906040850190845b81811015610e9857835183529284019291840191600101610e7c565b50909695505050505050565b60008083601f840112610eb657600080fd5b50813567ffffffffffffffff811115610ece57600080fd5b602083019150836020828501011115610dd457600080fd5b60008060008060008060a08789031215610eff57600080fd5b863567ffffffffffffffff811115610f1657600080fd5b610f2289828a01610ea4565b9097509550610f35905060208801610ddb565b935060408701359250610f4a60608801610ddb565b9150610f5860808801610ddb565b90509295509295509295565b600080600060408486031215610f7957600080fd5b833567ffffffffffffffff811115610f9057600080fd5b610f9c86828701610d8f565b909790965060209590950135949350505050565b600080600080600060808688031215610fc857600080fd5b853567ffffffffffffffff811115610fdf57600080fd5b610feb88828901610d8f565b9096509450610ffe905060208701610ddb565b94979396509394604081013594506060013592915050565b60006020828403121561102857600080fd5b5035919050565b6000806020838503121561104257600080fd5b823567ffffffffffffffff81111561105957600080fd5b61106585828601610d8f565b90969095509350505050565b600080600080600080600060c0888a03121561108c57600080fd5b873567ffffffffffffffff8111156110a357600080fd5b6110af8a828b01610ea4565b90985096506110c2905060208901610ddb565b945060408801359350606088013592506110de60808901610ddb565b91506110ec60a08901610ddb565b905092959891949750929550565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261118d57600080fd5b83018035915067ffffffffffffffff8211156111a857600080fd5b602001915036819003821315610dd457600080fd5b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b60a08152600061121a60a08301888a6111bd565b73ffffffffffffffffffffffffffffffffffffffff9687166020840152604083019590955250918416606083015290921660809092019190915292915050565b60006020828403121561126c57600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8214156112d4576112d4611273565b5060010190565b6040815260006112ef6040830185876111bd565b9050826020830152949350505050565b6000821982111561131257611312611273565b500190565b60008282101561132957611329611273565b500390565b6080815260006113426080830187896111bd565b73ffffffffffffffffffffffffffffffffffffffff95909516602083015250604081019290925260609091015292915050565b60c08152600061138960c08301898b6111bd565b905073ffffffffffffffffffffffffffffffffffffffff8088166020840152866040840152856060840152808516608084015280841660a0840152509897505050505050505056fea2646970667358221220dd0ddea02c8de243b01b9ec16a1d0cf88f22463b599d637dbeb783b94a039f2764736f6c634300080c0033

Verified Source Code Full Match

Compiler: v0.8.12+commit.f00d7308 EVM: london Optimization: Yes (10000 runs)
ETHBulkRegistrar.sol 83 lines
// SPDX-License-Identifier: MIT
pragma solidity >=0.8.4;
import "./IETHBulkRegistrar.sol";
import "./IETHRegistrarController.sol";

contract ETHBulkRegistrar is IETHBulkRegistrar {
    IETHRegistrarController public immutable registrarController;

    constructor(IETHRegistrarController _registrarController) {
        registrarController = _registrarController;
    }

    function bulkRentPrice(string[] calldata names, uint256 duration) external view override returns (uint256 total) {
        for (uint256 i = 0; i < names.length; i++) {
            uint price = registrarController.rentPrice(names[i], duration);
            total += price;
        }
        return total;
    }

    function bulkMakeCommitment(string[] calldata name, address owner, bytes32 secret) external view override returns (bytes32[] memory commitmentList) {
        commitmentList = new bytes32[](name.length);
        for (uint256 i = 0; i < name.length; i++) {
            commitmentList[i] = registrarController.makeCommitmentWithConfig(name[i], owner, secret, address(0), address(0));
        }
        return commitmentList;
    }

    function commitments(bytes32 commit) external view override returns (uint256) {
        return registrarController.commitments(commit);
    }

    function bulkCommit(bytes32[] calldata commitmentList) external override {
        for (uint256 i = 0; i < commitmentList.length; i++) {
            registrarController.commit(commitmentList[i]);
        }
    }

    function bulkRegister(string[] calldata names, address owner, uint duration, bytes32 secret) external payable override {
        uint256 cost = 0;
        for (uint256 i = 0; i < names.length; i++) {
            uint price = registrarController.rentPrice(names[i], duration);
            registrarController.register{value: (price)}(names[i], owner, duration, secret);
            cost = cost + price;
        }

        // Send any excess funds back
        if (msg.value > cost) {
            (bool sent, ) = msg.sender.call{value: msg.value - cost}("");
            require(sent, "Failed to send Ether");
        }
    }

    function bulkRenew(string[] calldata names, uint duration) external payable override {
        uint256 cost = 0;
        for (uint256 i = 0; i < names.length; i++) {
            uint price = registrarController.rentPrice(names[i], duration);
            registrarController.renew{value: (price)}(names[i], duration);
            cost = cost + price;
        }

        // Send any excess funds back
        if (msg.value > cost) {
            (bool sent, ) = msg.sender.call{value: msg.value - cost}("");
            require(sent, "Failed to send Ether");
        }
    }

    function registerWithConfig(string calldata name, address owner, uint duration, bytes32 secret, address resolver, address addr) external payable override {
        uint cost = registrarController.rentPrice(name, duration);
        registrarController.registerWithConfig{value: cost}(name, owner, duration, secret, resolver, addr);
        // Send any excess funds back
        if (msg.value > cost) {
            (bool sent, ) = msg.sender.call{value: msg.value - cost}("");
            require(sent, "Failed to send Ether");
        }
    }

    function makeCommitmentWithConfig(string calldata name, address owner, bytes32 secret, address resolver, address addr) external view override returns (bytes32 commitment) {
        commitment = registrarController.makeCommitmentWithConfig(name, owner, secret, resolver, addr);
        return commitment;
    }
}
IETHBulkRegistrar.sol 19 lines
pragma solidity >=0.8.4;

interface IETHBulkRegistrar {
    function bulkRentPrice(string[] calldata names, uint256 duration) external view returns (uint256 total);

    function bulkRegister(string[] calldata names, address owner, uint duration, bytes32 secret) external payable;

    function bulkRenew(string[] calldata names, uint duration) external payable;

    function bulkCommit(bytes32[] calldata commitments) external;

    function bulkMakeCommitment(string[] calldata name, address owner, bytes32 secret) external view returns (bytes32[] memory commitments);

    function commitments(bytes32 commit) external view returns (uint256);

    function registerWithConfig(string calldata name, address owner, uint duration, bytes32 secret, address resolver, address addr) external payable;

    function makeCommitmentWithConfig(string calldata name, address owner, bytes32 secret, address resolver, address addr) external view returns (bytes32);
}
IETHRegistrarController.sol 19 lines
pragma solidity >=0.8.4;

interface IETHRegistrarController {
    function rentPrice(string memory, uint) external view returns (uint);

    function available(string memory) external returns (bool);

    function commit(bytes32) external;

    function register(string calldata, address, uint256, bytes32) external payable;

    function registerWithConfig(string memory, address, uint256, bytes32, address, address) external payable;

    function makeCommitmentWithConfig(string memory, address, bytes32, address, address) external pure returns (bytes32);

    function renew(string calldata, uint256) external payable;

    function commitments(bytes32) external view returns (uint256);
}

Read Contract

bulkMakeCommitment 0x3223ded6 → bytes32[]
bulkRentPrice 0xbf31e530 → uint256
commitments 0x839df945 → uint256
makeCommitmentWithConfig 0x3d86c52f → bytes32
registrarController 0xf9cd32c5 → address

Write Contract 4 functions

These functions modify contract state and require a wallet transaction to execute.

bulkCommit 0xceae4ad9
bytes32[] commitmentList
bulkRegister 0x79000a90
string[] names
address owner
uint256 duration
bytes32 secret
bulkRenew 0x3dbbcd8d
string[] names
uint256 duration
registerWithConfig 0xf7a16963
string name
address owner
uint256 duration
bytes32 secret
address resolver
address addr

Recent Transactions

No transactions found for this address