ETH Price: $2,901.16 (-10.48%)
Gas: 27 Gwei

Contract

0x2b860c491E0141806DF58FeAa65fef67a46bf2Dd
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Value
Claim132944862021-09-25 10:39:011013 days ago1632566341IN
0x2b860c49...7a46bf2Dd
0 ETH0.002011125
Claim132587192021-09-19 21:47:401019 days ago1632088060IN
0x2b860c49...7a46bf2Dd
0 ETH0.005187764.53970448
Claim132566332021-09-19 14:23:351019 days ago1632061415IN
0x2b860c49...7a46bf2Dd
0 ETH0.0025426931.62476406
Claim132535022021-09-19 2:31:051020 days ago1632018665IN
0x2b860c49...7a46bf2Dd
0 ETH0.0035623444.32106558
Claim132533562021-09-19 1:59:251020 days ago1632016765IN
0x2b860c49...7a46bf2Dd
0 ETH0.0035008743.52593649
Claim132512462021-09-18 18:14:201020 days ago1631988860IN
0x2b860c49...7a46bf2Dd
0 ETH0.003731446.4278264
Claim132496632021-09-18 12:30:511020 days ago1631968251IN
0x2b860c49...7a46bf2Dd
0 ETH0.0042854453.31614529
Claim132495412021-09-18 12:00:111020 days ago1631966411IN
0x2b860c49...7a46bf2Dd
0 ETH0.0032705940.6587813
Claim132494172021-09-18 11:34:281020 days ago1631964868IN
0x2b860c49...7a46bf2Dd
0 ETH0.0041457751.54385626
Claim132494102021-09-18 11:32:461020 days ago1631964766IN
0x2b860c49...7a46bf2Dd
0 ETH0.0043798355.08601171
Claim132491102021-09-18 10:25:401020 days ago1631960740IN
0x2b860c49...7a46bf2Dd
0 ETH0.0026784933.29642251
Claim132475392021-09-18 4:29:471021 days ago1631939387IN
0x2b860c49...7a46bf2Dd
0 ETH0.0038848148.30661809
Claim132460702021-09-17 22:58:241021 days ago1631919504IN
0x2b860c49...7a46bf2Dd
0 ETH0.0043893254.57186653
Claim132447882021-09-17 18:10:191021 days ago1631902219IN
0x2b860c49...7a46bf2Dd
0 ETH0.00864869107.51468487
Claim132433562021-09-17 13:09:111021 days ago1631884151IN
0x2b860c49...7a46bf2Dd
0 ETH0.0044855955.76739259
Claim132407532021-09-17 3:08:141022 days ago1631848094IN
0x2b860c49...7a46bf2Dd
0 ETH0.0056334270.02915603
Claim132381242021-09-16 17:23:391022 days ago1631813019IN
0x2b860c49...7a46bf2Dd
0 ETH0.0046864858.25776992
Claim132296352021-09-15 9:58:561023 days ago1631699936IN
0x2b860c49...7a46bf2Dd
0 ETH0.0037465346.60907466
Claim132282172021-09-15 4:47:441023 days ago1631681264IN
0x2b860c49...7a46bf2Dd
0 ETH0.0035653644.33424772
Claim132280662021-09-15 4:13:361024 days ago1631679216IN
0x2b860c49...7a46bf2Dd
0 ETH0.0039115548.64996301
Claim132280342021-09-15 4:05:341024 days ago1631678734IN
0x2b860c49...7a46bf2Dd
0 ETH0.0042462852.8
Claim132212912021-09-14 3:00:311025 days ago1631588431IN
0x2b860c49...7a46bf2Dd
0 ETH0.0030295737.68693305
Claim132174362021-09-13 12:45:321025 days ago1631537132IN
0x2b860c49...7a46bf2Dd
0 ETH0.0034240542.57187144
Claim132117402021-09-12 15:21:051026 days ago1631460065IN
0x2b860c49...7a46bf2Dd
0 ETH0.0039315948.89308121
Claim132113762021-09-12 14:01:021026 days ago1631455262IN
0x2b860c49...7a46bf2Dd
0 ETH0.0042301652.61664318
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:
Airdrop

