ETH Price: $2,634.27 (-1.37%)
Gas: 1 Gwei

Contract

0xa40aedAac28F9574124D7c8EFf59732cC77f1DD4
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Token Holdings

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Claim176566252023-07-09 14:04:35397 days ago1688911475IN
Notional Finance: Airdrop
0 ETH0.0013835616.96921475
Claim169233702023-03-28 4:08:23501 days ago1679976503IN
Notional Finance: Airdrop
0 ETH0.0014088721.86464995
Claim169051022023-03-25 14:34:23503 days ago1679754863IN
Notional Finance: Airdrop
0 ETH0.0015154818.77508022
Claim161473932022-12-09 13:19:11609 days ago1670591951IN
Notional Finance: Airdrop
0 ETH0.0017970822.03767631
Claim157164792022-10-10 8:22:11669 days ago1665390131IN
Notional Finance: Airdrop
0 ETH0.0025814431.67416226
Claim155350052022-09-14 20:56:56695 days ago1663189016IN
Notional Finance: Airdrop
0 ETH0.0028047534.39387271
Claim155345362022-09-14 18:52:45695 days ago1663181565IN
Notional Finance: Airdrop
0 ETH0.0014508917.78585886
Claim153468222022-08-15 15:34:53725 days ago1660577693IN
Notional Finance: Airdrop
0 ETH0.0011522914.13270179
Claim151169812022-07-10 20:19:32761 days ago1657484372IN
Notional Finance: Airdrop
0 ETH0.0025062530.74561135
Claim151089682022-07-09 14:35:59762 days ago1657377359IN
Notional Finance: Airdrop
0 ETH0.0018224922.59086553
Claim149073592022-06-05 5:39:11797 days ago1654407551IN
Notional Finance: Airdrop
0 ETH0.0023527328.86789949
Claim147230292022-05-06 10:34:16826 days ago1651833256IN
Notional Finance: Airdrop
0 ETH0.0014039147.65984937
Claim144192932022-03-19 21:24:41874 days ago1647725081IN
Notional Finance: Airdrop
0 ETH0.0021944826.90044928
Claim142897432022-02-27 18:10:26894 days ago1645985426IN
Notional Finance: Airdrop
0 ETH0.004941261.19291906
Claim142546852022-02-22 8:07:11899 days ago1645517231IN
Notional Finance: Airdrop
0 ETH0.0052717364.61404865
Claim142411972022-02-20 5:53:23902 days ago1645336403IN
Notional Finance: Airdrop
0 ETH0.0011466838.94338753
Claim142411972022-02-20 5:53:23902 days ago1645336403IN
Notional Finance: Airdrop
0 ETH0.0031429638.94338753
Claim142390142022-02-19 21:55:21902 days ago1645307721IN
Notional Finance: Airdrop
0 ETH0.0045535455.85804816
Claim141642752022-02-08 8:05:23913 days ago1644307523IN
Notional Finance: Airdrop
0 ETH0.0058926873.05036903
Claim141493222022-02-06 0:55:41916 days ago1644108941IN
Notional Finance: Airdrop
0 ETH0.0039028547.87955765
Claim141490272022-02-05 23:48:51916 days ago1644104931IN
Notional Finance: Airdrop
0 ETH0.0041518450.93414168
Claim141252562022-02-02 7:23:15920 days ago1643786595IN
Notional Finance: Airdrop
0 ETH0.008075699.10910661
Claim140583322022-01-22 23:16:13930 days ago1642893373IN
Notional Finance: Airdrop
0 ETH0.01044336128.04835743
Claim140338442022-01-19 4:27:11934 days ago1642566431IN
Notional Finance: Airdrop
0 ETH0.00923156114.345477
Claim140128272022-01-15 22:35:51937 days ago1642286151IN
Notional Finance: Airdrop
0 ETH0.01174549144.0175956
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:
MerkleDistributor

Compiler Version
v0.6.11+commit.5ef660b1

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 4 : MerkleDistributor.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity =0.6.11;

import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import "@openzeppelin/contracts/cryptography/MerkleProof.sol";
import "./interfaces/IMerkleDistributor.sol";

