ETH Price: $3,932.89 (-1.29%)
Gas: 0.08 Gwei

Contract

0x5fb1941b5415b4817d9CC62f8039F7A4B366Ff8F
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

More Info

Private Name Tags

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Claim171257622023-04-25 20:51:23913 days ago1682455883IN
0x5fb1941b...4B366Ff8F
0 ETH0.0063282240.43902802
Change Merkle Ro...170970552023-04-21 20:14:23917 days ago1682108063IN
0x5fb1941b...4B366Ff8F
0 ETH0.0015953355
Change Merkle Ro...170741942023-04-18 14:37:11920 days ago1681828631IN
0x5fb1941b...4B366Ff8F
0 ETH0.001450350
Change Merkle Ro...170688232023-04-17 20:21:59921 days ago1681762919IN
0x5fb1941b...4B366Ff8F
0 ETH0.0010732237
Claim170355942023-04-13 1:19:11926 days ago1681348751IN
0x5fb1941b...4B366Ff8F
0 ETH0.0050528131.97662857
Change Merkle Ro...170185362023-04-10 14:59:47928 days ago1681138787IN
0x5fb1941b...4B366Ff8F
0 ETH0.0011602440
Claim169419032023-03-30 18:40:59939 days ago1680201659IN
0x5fb1941b...4B366Ff8F
0 ETH0.0040648429.68123276
Claim169359382023-03-29 22:34:47940 days ago1680129287IN
0x5fb1941b...4B366Ff8F
0 ETH0.003842424.55082814
Change Merkle Ro...169332112023-03-29 13:21:23940 days ago1680096083IN
0x5fb1941b...4B366Ff8F
0 ETH0.0009382532.34696993
Claim167863962023-03-08 22:07:11961 days ago1678313231IN
0x5fb1941b...4B366Ff8F
0 ETH0.0060398538.01857905
Claim166502092023-02-17 18:30:11980 days ago1676658611IN
0x5fb1941b...4B366Ff8F
0 ETH0.0069958851.05737329
Claim166435352023-02-16 19:59:23981 days ago1676577563IN
0x5fb1941b...4B366Ff8F
0 ETH0.0069280444.27542444
Claim166374962023-02-15 23:44:23982 days ago1676504663IN
0x5fb1941b...4B366Ff8F
0 ETH0.0056190235.37181627
Claim166319622023-02-15 5:09:11983 days ago1676437751IN
0x5fb1941b...4B366Ff8F
0 ETH0.0032458824
Change Merkle Ro...166287932023-02-14 18:31:47983 days ago1676399507IN
0x5fb1941b...4B366Ff8F
0 ETH0.0007541526
Claim166210292023-02-13 16:28:23984 days ago1676305703IN
0x5fb1941b...4B366Ff8F
0 ETH0.0043351127.70078789
Change Merkle Ro...166209512023-02-13 16:12:35984 days ago1676304755IN
0x5fb1941b...4B366Ff8F
0 ETH0.0011013138
Claim166165382023-02-13 1:25:23985 days ago1676251523IN
0x5fb1941b...4B366Ff8F
0 ETH0.0026437216.64416448
Claim166091092023-02-12 0:30:23986 days ago1676161823IN
0x5fb1941b...4B366Ff8F
0 ETH0.0020852115.22257593
Change Merkle Ro...165875472023-02-09 0:14:11989 days ago1675901651IN
0x5fb1941b...4B366Ff8F
0 ETH0.0007831627
Change Merkle Ro...165861562023-02-08 19:34:23989 days ago1675884863IN
0x5fb1941b...4B366Ff8F
0 ETH0.0011602440
Change Merkle Ro...165861452023-02-08 19:32:11989 days ago1675884731IN
0x5fb1941b...4B366Ff8F
0 ETH0.0011602440
Change Merkle Ro...165417702023-02-02 14:40:23995 days ago1675348823IN
0x5fb1941b...4B366Ff8F
0 ETH0.0008701830
Claim162485812022-12-23 16:21:111036 days ago1671812471IN
0x5fb1941b...4B366Ff8F
0 ETH0.002789717.92800457
Change Merkle Ro...162414192022-12-22 16:24:351037 days ago1671726275IN
0x5fb1941b...4B366Ff8F
0 ETH0.0004270414.72874715
View all transactions

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Cross-Chain Transactions

Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
GenesisKeyTeamDistributor