Compiler Version
v0.8.0+commit.c7dfd78e

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 1 : Airdrop.sol
pragma solidity ^0.8.0;

/*

      |>(|)<|
      .-'^'-.
     '/"'"^"\'
    :( *   * ):
    ::)  ,| (::
    '(       )'          _.
     '\ --- /'          / /
   .-'       '-.      .__D
 ,"      |      \    / : (=|
:   Y    |    \  \  /  : (=|
|   |o__/ \__o:   \/  " \ \
|   |          \     '   "-.
|    `.    ___ \:._.'
 ".__  "-" __ \ \
  .|''---''------|               _
  / -.          _""-.--.        C )
 '    '/.___.--'        '._    : |
|     --_   ^"--...__      ''-.' |
|        ''---.o)    ""._        |
 ^'--.._      |o)        '`-..._./
        '--.._|o)
              'O)

*/

/* proof is:

0x63b8398f3ebcf782015a0019a4300bc20e74cf94e6626e4b18f93dd85d150f34

*/
interface IERC20 {
    function mint(address to, uint256 amount) external;
}

library MerkleProof {
    function verify(
        bytes32[] memory proof,
        bytes32 root,
        bytes32 leaf
    ) internal pure returns (bool) {
        bytes32 computedHash = leaf;

        for (uint256 i = 0; i < proof.length; i++) {
            bytes32 proofElement = proof[i];

            if (computedHash <= proofElement) {
                computedHash = keccak256(
                    abi.encodePacked(computedHash, proofElement)
                );
            } else {
                computedHash = keccak256(
                    abi.encodePacked(proofElement, computedHash)
                );
            }
        }
        return computedHash == root;
    }
}

contract Airdrop {
    IERC20 public immutable token;
    bytes32 public immutable merkleRoot;
    mapping(uint256 => uint256) private claimedBitMap;

    constructor(IERC20 token_, bytes32 merkleRoot_) {
        token = token_;
        merkleRoot = merkleRoot_;
    }

    function isClaimed(uint256 index) public view returns (bool) {
        uint256 claimedWordIndex = index / 256;
        uint256 claimedBitIndex = index % 256;
        uint256 claimedWord = claimedBitMap[claimedWordIndex];
        uint256 mask = (1 << claimedBitIndex);
        return claimedWord & mask == mask;
    }

    function _setClaimed(uint256 index) private {
        uint256 claimedWordIndex = index / 256;
        uint256 claimedBitIndex = index % 256;
        claimedBitMap[claimedWordIndex] =
            claimedBitMap[claimedWordIndex] |
            (1 << claimedBitIndex);
    }

    function claim(bytes calldata node, bytes32[] calldata merkleProof)
        external
    {
        uint256 index;
        uint256 amount;
        address recipient;
        (index, recipient, amount) = abi.decode(
            node,
            (uint256, address, uint256)
        );

        require(recipient == msg.sender);
        require(!isClaimed(index), "MerkleDistributor: Drop already claimed.");

        require(
            MerkleProof.verify(merkleProof, merkleRoot, keccak256(node)),
            "MerkleDistributor: Invalid proof."
        );

        _setClaimed(index);
        token.mint(msg.sender, amount * 10 * 1 ether);
    }
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"contract IERC20","name":"token_","type":"address"},{"internalType":"bytes32","name":"merkleRoot_","type":"bytes32"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"bytes","name":"node","type":"bytes"},{"internalType":"bytes32[]","name":"merkleProof","type":"bytes32[]"}],"name":"claim","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"isClaimed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"merkleRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"token","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"}]

