ETH Price: $3,315.14 (+1.70%)
Gas: 3 Gwei

Contract

0xb321a96f0830ca6a1100DCa7c073C269D9738C81
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Clone143844472022-03-14 11:26:52868 days ago1647257212IN
0xb321a96f...9D9738C81
0 ETH0.0005783215.89472427
Clone143843612022-03-14 11:07:54868 days ago1647256074IN
0xb321a96f...9D9738C81
0 ETH0.0005511117.18168888
Clone143842992022-03-14 10:54:47868 days ago1647255287IN
0xb321a96f...9D9738C81
0 ETH0.000694819.09589294
Clone143831452022-03-14 6:31:00868 days ago1647239460IN
0xb321a96f...9D9738C81
0 ETH0.0020742257.00759112
Clone143706352022-03-12 7:38:54870 days ago1647070734IN
0xb321a96f...9D9738C81
0 ETH0.0003670611.44370057
Clone143706352022-03-12 7:38:54870 days ago1647070734IN
0xb321a96f...9D9738C81
0 ETH0.0003670611.44370057
Clone143599892022-03-10 15:49:55872 days ago1646927395IN
0xb321a96f...9D9738C81
0 ETH0.0011131634.70412348
Clone143498702022-03-09 2:14:08873 days ago1646792048IN
0xb321a96f...9D9738C81
0 ETH0.0014387544.8546834
Clone143022142022-03-01 16:29:33881 days ago1646152173IN
0xb321a96f...9D9738C81
0 ETH0.0014598745.51313528
Clone142910982022-02-27 23:03:29882 days ago1646003009IN
0xb321a96f...9D9738C81
0 ETH0.0014300144.58211782
Clone142835882022-02-26 19:16:15884 days ago1645902975IN
0xb321a96f...9D9738C81
0 ETH0.0015232347.48845995
Clone142545722022-02-22 7:43:01888 days ago1645515781IN
0xb321a96f...9D9738C81
0 ETH0.0039361667.94698543
Clone142286102022-02-18 7:05:06892 days ago1645167906IN
0xb321a96f...9D9738C81
0 ETH0.0013442236.94440266
Clone142232252022-02-17 10:55:09893 days ago1645095309IN
0xb321a96f...9D9738C81
0 ETH0.0024609639.53991211
Clone142189962022-02-16 19:16:01894 days ago1645038961IN
0xb321a96f...9D9738C81
0 ETH0.0034075293.65179932
Clone142166372022-02-16 10:38:08894 days ago1645007888IN
0xb321a96f...9D9738C81
0 ETH0.0010955434.15454977
Clone142122332022-02-15 18:03:58895 days ago1644948238IN
0xb321a96f...9D9738C81
0 ETH0.0025298578.87050309
Clone142009532022-02-14 0:15:03896 days ago1644797703IN
0xb321a96f...9D9738C81
0 ETH0.0014830146.23431659
Clone141849252022-02-11 13:07:39899 days ago1644584859IN
0xb321a96f...9D9738C81
0 ETH0.0019898854.68966312
Clone141693382022-02-09 3:03:32901 days ago1644375812IN
0xb321a96f...9D9738C81
0 ETH0.0025222669.32158245
Clone141623152022-02-08 0:48:03902 days ago1644281283IN
0xb321a96f...9D9738C81
0 ETH0.0031594898.49989903
Clone141521322022-02-06 11:05:47904 days ago1644145547IN
0xb321a96f...9D9738C81
0 ETH0.0021763444.13415058
Clone141412872022-02-04 19:00:34906 days ago1644001234IN
0xb321a96f...9D9738C81
0 ETH0.005525122.76980739
Clone141368732022-02-04 2:41:04906 days ago1643942464IN
0xb321a96f...9D9738C81
0 ETH0.0034193884.05154877
Clone141368532022-02-04 2:37:29906 days ago1643942249IN
0xb321a96f...9D9738C81
0 ETH0.0038682495.08501673
View all transactions

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
EthClone

