ETH Price: $3,827.17 (-6.89%)

Contract

0x1CeC01DC0fFEE5eB5aF47DbEc1809F2A7c601C30

Overview

ETH Balance

0 ETH

ETH Value

$0.00

More Info

Private Name Tags

Multichain Info

N/A
Transaction Hash
Method
Block
From
To

There are no matching entries

Please try again later

Advanced mode:
Parent Transaction Hash Block From To
View All Internal Transactions

Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
ZeroExSettlerDeployerSafeModule

Compiler Version
v0.8.25+commit.b61c2a91

Optimization Enabled:
Yes with 1000000 runs

Other Settings:
cancun EvmVersion
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.25;

import {DEPLOYER} from "./DeployerAddress.sol";
import {IDeployer, IDeployerRemove} from "./IDeployer.sol";
import {Feature} from "./Feature.sol";
import {Nonce} from "./Nonce.sol";
import {Revert} from "../utils/Revert.sol";

interface ISafeMinimal {
    enum Operation {
        Call,
        DelegateCall
    }

    function execTransactionFromModuleReturnData(address to, uint256 value, bytes memory data, Operation operation)
        external
        returns (bool success, bytes memory returnData);

    function isOwner(address) external view returns (bool);
}

contract ZeroExSettlerDeployerSafeModule is IDeployerRemove {
    using Revert for bool;

    ISafeMinimal public immutable safe;
    IDeployer public constant deployer = IDeployer(DEPLOYER);

    constructor(address _safe) {
        assert(address(this) == 0x1CeC01DC0fFEE5eB5aF47DbEc1809F2A7c601C30 || block.chainid == 31337);
        safe = ISafeMinimal(_safe);
    }

    modifier onlyOwner() {
        require(safe.isOwner(msg.sender));
        _;
    }

    function _callSafeReturnBool() internal onlyOwner returns (bool) {
        (bool success, bytes memory returnData) =
            safe.execTransactionFromModuleReturnData(address(deployer), 0, msg.data, ISafeMinimal.Operation.Call);
        success.maybeRevert(returnData);
        return abi.decode(returnData, (bool));
    }

    function remove(Feature, Nonce) external override returns (bool) {
        return _callSafeReturnBool();
    }

    function remove(address) external override returns (bool) {
        return _callSafeReturnBool();
    }

    function removeAll(Feature) external override returns (bool) {
        return _callSafeReturnBool();
    }
}

File 2 of 11 : DeployerAddress.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.25;

address constant DEPLOYER = 0x00000000000004533Fe15556B1E086BB1A72cEae;

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.25;

import {IERC165} from "@forge-std/interfaces/IERC165.sol";
import {IOwnable} from "./IOwnable.sol";
import {IERC1967Proxy} from "../interfaces/IERC1967Proxy.sol";
import {IMultiCall} from "../interfaces/IMultiCall.sol";
import {Feature} from "./Feature.sol";
import {Nonce} from "./Nonce.sol";

interface IERC721View is IERC165 {
    event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);
    event PermanentURI(string, uint256 indexed); // not technically part of the standard

    function balanceOf(address) external view returns (uint256);
    function ownerOf(uint256 tokenId) external view returns (address);
    function getApproved(uint256 tokenId) external view returns (address);
    function isApprovedForAll(address owner, address operator) external view returns (bool);
}

interface IERC721ViewMetadata is IERC721View {
    function name() external view returns (string memory);
    function symbol() external view returns (string memory);
    function tokenURI(uint256) external view returns (string memory);
}

interface IDeployerRemove {
    function remove(Feature, Nonce) external returns (bool);
    function remove(address) external returns (bool);
    function removeAll(Feature) external returns (bool);
}

interface IDeployer is IOwnable, IERC721ViewMetadata, IMultiCall, IDeployerRemove {
    function authorized(Feature) external view returns (address, uint40);
    function descriptionHash(Feature) external view returns (bytes32);
    function prev(Feature) external view returns (address);
    function next(Feature) external view returns (address);
    function deployInfo(address) external view returns (Feature, Nonce);
    function authorize(Feature, address, uint40) external returns (bool);
    function setDescription(Feature, string calldata) external returns (string memory);
    function deploy(Feature, bytes calldata) external payable returns (address, Nonce);

    // ERC-6093 errors
    error ERC721InvalidOwner(address owner);
    error ERC721NonexistentToken(uint256 tokenId);

    error FeatureNotInitialized(Feature);
    error FeatureInitialized(Feature);
    error DeployFailed(Feature, Nonce, address);
    error FutureNonce(Nonce);
    error NoInstance();

    event Authorized(Feature indexed, address indexed, uint40);
    event Deployed(Feature indexed, Nonce indexed, address indexed);
    event Removed(Feature indexed, Nonce indexed, address indexed);
    event RemovedAll(Feature indexed);
}

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.25;

import {Panic} from "../utils/Panic.sol";

type Feature is uint128;

function eq(Feature a, Feature b) pure returns (bool) {
    return Feature.unwrap(a) == Feature.unwrap(b);
}

function isNull(Feature a) pure returns (bool) {
    return Feature.unwrap(a) == 0;
}