contract MerkleDistributor is IMerkleDistributor {
    uint256 public immutable override minClaimTime;
    address public immutable override token;
    bytes32 public immutable override merkleRoot;

    // This is a packed array of booleans.
    mapping(uint256 => uint256) private claimedBitMap;

    constructor(address token_, bytes32 merkleRoot_, uint256 minClaimTime_) public {
        token = token_;
        merkleRoot = merkleRoot_;
        minClaimTime = minClaimTime_;
    }

    function isClaimed(uint256 index) public view override 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(uint256 index, address account, uint256 amount, bytes32[] calldata merkleProof) external override {
        require(block.timestamp >= minClaimTime, "MerkleDistributor: prior to minimum claim time.");
        require(!isClaimed(index), 'MerkleDistributor: Drop already claimed.');

        // Verify the merkle proof.
        bytes32 node = keccak256(abi.encodePacked(index, account, amount));
        require(MerkleProof.verify(merkleProof, merkleRoot, node), 'MerkleDistributor: Invalid proof.');

        // Mark it claimed and send the token.
        _setClaimed(index);
        require(IERC20(token).transfer(account, amount), 'MerkleDistributor: Transfer failed.');

        emit Claimed(index, account, amount);
    }
}

File 2 of 4 : IERC20.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.6.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns the amount of tokens owned by `account`.
     */
    function balanceOf(address account) external view returns (uint256);

    /**
     * @dev Moves `amount` tokens from the caller's account to `recipient`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address recipient, uint256 amount) external returns (bool);

    /**
     * @dev Returns the remaining number of tokens that `spender` will be
     * allowed to spend on behalf of `owner` through {transferFrom}. This is
     * zero by default.
     *
     * This value changes when {approve} or {transferFrom} are called.
     */
    function allowance(address owner, address spender) external view returns (uint256);

    /**
     * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * IMPORTANT: Beware that changing an allowance with this method brings the risk
     * that someone may use both the old and the new allowance by unfortunate
     * transaction ordering. One possible solution to mitigate this race
     * condition is to first reduce the spender's allowance to 0 and set the
     * desired value afterwards:
     * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
     *
     * Emits an {Approval} event.
     */
    function approve(address spender, uint256 amount) external returns (bool);

    /**
     * @dev Moves `amount` tokens from `sender` to `recipient` using the
     * allowance mechanism. `amount` is then deducted from the caller's
     * allowance.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(address sender, address recipient, uint256 amount) external returns (bool);

    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

    /**
     * @dev Emitted when the allowance of a `spender` for an `owner` is set by
     * a call to {approve}. `value` is the new allowance.
     */
    event Approval(address indexed owner, address indexed spender, uint256 value);
}

File 3 of 4 : MerkleProof.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.6.0;

/**
 * @dev These functions deal with verification of Merkle trees (hash trees),
 */
library MerkleProof {
    /**
     * @dev Returns true if a `leaf` can be proved to be a part of a Merkle tree
     * defined by `root`. For this, a `proof` must be provided, containing
     * sibling hashes on the branch from the leaf to the root of the tree. Each
     * pair of leaves and each pair of pre-images are assumed to be sorted.
     */
    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) {
                // Hash(current computed hash + current element of the proof)
                computedHash = keccak256(abi.encodePacked(computedHash, proofElement));
            } else {
                // Hash(current element of the proof + current computed hash)
                computedHash = keccak256(abi.encodePacked(proofElement, computedHash));
            }
        }

        // Check if the computed hash (root) is equal to the provided root
        return computedHash == root;
    }
}

File 4 of 4 : IMerkleDistributor.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity >=0.5.0;

// Allows anyone to claim a token if they exist in a merkle root.
interface IMerkleDistributor {
    // Returns the address of the token distributed by this contract.
    function token() external view returns (address);
    // Returns the merkle root of the merkle tree containing account balances available to claim.
    function merkleRoot() external view returns (bytes32);
    // Returns the minimum claim time for the token
    function minClaimTime() external view returns (uint256);
    // Returns true if the index has been marked claimed.
    function isClaimed(uint256 index) external view returns (bool);
    // Claim the given amount of the token to the given address. Reverts if the inputs are invalid.
    function claim(uint256 index, address account, uint256 amount, bytes32[] calldata merkleProof) external;