Compiler Version
v0.8.0+commit.c7dfd78e

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 5 : EthClone.sol
// SPDX-License-Identifier: GPL-3.0
pragma solidity ^0.8.0;

import "./IPepper.sol";

contract EthClone {
    event Clone(uint256[] nftIds);

    IPepper public pepperContract;

    constructor(IPepper pepperAddress) {
        pepperContract = pepperAddress;
    }

    function clone(uint256[] calldata nftIds) external {
        for (uint16 i = 0; i < nftIds.length; i++) {
            require(
                pepperContract.ownerOf(nftIds[i]) == msg.sender,
                "The sender doesn't own the tokens"
            );
        }

        emit Clone(nftIds);
    }

    function tokensOf(address _address)
        external
        view
        returns (uint256[] memory)
    {
        uint256 numPeppers = pepperContract.balanceOf(_address);
        uint256[] memory tokens = new uint256[](numPeppers);
        for (uint256 i = 0; i < numPeppers; i++) {
            uint256 token = pepperContract.tokenOfOwnerByIndex(_address, i);
            tokens[i] = token;
        }

        return tokens;
    }
}

File 2 of 5 : IPepper.sol
// SPDX-License-Identifier: GPL-3.0
pragma solidity ^0.8.0;

import "@openzeppelin/contracts/token/ERC721/IERC721.sol";
import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable.sol";

interface IPepper is IERC721, IERC721Enumerable {
    function burn(uint256 nftId) external;

    function directMint(address to, uint256[] calldata nftIds) external;

    function checkApprovedOrOwner(address spender, uint256 nftId)
        external
        view
        returns (bool);
}

File 3 of 5 : IERC721.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../../utils/introspection/IERC165.sol";

/**
 * @dev Required interface of an ERC721 compliant contract.
 */
interface IERC721 is IERC165 {
    /**
     * @dev Emitted when `tokenId` token is transferred from `from` to `to`.
     */
    event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);

    /**
     * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token.
     */
    event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);

    /**
     * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets.
     */
    event ApprovalForAll(address indexed owner, address indexed operator, bool approved);

    /**
     * @dev Returns the number of tokens in ``owner``'s account.
     */
    function balanceOf(address owner) external view returns (uint256 balance);

    /**
     * @dev Returns the owner of the `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function ownerOf(uint256 tokenId) external view returns (address owner);

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
     * are aware of the ERC721 protocol to prevent tokens from being forever locked.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

    /**
     * @dev Transfers `tokenId` token from `from` to `to`.
     *
     * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

    /**
     * @dev Gives permission to `to` to transfer `tokenId` token to another account.
     * The approval is cleared when the token is transferred.
     *
     * Only a single account can be approved at a time, so approving the zero address clears previous approvals.
     *
     * Requirements:
     *
     * - The caller must own the token or be an approved operator.
     * - `tokenId` must exist.
     *
     * Emits an {Approval} event.
     */
    function approve(address to, uint256 tokenId) external;

    /**
     * @dev Returns the account approved for `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function getApproved(uint256 tokenId) external view returns (address operator);

    /**
     * @dev Approve or remove `operator` as an operator for the caller.
     * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller.
     *
     * Requirements:
     *
     * - The `operator` cannot be the caller.
     *
     * Emits an {ApprovalForAll} event.
     */
    function setApprovalForAll(address operator, bool _approved) external;

    /**
     * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`.
     *
     * See {setApprovalForAll}
     */
    function isApprovedForAll(address owner, address operator) external view returns (bool);

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes calldata data
    ) external;
}

File 4 of 5 : IERC721Enumerable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../IERC721.sol";

/**
 * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
interface IERC721Enumerable is IERC721 {
    /**
     * @dev Returns the total amount of tokens stored by the contract.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns a token ID owned by `owner` at a given `index` of its token list.
     * Use along with {balanceOf} to enumerate all of ``owner``'s tokens.
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) external view returns (uint256 tokenId);

    /**
     * @dev Returns a token ID at a given `index` of all the tokens stored by the contract.
     * Use along with {totalSupply} to enumerate all tokens.
     */
    function tokenByIndex(uint256 index) external view returns (uint256);
}