using {eq as ==, isNull} for Feature global;

function wrap(uint256 x) pure returns (Feature) {
    if (x > type(uint128).max) {
        Panic.panic(Panic.ARITHMETIC_OVERFLOW);
    }
    if (x == 0) {
        Panic.panic(Panic.ENUM_CAST);
    }
    return Feature.wrap(uint128(x));
}

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.25;

/// @dev if you update this, you also have to update the length of the array `NonceList.List.links` in Deployer.sol
type Nonce is uint32;

function incr(Nonce a) pure returns (Nonce) {
    return Nonce.wrap(Nonce.unwrap(a) + 1);
}

function gt(Nonce a, Nonce b) pure returns (bool) {
    return Nonce.unwrap(a) > Nonce.unwrap(b);
}

function eq(Nonce a, Nonce b) pure returns (bool) {
    return Nonce.unwrap(a) == Nonce.unwrap(b);
}

function isNull(Nonce a) pure returns (bool) {
    return Nonce.unwrap(a) == 0;
}

using {incr, gt as >, eq as ==, isNull} for Nonce global;

Nonce constant zero = Nonce.wrap(0);

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.25;

library Revert {
    function _revert(bytes memory reason) internal pure {
        assembly ("memory-safe") {
            revert(add(reason, 0x20), mload(reason))
        }
    }

    function maybeRevert(bool success, bytes memory reason) internal pure {
        if (!success) {
            _revert(reason);
        }
    }
}

// SPDX-License-Identifier: MIT
pragma solidity >=0.6.2;

interface IERC165 {
    /// @notice Query if a contract implements an interface
    /// @param interfaceID The interface identifier, as specified in ERC-165
    /// @dev Interface identification is specified in ERC-165. This function
    /// uses less than 30,000 gas.
    /// @return `true` if the contract implements `interfaceID` and
    /// `interfaceID` is not 0xffffffff, `false` otherwise
    function supportsInterface(bytes4 interfaceID) external view returns (bool);
}

// SPDX-License-Identifier: MIT
pragma solidity =0.8.25;

import {IERC165} from "@forge-std/interfaces/IERC165.sol";

interface IOwnable is IERC165 {
    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

    function owner() external view returns (address);

    function transferOwnership(address) external returns (bool);

    error PermissionDenied();
    error ZeroAddress();
}

// SPDX-License-Identifier: MIT
pragma solidity 0.8.25;

interface IERC1967Proxy {
    event Upgraded(address indexed implementation);

    function implementation() external view returns (address);

    function version() external view returns (string memory);

    function upgrade(address newImplementation) external payable returns (bool);

    function upgradeAndCall(address newImplementation, bytes calldata data) external payable returns (bool);
}

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.25;

interface IMultiCall {
    function multicall(bytes[] calldata datas) external;
}

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.25;

library Panic {
    function panic(uint256 code) internal pure {
        assembly ("memory-safe") {
            mstore(0x00, 0x4e487b71) // selector for `Panic(uint256)`
            mstore(0x20, code)
            revert(0x1c, 0x24)
        }
    }

    // https://docs.soliditylang.org/en/latest/control-structures.html#panic-via-assert-and-error-via-require
    uint8 internal constant GENERIC = 0x00;
    uint8 internal constant ASSERT_FAIL = 0x01;
    uint8 internal constant ARITHMETIC_OVERFLOW = 0x11;
    uint8 internal constant DIVISION_BY_ZERO = 0x12;
    uint8 internal constant ENUM_CAST = 0x21;
    uint8 internal constant CORRUPT_STORAGE_ARRAY = 0x22;
    uint8 internal constant POP_EMPTY_ARRAY = 0x31;
    uint8 internal constant ARRAY_OUT_OF_BOUNDS = 0x32;
    uint8 internal constant OUT_OF_MEMORY = 0x41;
    uint8 internal constant ZERO_FUNCTION_POINTER = 0x51;
}