60c060405234801561001057600080fd5b5060405161075238038061075283398101604081905261002f9161004a565b60609190911b6001600160601b03191660805260a052610082565b6000806040838503121561005c578182fd5b82516001600160a01b0381168114610072578283fd5b6020939093015192949293505050565b60805160601c60a05161069b6100b76000396000818160bb01526101720152600081816101dd01526102bb015261069b6000f3fe608060405234801561001057600080fd5b506004361061004c5760003560e01c80632eb4a7ab146100515780638923586d1461006f5780639e34070f14610084578063fc0c546a146100a4575b600080fd5b6100596100b9565b6040516100669190610531565b60405180910390f35b61008261007d3660046103d6565b6100dd565b005b610097610092366004610495565b610278565b6040516100669190610526565b6100ac6102b9565b604051610066919061053a565b7f000000000000000000000000000000000000000000000000000000000000000081565b600080806100ed868801886104ad565b91945090925090506001600160a01b038116331461010a57600080fd5b61011383610278565b156101395760405162461bcd60e51b81526004016101309061054e565b60405180910390fd5b6101ae858580806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040517f000000000000000000000000000000000000000000000000000000000000000092506101a191508b908b906104fd565b60405180910390206102dd565b6101ca5760405162461bcd60e51b815260040161013090610596565b6101d383610398565b6001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000166340c10f193361020e85600a6105eb565b61022090670de0b6b3a76400006105eb565b6040518363ffffffff1660e01b815260040161023d92919061050d565b600060405180830381600087803b15801561025757600080fd5b505af115801561026b573d6000803e3d6000fd5b5050505050505050505050565b600080610287610100846105d7565b9050600061029761010085610625565b60009283526020839052604090922054600190921b9182169091149392505050565b7f000000000000000000000000000000000000000000000000000000000000000081565b600081815b855181101561038d57600086828151811061030d57634e487b7160e01b600052603260045260246000fd5b6020026020010151905080831161034e5782816040516020016103319291906104ef565b60405160208183030381529060405280519060200120925061037a565b80836040516020016103619291906104ef565b6040516020818303038152906040528051906020012092505b50806103858161060a565b9150506102e2565b509092149392505050565b60006103a6610100836105d7565b905060006103b661010084610625565b6000928352602083905260409092208054600190931b9092179091555050565b600080600080604085870312156103eb578384fd5b843567ffffffffffffffff80821115610402578586fd5b818701915087601f830112610415578586fd5b813581811115610423578687fd5b60208981838601011115610435578788fd5b80840197508196508089013593508284111561044f578586fd5b838901935089601f850112610462578586fd5b8335915082821115610472578586fd5b89818284028601011115610484578586fd5b969995985091909501955093505050565b6000602082840312156104a6578081fd5b5035919050565b6000806000606084860312156104c1578283fd5b8335925060208401356001600160a01b03811681146104de578283fd5b929592945050506040919091013590565b918252602082015260400190565b6000828483379101908152919050565b6001600160a01b03929092168252602082015260400190565b901515815260200190565b90815260200190565b6001600160a01b0391909116815260200190565b60208082526028908201527f4d65726b6c654469737472696275746f723a2044726f7020616c72656164792060408201526731b630b4b6b2b21760c11b606082015260800190565b60208082526021908201527f4d65726b6c654469737472696275746f723a20496e76616c69642070726f6f666040820152601760f91b606082015260800190565b6000826105e6576105e661064f565b500490565b600081600019048311821515161561060557610605610639565b500290565b600060001982141561061e5761061e610639565b5060010190565b6000826106345761063461064f565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fdfea2646970667358221220e51b93a190662cca23a3f4cc36dca6bb08f92d08d7330014dbb3054a05071c2d64736f6c63430008000033000000000000000000000000c0844fdf1bcbde59a3af0859455d964d350a2cb663b8398f3ebcf782015a0019a4300bc20e74cf94e6626e4b18f93dd85d150f34

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061004c5760003560e01c80632eb4a7ab146100515780638923586d1461006f5780639e34070f14610084578063fc0c546a146100a4575b600080fd5b6100596100b9565b6040516100669190610531565b60405180910390f35b61008261007d3660046103d6565b6100dd565b005b610097610092366004610495565b610278565b6040516100669190610526565b6100ac6102b9565b604051610066919061053a565b7f63b8398f3ebcf782015a0019a4300bc20e74cf94e6626e4b18f93dd85d150f3481565b600080806100ed868801886104ad565b91945090925090506001600160a01b038116331461010a57600080fd5b61011383610278565b156101395760405162461bcd60e51b81526004016101309061054e565b60405180910390fd5b6101ae858580806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040517f63b8398f3ebcf782015a0019a4300bc20e74cf94e6626e4b18f93dd85d150f3492506101a191508b908b906104fd565b60405180910390206102dd565b6101ca5760405162461bcd60e51b815260040161013090610596565b6101d383610398565b6001600160a01b037f000000000000000000000000c0844fdf1bcbde59a3af0859455d964d350a2cb6166340c10f193361020e85600a6105eb565b61022090670de0b6b3a76400006105eb565b6040518363ffffffff1660e01b815260040161023d92919061050d565b600060405180830381600087803b15801561025757600080fd5b505af115801561026b573d6000803e3d6000fd5b5050505050505050505050565b600080610287610100846105d7565b9050600061029761010085610625565b60009283526020839052604090922054600190921b9182169091149392505050565b7f000000000000000000000000c0844fdf1bcbde59a3af0859455d964d350a2cb681565b600081815b855181101561038d57600086828151811061030d57634e487b7160e01b600052603260045260246000fd5b6020026020010151905080831161034e5782816040516020016103319291906104ef565b60405160208183030381529060405280519060200120925061037a565b80836040516020016103619291906104ef565b6040516020818303038152906040528051906020012092505b50806103858161060a565b9150506102e2565b509092149392505050565b60006103a6610100836105d7565b905060006103b661010084610625565b6000928352602083905260409092208054600190931b9092179091555050565b600080600080604085870312156103eb578384fd5b843567ffffffffffffffff80821115610402578586fd5b818701915087601f830112610415578586fd5b813581811115610423578687fd5b60208981838601011115610435578788fd5b80840197508196508089013593508284111561044f578586fd5b838901935089601f850112610462578586fd5b8335915082821115610472578586fd5b89818284028601011115610484578586fd5b969995985091909501955093505050565b6000602082840312156104a6578081fd5b5035919050565b6000806000606084860312156104c1578283fd5b8335925060208401356001600160a01b03811681146104de578283fd5b929592945050506040919091013590565b918252602082015260400190565b6000828483379101908152919050565b6001600160a01b03929092168252602082015260400190565b901515815260200190565b90815260200190565b6001600160a01b0391909116815260200190565b60208082526028908201527f4d65726b6c654469737472696275746f723a2044726f7020616c72656164792060408201526731b630b4b6b2b21760c11b606082015260800190565b60208082526021908201527f4d65726b6c654469737472696275746f723a20496e76616c69642070726f6f666040820152601760f91b606082015260800190565b6000826105e6576105e661064f565b500490565b600081600019048311821515161561060557610605610639565b500290565b600060001982141561061e5761061e610639565b5060010190565b6000826106345761063461064f565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fdfea2646970667358221220e51b93a190662cca23a3f4cc36dca6bb08f92d08d7330014dbb3054a05071c2d64736f6c63430008000033

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

000000000000000000000000c0844fdf1bcbde59a3af0859455d964d350a2cb663b8398f3ebcf782015a0019a4300bc20e74cf94e6626e4b18f93dd85d150f34

-----Decoded View---------------
Arg [0] : token_ (address): 0xC0844FDF1bcbDE59a3AF0859455D964D350A2cb6
Arg [1] : merkleRoot_ (bytes32): 0x63b8398f3ebcf782015a0019a4300bc20e74cf94e6626e4b18f93dd85d150f34

-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 000000000000000000000000c0844fdf1bcbde59a3af0859455d964d350a2cb6
Arg [1] : 63b8398f3ebcf782015a0019a4300bc20e74cf94e6626e4b18f93dd85d150f34


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.