    // This event is triggered whenever a call to #claim succeeds.
    event Claimed(uint256 index, address account, uint256 amount);
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"token_","type":"address"},{"internalType":"bytes32","name":"merkleRoot_","type":"bytes32"},{"internalType":"uint256","name":"minClaimTime_","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"index","type":"uint256"},{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Claimed","type":"event"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"},{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"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":"minClaimTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"token","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}]

60e060405234801561001057600080fd5b506040516106f23803806106f28339818101604052606081101561003357600080fd5b5080516020820151604090920151606082901b6001600160601b03191660a05260c08390526080819052916001600160a01b039091169061065661009c6000398061027d52806104255250806102ee5280610493525080610163528061046f52506106566000f3fe608060405234801561001057600080fd5b50600436106100575760003560e01c80632e7ba6ef1461005c5780632eb4a7ab146100ea5780639e34070f14610104578063f1dc6f9314610135578063fc0c546a1461013d575b600080fd5b6100e86004803603608081101561007257600080fd5b8135916001600160a01b0360208201351691604082013591908101906080810160608201356401000000008111156100a957600080fd5b8201836020820111156100bb57600080fd5b803590602001918460208302840111640100000000831117156100dd57600080fd5b509092509050610161565b005b6100f2610423565b60408051918252519081900360200190f35b6101216004803603602081101561011a57600080fd5b5035610447565b604080519115158252519081900360200190f35b6100f261046d565b610145610491565b604080516001600160a01b039092168252519081900360200190f35b7f00000000000000000000000000000000000000000000000000000000000000004210156101c05760405162461bcd60e51b815260040180806020018281038252602f8152602001806105ae602f913960400191505060405180910390fd5b6101c985610447565b156102055760405162461bcd60e51b81526004018080602001828103825260288152602001806105866028913960400191505060405180910390fd5b6040805160208082018890526bffffffffffffffffffffffff19606088901b16828401526054808301879052835180840390910181526074830180855281519183019190912060949286028085018401909552858252936102a8939192879287928392909101908490808284376000920191909152507f000000000000000000000000000000000000000000000000000000000000000092508591506104b59050565b6102e35760405162461bcd60e51b81526004018080602001828103825260218152602001806105dd6021913960400191505060405180910390fd5b6102ec8661055e565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663a9059cbb86866040518363ffffffff1660e01b815260040180836001600160a01b03166001600160a01b0316815260200182815260200192505050602060405180830381600087803b15801561036c57600080fd5b505af1158015610380573d6000803e3d6000fd5b505050506040513d602081101561039657600080fd5b50516103d35760405162461bcd60e51b81526004018080602001828103825260238152602001806105fe6023913960400191505060405180910390fd5b604080518781526001600160a01b038716602082015280820186905290517f4ec90e965519d92681267467f775ada5bd214aa92c0dc93d90a5e880ce9ed0269181900360600190a1505050505050565b7f000000000000000000000000000000000000000000000000000000000000000081565b6101008104600090815260208190526040902054600160ff9092169190911b9081161490565b7f000000000000000000000000000000000000000000000000000000000000000081565b7f000000000000000000000000000000000000000000000000000000000000000081565b600081815b85518110156105535760008682815181106104d157fe5b60200260200101519050808311610518578281604051602001808381526020018281526020019250505060405160208183030381529060405280519060200120925061054a565b808360405160200180838152602001828152602001925050506040516020818303038152906040528051906020012092505b506001016104ba565b509092149392505050565b610100810460009081526020819052604090208054600160ff9093169290921b909117905556fe4d65726b6c654469737472696275746f723a2044726f7020616c726561647920636c61696d65642e4d65726b6c654469737472696275746f723a207072696f7220746f206d696e696d756d20636c61696d2074696d652e4d65726b6c654469737472696275746f723a20496e76616c69642070726f6f662e4d65726b6c654469737472696275746f723a205472616e73666572206661696c65642ea2646970667358221220b4b665522d5ee9c81f51fa7188e095c710969e2784cea31e221f517f44f8791c64736f6c634300060b0033000000000000000000000000cfeaead4947f0705a14ec42ac3d44129e1ef3ed534e18af42a82ff6dbcad3853157ba252b4d14ad9bbfe8e1913133da13eb1af4800000000000000000000000000000000000000000000000000000000615a4400

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106100575760003560e01c80632e7ba6ef1461005c5780632eb4a7ab146100ea5780639e34070f14610104578063f1dc6f9314610135578063fc0c546a1461013d575b600080fd5b6100e86004803603608081101561007257600080fd5b8135916001600160a01b0360208201351691604082013591908101906080810160608201356401000000008111156100a957600080fd5b8201836020820111156100bb57600080fd5b803590602001918460208302840111640100000000831117156100dd57600080fd5b509092509050610161565b005b6100f2610423565b60408051918252519081900360200190f35b6101216004803603602081101561011a57600080fd5b5035610447565b604080519115158252519081900360200190f35b6100f261046d565b610145610491565b604080516001600160a01b039092168252519081900360200190f35b7f00000000000000000000000000000000000000000000000000000000615a44004210156101c05760405162461bcd60e51b815260040180806020018281038252602f8152602001806105ae602f913960400191505060405180910390fd5b6101c985610447565b156102055760405162461bcd60e51b81526004018080602001828103825260288152602001806105866028913960400191505060405180910390fd5b6040805160208082018890526bffffffffffffffffffffffff19606088901b16828401526054808301879052835180840390910181526074830180855281519183019190912060949286028085018401909552858252936102a8939192879287928392909101908490808284376000920191909152507f34e18af42a82ff6dbcad3853157ba252b4d14ad9bbfe8e1913133da13eb1af4892508591506104b59050565b6102e35760405162461bcd60e51b81526004018080602001828103825260218152602001806105dd6021913960400191505060405180910390fd5b6102ec8661055e565b7f000000000000000000000000cfeaead4947f0705a14ec42ac3d44129e1ef3ed56001600160a01b031663a9059cbb86866040518363ffffffff1660e01b815260040180836001600160a01b03166001600160a01b0316815260200182815260200192505050602060405180830381600087803b15801561036c57600080fd5b505af1158015610380573d6000803e3d6000fd5b505050506040513d602081101561039657600080fd5b50516103d35760405162461bcd60e51b81526004018080602001828103825260238152602001806105fe6023913960400191505060405180910390fd5b604080518781526001600160a01b038716602082015280820186905290517f4ec90e965519d92681267467f775ada5bd214aa92c0dc93d90a5e880ce9ed0269181900360600190a1505050505050565b7f34e18af42a82ff6dbcad3853157ba252b4d14ad9bbfe8e1913133da13eb1af4881565b6101008104600090815260208190526040902054600160ff9092169190911b9081161490565b7f00000000000000000000000000000000000000000000000000000000615a440081565b7f000000000000000000000000cfeaead4947f0705a14ec42ac3d44129e1ef3ed581565b600081815b85518110156105535760008682815181106104d157fe5b60200260200101519050808311610518578281604051602001808381526020018281526020019250505060405160208183030381529060405280519060200120925061054a565b808360405160200180838152602001828152602001925050506040516020818303038152906040528051906020012092505b506001016104ba565b509092149392505050565b610100810460009081526020819052604090208054600160ff9093169290921b909117905556fe4d65726b6c654469737472696275746f723a2044726f7020616c726561647920636c61696d65642e4d65726b6c654469737472696275746f723a207072696f7220746f206d696e696d756d20636c61696d2074696d652e4d65726b6c654469737472696275746f723a20496e76616c69642070726f6f662e4d65726b6c654469737472696275746f723a205472616e73666572206661696c65642ea2646970667358221220b4b665522d5ee9c81f51fa7188e095c710969e2784cea31e221f517f44f8791c64736f6c634300060b0033

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

000000000000000000000000cfeaead4947f0705a14ec42ac3d44129e1ef3ed534e18af42a82ff6dbcad3853157ba252b4d14ad9bbfe8e1913133da13eb1af4800000000000000000000000000000000000000000000000000000000615a4400

-----Decoded View---------------
Arg [0] : token_ (address): 0xCFEAead4947f0705A14ec42aC3D44129E1Ef3eD5
Arg [1] : merkleRoot_ (bytes32): 0x34e18af42a82ff6dbcad3853157ba252b4d14ad9bbfe8e1913133da13eb1af48
Arg [2] : minClaimTime_ (uint256): 1633305600

-----Encoded View---------------
3 Constructor Arguments found :
Arg [0] : 000000000000000000000000cfeaead4947f0705a14ec42ac3d44129e1ef3ed5
Arg [1] : 34e18af42a82ff6dbcad3853157ba252b4d14ad9bbfe8e1913133da13eb1af48
Arg [2] : 00000000000000000000000000000000000000000000000000000000615a4400


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.