File 5 of 5 : IERC165.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC165 standard, as defined in the
 * https://eips.ethereum.org/EIPS/eip-165[EIP].
 *
 * Implementers can declare support of contract interfaces, which can then be
 * queried by others ({ERC165Checker}).
 *
 * For an implementation, see {ERC165}.
 */
interface IERC165 {
    /**
     * @dev Returns true if this contract implements the interface defined by
     * `interfaceId`. See the corresponding
     * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
     * to learn more about how these ids are created.
     *
     * This function call must use less than 30 000 gas.
     */
    function supportsInterface(bytes4 interfaceId) external view returns (bool);
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"contract IPepper","name":"pepperAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256[]","name":"nftIds","type":"uint256[]"}],"name":"Clone","type":"event"},{"inputs":[{"internalType":"uint256[]","name":"nftIds","type":"uint256[]"}],"name":"clone","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"pepperContract","outputs":[{"internalType":"contract IPepper","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"}],"name":"tokensOf","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"}]

608060405234801561001057600080fd5b5060405161067e38038061067e83398101604081905261002f91610054565b600080546001600160a01b0319166001600160a01b0392909216919091179055610082565b600060208284031215610065578081fd5b81516001600160a01b038116811461007b578182fd5b9392505050565b6105ed806100916000396000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c80633a7d1fed146100465780633df3f7ca146100645780635a3f267214610079575b600080fd5b61004e610099565b60405161005b9190610457565b60405180910390f35b6100776100723660046103d0565b6100a8565b005b61008c610087366004610391565b6101e0565b60405161005b91906104be565b6000546001600160a01b031681565b60005b61ffff81168211156101a25760005433906001600160a01b0316636352211e858561ffff86168181106100ee57634e487b7160e01b600052603260045260246000fd5b905060200201356040518263ffffffff1660e01b81526004016101119190610543565b60206040518083038186803b15801561012957600080fd5b505afa15801561013d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061016191906103b4565b6001600160a01b0316146101905760405162461bcd60e51b815260040161018790610502565b60405180910390fd5b8061019a8161054c565b9150506100ab565b507ffd8ceed0a0676f4562420cbb9a968acf554aa48a0565ec0858ee0f20a630084882826040516101d4929190610484565b60405180910390a15050565b600080546040516370a0823160e01b8152606092916001600160a01b0316906370a0823190610213908690600401610457565b60206040518083038186803b15801561022b57600080fd5b505afa15801561023f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610263919061043f565b905060008167ffffffffffffffff81111561028e57634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156102b7578160200160208202803683370190505b50905060005b828110156103895760008054604051632f745c5960e01b81526001600160a01b0390911690632f745c59906102f8908990869060040161046b565b60206040518083038186803b15801561031057600080fd5b505afa158015610324573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610348919061043f565b90508083838151811061036b57634e487b7160e01b600052603260045260246000fd5b602090810291909101015250806103818161056e565b9150506102bd565b509392505050565b6000602082840312156103a2578081fd5b81356103ad8161059f565b9392505050565b6000602082840312156103c5578081fd5b81516103ad8161059f565b600080602083850312156103e2578081fd5b823567ffffffffffffffff808211156103f9578283fd5b818501915085601f83011261040c578283fd5b81358181111561041a578384fd5b866020808302850101111561042d578384fd5b60209290920196919550909350505050565b600060208284031215610450578081fd5b5051919050565b6001600160a01b0391909116815260200190565b6001600160a01b03929092168252602082015260400190565b6020808252810182905260006001600160fb1b038311156104a3578081fd5b60208302808560408501379190910160400190815292915050565b6020808252825182820181905260009190848201906040850190845b818110156104f6578351835292840192918401916001016104da565b50909695505050505050565b60208082526021908201527f5468652073656e64657220646f65736e2774206f776e2074686520746f6b656e6040820152607360f81b606082015260800190565b90815260200190565b600061ffff8083168181141561056457610564610589565b6001019392505050565b600060001982141561058257610582610589565b5060010190565b634e487b7160e01b600052601160045260246000fd5b6001600160a01b03811681146105b457600080fd5b5056fea2646970667358221220a710b8c6200e66e08ba607afad81125f8c1977a3f8f9ba028b054c40fa05d7b564736f6c6343000800003300000000000000000000000026aede53a9a3a533c4ee341922d84bc9c19dcd13

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106100415760003560e01c80633a7d1fed146100465780633df3f7ca146100645780635a3f267214610079575b600080fd5b61004e610099565b60405161005b9190610457565b60405180910390f35b6100776100723660046103d0565b6100a8565b005b61008c610087366004610391565b6101e0565b60405161005b91906104be565b6000546001600160a01b031681565b60005b61ffff81168211156101a25760005433906001600160a01b0316636352211e858561ffff86168181106100ee57634e487b7160e01b600052603260045260246000fd5b905060200201356040518263ffffffff1660e01b81526004016101119190610543565b60206040518083038186803b15801561012957600080fd5b505afa15801561013d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061016191906103b4565b6001600160a01b0316146101905760405162461bcd60e51b815260040161018790610502565b60405180910390fd5b8061019a8161054c565b9150506100ab565b507ffd8ceed0a0676f4562420cbb9a968acf554aa48a0565ec0858ee0f20a630084882826040516101d4929190610484565b60405180910390a15050565b600080546040516370a0823160e01b8152606092916001600160a01b0316906370a0823190610213908690600401610457565b60206040518083038186803b15801561022b57600080fd5b505afa15801561023f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610263919061043f565b905060008167ffffffffffffffff81111561028e57634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156102b7578160200160208202803683370190505b50905060005b828110156103895760008054604051632f745c5960e01b81526001600160a01b0390911690632f745c59906102f8908990869060040161046b565b60206040518083038186803b15801561031057600080fd5b505afa158015610324573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610348919061043f565b90508083838151811061036b57634e487b7160e01b600052603260045260246000fd5b602090810291909101015250806103818161056e565b9150506102bd565b509392505050565b6000602082840312156103a2578081fd5b81356103ad8161059f565b9392505050565b6000602082840312156103c5578081fd5b81516103ad8161059f565b600080602083850312156103e2578081fd5b823567ffffffffffffffff808211156103f9578283fd5b818501915085601f83011261040c578283fd5b81358181111561041a578384fd5b866020808302850101111561042d578384fd5b60209290920196919550909350505050565b600060208284031215610450578081fd5b5051919050565b6001600160a01b0391909116815260200190565b6001600160a01b03929092168252602082015260400190565b6020808252810182905260006001600160fb1b038311156104a3578081fd5b60208302808560408501379190910160400190815292915050565b6020808252825182820181905260009190848201906040850190845b818110156104f6578351835292840192918401916001016104da565b50909695505050505050565b60208082526021908201527f5468652073656e64657220646f65736e2774206f776e2074686520746f6b656e6040820152607360f81b606082015260800190565b90815260200190565b600061ffff8083168181141561056457610564610589565b6001019392505050565b600060001982141561058257610582610589565b5060010190565b634e487b7160e01b600052601160045260246000fd5b6001600160a01b03811681146105b457600080fd5b5056fea2646970667358221220a710b8c6200e66e08ba607afad81125f8c1977a3f8f9ba028b054c40fa05d7b564736f6c63430008000033

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

00000000000000000000000026aede53a9a3a533c4ee341922d84bc9c19dcd13

-----Decoded View---------------
Arg [0] : pepperAddress (address): 0x26AeDE53a9A3a533C4Ee341922d84bC9c19dcd13

-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 00000000000000000000000026aede53a9a3a533c4ee341922d84bc9c19dcd13


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
Loading...
Loading
[ Download: CSV Export  ]

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.