Compiler Version
v0.8.6+commit.11564f7e

Optimization Enabled:
Yes with 0 runs

Other Settings:
default evmVersion
//SPDX-License-Identifier: Unlicense
pragma solidity ^0.8.0;

import "../interface/IGenesisKeyTeamDistributor.sol";
import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol";

// From: https://github.com/Uniswap/merkle-distributor/blob/master/contracts/MerkleDistributor.sol

interface IGkTeam {
    function teamClaim(address recipient) external returns (bool);
}

contract GenesisKeyTeamDistributor is IGenesisKeyTeamDistributor {
    address public immutable override gkTeam;
    bytes32 public override merkleRoot;
    address public override owner;

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

    constructor(address gkTeam_) {
        gkTeam = gkTeam_;
        owner = msg.sender;
    }

    function transferOwnership(address _newOwner) external {
        require(msg.sender == owner, "!auth");
        owner = _newOwner;
    }

    function changeMerkleRoot(bytes32 _newRoot) external {
        require(msg.sender == owner, "!auth");
        merkleRoot = _newRoot;
    }

    function claim(
        uint256 index,
        address account,
        uint256 tokenId,
        bytes32[] calldata merkleProof
    ) external payable override {
        require(msg.sender == account);
        require(!addressClaimed[account], "GKTeamDistributor: Drop already claimed.");

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

        // Mark it claimed and send the token.
        addressClaimed[account] = true;
        require(IGkTeam(gkTeam).teamClaim(account), "GKTeamDistributor: No team keys available");

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

//SPDX-License-Identifier: Unlicense
pragma solidity ^0.8.0;

// Allows anyone to claim a token if they exist in a merkle root.
interface IGenesisKeyTeamDistributor {
    // Returns the address of the gkTeam contract.
    function gkTeam() external view returns (address);

    // Returns the merkle root of the merkle tree containing account balances available to claim.
    function merkleRoot() external view returns (bytes32);

    function owner() external view returns (address);

    // Claim the given amount of the token to the given address. Reverts if the inputs are invalid.
    function claim(
        uint256 index,
        address account,
        uint256 tokenId,
        bytes32[] calldata merkleProof
    ) external payable;

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

// SPDX-License-Identifier: MIT

pragma solidity ^0.8.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 4 of 4 : MerkleProof.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev These functions deal with verification of Merkle Trees proofs.
 *
 * The proofs can be generated using the JavaScript library
 * https://github.com/miguelmota/merkletreejs[merkletreejs].
 * Note: the hashing algorithm should be keccak256 and pair sorting should be enabled.
 *
 * See `test/utils/cryptography/MerkleProof.test.js` for some examples.
 */
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;
    }
}

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

Contract Security Audit

Contract ABI

API
[{"inputs":[{"internalType":"address","name":"gkTeam_","type":"address"}],"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":"tokenId","type":"uint256"}],"name":"Claimed","type":"event"},{"inputs":[{"internalType":"bytes32","name":"_newRoot","type":"bytes32"}],"name":"changeMerkleRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"},{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32[]","name":"merkleProof","type":"bytes32[]"}],"name":"claim","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"gkTeam","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"merkleRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60a060405234801561001057600080fd5b5060405161077738038061077783398101604081905261002f91610058565b60601b6001600160601b03191660805260018054336001600160a01b0319909116179055610088565b60006020828403121561006a57600080fd5b81516001600160a01b038116811461008157600080fd5b9392505050565b60805160601c6106cb6100ac6000396000818160d701526102db01526106cb6000f3fe6080604052600436106100555760003560e01c80632e7ba6ef1461005a5780632eb4a7ab1461006f5780638da5cb5b14610098578063bc53d64e146100c5578063ebcea3db146100f9578063f2fde38b14610119575b600080fd5b61006d6100683660046105b6565b610139565b005b34801561007b57600080fd5b5061008560005481565b6040519081526020015b60405180910390f35b3480156100a457600080fd5b506001546100b8906001600160a01b031681565b60405161008f919061064c565b3480156100d157600080fd5b506100b87f000000000000000000000000000000000000000000000000000000000000000081565b34801561010557600080fd5b5061006d61011436600461059d565b610413565b34801561012557600080fd5b5061006d610134366004610559565b610442565b336001600160a01b0385161461014e57600080fd5b6001600160a01b03841660009081526003602052604090205460ff16156101cd5760405162461bcd60e51b815260206004820152602860248201527f474b5465616d4469737472696275746f723a2044726f7020616c72656164792060448201526731b630b4b6b2b21760c11b60648201526084015b60405180910390fd5b60408051602081018790526001600160601b0319606087901b169181019190915260548101849052600090607401604051602081830303815290604052805190602001209050610252838380806020026020016040519081016040528093929190818152602001838360200280828437600092018290525054925085915061048e9050565b6102a85760405162461bcd60e51b815260206004820152602160248201527f474b5465616d4469737472696275746f723a20496e76616c69642070726f6f666044820152601760f91b60648201526084016101c4565b6001600160a01b0380861660009081526003602052604090819020805460ff191660011790555163e7db0be960e01b81527f00000000000000000000000000000000000000000000000000000000000000009091169063e7db0be99061031290889060040161064c565b602060405180830381600087803b15801561032c57600080fd5b505af1158015610340573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610364919061057b565b6103c25760405162461bcd60e51b815260206004820152602960248201527f474b5465616d4469737472696275746f723a204e6f207465616d206b65797320604482015268617661696c61626c6560b81b60648201526084016101c4565b604080518781526001600160a01b03871660208201529081018590527f4ec90e965519d92681267467f775ada5bd214aa92c0dc93d90a5e880ce9ed0269060600160405180910390a1505050505050565b6001546001600160a01b0316331461043d5760405162461bcd60e51b81526004016101c490610660565b600055565b6001546001600160a01b0316331461046c5760405162461bcd60e51b81526004016101c490610660565b600180546001600160a01b0319166001600160a01b0392909216919091179055565b600081815b85518110156105325760008682815181106104b0576104b06106a8565b602002602001015190508083116104f257604080516020810185905290810182905260600160405160208183030381529060405280519060200120925061051f565b60408051602081018390529081018490526060016040516020818303038152906040528051906020012092505b508061052a8161067f565b915050610493565b509092149392505050565b80356001600160a01b038116811461055457600080fd5b919050565b60006020828403121561056b57600080fd5b6105748261053d565b9392505050565b60006020828403121561058d57600080fd5b8151801515811461057457600080fd5b6000602082840312156105af57600080fd5b5035919050565b6000806000806000608086880312156105ce57600080fd5b853594506105de6020870161053d565b93506040860135925060608601356001600160401b038082111561060157600080fd5b818801915088601f83011261061557600080fd5b81358181111561062457600080fd5b8960208260051b850101111561063957600080fd5b9699959850939650602001949392505050565b6001600160a01b0391909116815260200190565b602080825260059082015264042c2eae8d60db1b604082015260600190565b60006000198214156106a157634e487b7160e01b600052601160045260246000fd5b5060010190565b634e487b7160e01b600052603260045260246000fdfea164736f6c6343000806000a000000000000000000000000fc99e6b4447a17ea0c6162854fcb572ddc8fbb37

Deployed Bytecode

0x6080604052600436106100555760003560e01c80632e7ba6ef1461005a5780632eb4a7ab1461006f5780638da5cb5b14610098578063bc53d64e146100c5578063ebcea3db146100f9578063f2fde38b14610119575b600080fd5b61006d6100683660046105b6565b610139565b005b34801561007b57600080fd5b5061008560005481565b6040519081526020015b60405180910390f35b3480156100a457600080fd5b506001546100b8906001600160a01b031681565b60405161008f919061064c565b3480156100d157600080fd5b506100b87f000000000000000000000000fc99e6b4447a17ea0c6162854fcb572ddc8fbb3781565b34801561010557600080fd5b5061006d61011436600461059d565b610413565b34801561012557600080fd5b5061006d610134366004610559565b610442565b336001600160a01b0385161461014e57600080fd5b6001600160a01b03841660009081526003602052604090205460ff16156101cd5760405162461bcd60e51b815260206004820152602860248201527f474b5465616d4469737472696275746f723a2044726f7020616c72656164792060448201526731b630b4b6b2b21760c11b60648201526084015b60405180910390fd5b60408051602081018790526001600160601b0319606087901b169181019190915260548101849052600090607401604051602081830303815290604052805190602001209050610252838380806020026020016040519081016040528093929190818152602001838360200280828437600092018290525054925085915061048e9050565b6102a85760405162461bcd60e51b815260206004820152602160248201527f474b5465616d4469737472696275746f723a20496e76616c69642070726f6f666044820152601760f91b60648201526084016101c4565b6001600160a01b0380861660009081526003602052604090819020805460ff191660011790555163e7db0be960e01b81527f000000000000000000000000fc99e6b4447a17ea0c6162854fcb572ddc8fbb379091169063e7db0be99061031290889060040161064c565b602060405180830381600087803b15801561032c57600080fd5b505af1158015610340573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610364919061057b565b6103c25760405162461bcd60e51b815260206004820152602960248201527f474b5465616d4469737472696275746f723a204e6f207465616d206b65797320604482015268617661696c61626c6560b81b60648201526084016101c4565b604080518781526001600160a01b03871660208201529081018590527f4ec90e965519d92681267467f775ada5bd214aa92c0dc93d90a5e880ce9ed0269060600160405180910390a1505050505050565b6001546001600160a01b0316331461043d5760405162461bcd60e51b81526004016101c490610660565b600055565b6001546001600160a01b0316331461046c5760405162461bcd60e51b81526004016101c490610660565b600180546001600160a01b0319166001600160a01b0392909216919091179055565b600081815b85518110156105325760008682815181106104b0576104b06106a8565b602002602001015190508083116104f257604080516020810185905290810182905260600160405160208183030381529060405280519060200120925061051f565b60408051602081018390529081018490526060016040516020818303038152906040528051906020012092505b508061052a8161067f565b915050610493565b509092149392505050565b80356001600160a01b038116811461055457600080fd5b919050565b60006020828403121561056b57600080fd5b6105748261053d565b9392505050565b60006020828403121561058d57600080fd5b8151801515811461057457600080fd5b6000602082840312156105af57600080fd5b5035919050565b6000806000806000608086880312156105ce57600080fd5b853594506105de6020870161053d565b93506040860135925060608601356001600160401b038082111561060157600080fd5b818801915088601f83011261061557600080fd5b81358181111561062457600080fd5b8960208260051b850101111561063957600080fd5b9699959850939650602001949392505050565b6001600160a01b0391909116815260200190565b602080825260059082015264042c2eae8d60db1b604082015260600190565b60006000198214156106a157634e487b7160e01b600052601160045260246000fd5b5060010190565b634e487b7160e01b600052603260045260246000fdfea164736f6c6343000806000a

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

000000000000000000000000fc99e6b4447a17ea0c6162854fcb572ddc8fbb37

-----Decoded View---------------
Arg [0] : gkTeam_ (address): 0xfc99E6b4447a17EA0C6162854fcb572ddC8FbB37

-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 000000000000000000000000fc99e6b4447a17ea0c6162854fcb572ddc8fbb37


Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading
Loading...
Loading
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.