Settings
{
  "remappings": [
    "@solmate/=lib/solmate/src/",
    "@permit2/=lib/permit2/src/",
    "@forge-std/=lib/forge-std/src/",
    "@forge-gas-snapshot/=lib/forge-gas-snapshot/src/",
    "@uniswapv4/=lib/v4-core/src/",
    "@eulerswap/=lib/euler-swap/src/",
    "forge-std/src/=lib/forge-std/src/",
    "solmate/=lib/solmate/",
    "openzeppelin-contracts/=lib/openzeppelin-contracts/contracts/"
  ],
  "optimizer": {
    "enabled": true,
    "runs": 1000000,
    "details": {
      "constantOptimizer": true,
      "yul": true
    }
  },
  "metadata": {
    "useLiteralContent": false,
    "bytecodeHash": "none",
    "appendCBOR": false
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "evmVersion": "cancun",
  "viaIR": true,
  "libraries": {}
}

Contract Security Audit

Contract ABI

API
[{"inputs":[{"internalType":"address","name":"_safe","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"deployer","outputs":[{"internalType":"contract IDeployer","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"remove","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"Feature","name":"","type":"uint128"},{"internalType":"Nonce","name":"","type":"uint32"}],"name":"remove","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"Feature","name":"","type":"uint128"}],"name":"removeAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"safe","outputs":[{"internalType":"contract ISafeMinimal","name":"","type":"address"}],"stateMutability":"view","type":"function"}]

60a03460ae57601f61058b38819003918201601f19168301916001600160401b0383118484101760b25780849260209460405283398101031260ae57516001600160a01b0381169081900360ae57731cec01dc0ffee5eb5af47dbec1809f2a7c601c303014801560a4575b156090576080526040516104c490816100c782396080518181816101df01526102cf0152f35b634e487b7160e01b5f52600160045260245ffd5b50617a694614606a565b5f80fd5b634e487b7160e01b5f52604160045260245ffdfe60806040908082526004361015610014575f80fd5b5f3560e01c908163186f0354146101975750806329092d0e1461013d578063633a506c146100eb578063ada52c261461009e5763d5f3948814610055575f80fd5b3461009a575f7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261009a57602090516d04533fe15556b1e086bb1a72ceae8152f35b5f80fd5b503461009a5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261009a576020906100d9610203565b506100e261029d565b90519015158152f35b503461009a57807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261009a57610122610203565b5060243563ffffffff81160361009a576020906100e261029d565b503461009a5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261009a5760043573ffffffffffffffffffffffffffffffffffffffff81160361009a576020906100e261029d565b3461009a575f7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261009a5760209073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b600435906fffffffffffffffffffffffffffffffff8216820361009a57565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761026357604052565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b5190811515820361009a57565b604080517f2f54bf6e0000000000000000000000000000000000000000000000000000000081523360048201526020907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16908281602481855afa9081156104ba575f91610485575b501561009a578251907f5229073f0000000000000000000000000000000000000000000000000000000082526d04533fe15556b1e086bb1a72ceae60048301525f602483015260806044830152366084830152365f60a48401375f60a436840101525f827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe092826064830152818360a48287601f36011681010301925af193841561047c575f925f956103f0575b505050156103ea57808280518101031261009a576103e79101610290565b90565b81519101fd5b91945091503d805f833e6104048183610222565b810191808284031261009a5761041982610290565b928483015167ffffffffffffffff9384821161009a57019181601f8401121561009a5782519384116102635785610458915197601f8601160187610222565b82865284838301011161009a57815f92858093018388015e850101525f80806103c9565b513d5f823e3d90fd5b90508281813d83116104b3575b61049c8183610222565b8101031261009a576104ad90610290565b5f61031b565b503d610492565b84513d5f823e3d90fd0000000000000000000000008e5de7118a596e99b0563d3022039c11927f4827

Deployed Bytecode

0x60806040908082526004361015610014575f80fd5b5f3560e01c908163186f0354146101975750806329092d0e1461013d578063633a506c146100eb578063ada52c261461009e5763d5f3948814610055575f80fd5b3461009a575f7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261009a57602090516d04533fe15556b1e086bb1a72ceae8152f35b5f80fd5b503461009a5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261009a576020906100d9610203565b506100e261029d565b90519015158152f35b503461009a57807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261009a57610122610203565b5060243563ffffffff81160361009a576020906100e261029d565b503461009a5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261009a5760043573ffffffffffffffffffffffffffffffffffffffff81160361009a576020906100e261029d565b3461009a575f7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261009a5760209073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000008e5de7118a596e99b0563d3022039c11927f4827168152f35b600435906fffffffffffffffffffffffffffffffff8216820361009a57565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761026357604052565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b5190811515820361009a57565b604080517f2f54bf6e0000000000000000000000000000000000000000000000000000000081523360048201526020907f0000000000000000000000008e5de7118a596e99b0563d3022039c11927f482773ffffffffffffffffffffffffffffffffffffffff16908281602481855afa9081156104ba575f91610485575b501561009a578251907f5229073f0000000000000000000000000000000000000000000000000000000082526d04533fe15556b1e086bb1a72ceae60048301525f602483015260806044830152366084830152365f60a48401375f60a436840101525f827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe092826064830152818360a48287601f36011681010301925af193841561047c575f925f956103f0575b505050156103ea57808280518101031261009a576103e79101610290565b90565b81519101fd5b91945091503d805f833e6104048183610222565b810191808284031261009a5761041982610290565b928483015167ffffffffffffffff9384821161009a57019181601f8401121561009a5782519384116102635785610458915197601f8601160187610222565b82865284838301011161009a57815f92858093018388015e850101525f80806103c9565b513d5f823e3d90fd5b90508281813d83116104b3575b61049c8183610222565b8101031261009a576104ad90610290565b5f61031b565b503d610492565b84513d5f823e3d90fd

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

0000000000000000000000008e5de7118a596e99b0563d3022039c11927f4827

-----Decoded View---------------
Arg [0] : _safe (address): 0x8E5DE7118a596E99B0563D3022039c11927f4827

-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 0000000000000000000000008e5de7118a596e99b0563d3022039c11927f4827


Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

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

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
0x1CeC01DC0fFEE5eB5aF47DbEc1809F2A7c601C30
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.