Source Code
Overview
ETH Balance
0 ETH
Eth Value
$0.00Latest 25 from a total of 2,398 transactions
| Transaction Hash |
Method
|
Block
|
From
|
|
To
|
||||
|---|---|---|---|---|---|---|---|---|---|
| Claim | 14701154 | 1393 days ago | IN | 0.5 ETH | 0.00499083 | ||||
| Claim | 14698999 | 1393 days ago | IN | 0.5 ETH | 0.0086225 | ||||
| Claim | 14698995 | 1393 days ago | IN | 0.5 ETH | 0.01318374 | ||||
| Claim | 14696412 | 1394 days ago | IN | 0.5 ETH | 0.00832029 | ||||
| Claim | 14695855 | 1394 days ago | IN | 0.5 ETH | 0.00897913 | ||||
| Claim | 14694761 | 1394 days ago | IN | 0.5 ETH | 0.00586648 | ||||
| Claim | 14694754 | 1394 days ago | IN | 0.5 ETH | 0.00586905 | ||||
| Claim | 14694739 | 1394 days ago | IN | 0.5 ETH | 0.00579648 | ||||
| Claim | 14694735 | 1394 days ago | IN | 0.5 ETH | 0.00894855 | ||||
| Claim | 14694734 | 1394 days ago | IN | 0.5 ETH | 0.00627942 | ||||
| Claim | 14694732 | 1394 days ago | IN | 0.5 ETH | 0.00706459 | ||||
| Claim | 14694728 | 1394 days ago | IN | 0.5 ETH | 0.00618665 | ||||
| Claim | 14694713 | 1394 days ago | IN | 0.5 ETH | 0.00607074 | ||||
| Claim | 14694703 | 1394 days ago | IN | 0.5 ETH | 0.00678605 | ||||
| Claim | 14694696 | 1394 days ago | IN | 0.5 ETH | 0.00704391 | ||||
| Claim | 14694696 | 1394 days ago | IN | 0.5 ETH | 0.00707131 | ||||
| Claim | 14694690 | 1394 days ago | IN | 0.5 ETH | 0.00708088 | ||||
| Claim | 14694676 | 1394 days ago | IN | 0.5 ETH | 0.00819416 | ||||
| Claim | 14694675 | 1394 days ago | IN | 0.5 ETH | 0.00731364 | ||||
| Claim | 14694675 | 1394 days ago | IN | 0.5 ETH | 0.00726546 | ||||
| Claim | 14694668 | 1394 days ago | IN | 0.5 ETH | 0.00889116 | ||||
| Claim | 14694668 | 1394 days ago | IN | 0.5 ETH | 0.01402271 | ||||
| Claim | 14694666 | 1394 days ago | IN | 0.5 ETH | 0.00803104 | ||||
| Claim | 14694660 | 1394 days ago | IN | 0.5 ETH | 0.00967038 | ||||
| Claim | 14694643 | 1394 days ago | IN | 0.5 ETH | 0.00866211 |
Latest 25 internal transactions (View All)
Advanced mode:
| Parent Transaction Hash | Method | Block |
From
|
|
To
|
||
|---|---|---|---|---|---|---|---|
| - | 14701154 | 1393 days ago | 0.5 ETH | ||||
| - | 14698999 | 1393 days ago | 0.5 ETH | ||||
| - | 14698995 | 1393 days ago | 0.5 ETH | ||||
| - | 14696412 | 1394 days ago | 0.5 ETH | ||||
| - | 14695855 | 1394 days ago | 0.5 ETH | ||||
| - | 14694761 | 1394 days ago | 0.5 ETH | ||||
| - | 14694754 | 1394 days ago | 0.5 ETH | ||||
| - | 14694739 | 1394 days ago | 0.5 ETH | ||||
| - | 14694735 | 1394 days ago | 0.5 ETH | ||||
| - | 14694734 | 1394 days ago | 0.5 ETH | ||||
| - | 14694732 | 1394 days ago | 0.5 ETH | ||||
| - | 14694728 | 1394 days ago | 0.5 ETH | ||||
| - | 14694713 | 1394 days ago | 0.5 ETH | ||||
| - | 14694703 | 1394 days ago | 0.5 ETH | ||||
| - | 14694696 | 1394 days ago | 0.5 ETH | ||||
| - | 14694696 | 1394 days ago | 0.5 ETH | ||||
| - | 14694690 | 1394 days ago | 0.5 ETH | ||||
| - | 14694676 | 1394 days ago | 0.5 ETH | ||||
| - | 14694675 | 1394 days ago | 0.5 ETH | ||||
| - | 14694675 | 1394 days ago | 0.5 ETH | ||||
| - | 14694668 | 1394 days ago | 0.5 ETH | ||||
| - | 14694668 | 1394 days ago | 0.5 ETH | ||||
| - | 14694666 | 1394 days ago | 0.5 ETH | ||||
| - | 14694660 | 1394 days ago | 0.5 ETH | ||||
| - | 14694643 | 1394 days ago | 0.5 ETH |
Loading...
Loading
Loading...
Loading
Cross-Chain Transactions
Loading...
Loading
Similar Match Source Code This contract matches the deployed Bytecode of the Source Code for Contract 0x77E48249...7233db213 The constructor portion of the code might be different and could alter the actual behaviour of the contract
Contract Name:
GenesisKeyDistributor
Compiler Version
v0.8.6+commit.11564f7e
Optimization Enabled:
Yes with 0 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
//SPDX-License-Identifier: Unlicense
pragma solidity ^0.8.0;
import "../interface/IGenesisKeyDistributor.sol";
import "../interface/IGenesisKey.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
contract GenesisKeyDistributor is IGenesisKeyDistributor {
address public immutable override genesisKey;
bytes32 public immutable override merkleRoot;
uint256 public immutable override ethAmount;
// This is a packed array of booleans.
mapping(uint256 => uint256) private claimedBitMap;
constructor(
address genesisKey_,
bytes32 merkleRoot_,
uint256 ethAmount_
) {
genesisKey = genesisKey_;
merkleRoot = merkleRoot_;
ethAmount = ethAmount_;
}
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 tokenId,
bytes32[] calldata merkleProof
) external payable override {
require(msg.sender == account);
require(msg.value == ethAmount);
require(!isClaimed(index), "GenesisKeyDistributor: Drop already claimed.");
// Verify the merkle proof.
bytes32 node = keccak256(abi.encodePacked(index, account, tokenId));
require(MerkleProof.verify(merkleProof, merkleRoot, node), "GenesisKeyDistributor: Invalid proof.");
// Mark it claimed and send the token.
_setClaimed(index);
IGenesisKey(genesisKey).claimKey{ value: ethAmount }(account, ethAmount);
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 IGenesisKeyDistributor {
// Returns the address of the genesisKey contract.
function genesisKey() 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 profile auction contract address.
function ethAmount() 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 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: Unlicense
pragma solidity ^0.8.0;
interface IGenesisKey {
function claimKey(address recipient, uint256 _eth) external payable returns (bool);
}// 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);
}// 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;
}
}{
"metadata": {
"bytecodeHash": "none"
},
"optimizer": {
"enabled": true,
"runs": 0
},
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
},
"libraries": {}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[{"internalType":"address","name":"genesisKey_","type":"address"},{"internalType":"bytes32","name":"merkleRoot_","type":"bytes32"},{"internalType":"uint256","name":"ethAmount_","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":"tokenId","type":"uint256"}],"name":"Claimed","type":"event"},{"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":"ethAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"genesisKey","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","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"}]Contract Creation Code
0x60e060405234801561001057600080fd5b506040516107a73803806107a783398101604081905261002f9161004d565b60609290921b6001600160601b03191660805260a05260c052610090565b60008060006060848603121561006257600080fd5b83516001600160a01b038116811461007957600080fd5b602085015160409095015190969495509392505050565b60805160601c60a05160c0516106cb6100dc6000396000818161013901528181610172015261033401526000818160c701526102870152600081816061015261035c01526106cb6000f3fe60806040526004361061004a5760003560e01c8063034e68ab1461004f5780632e7ba6ef146100a05780632eb4a7ab146100b55780639e34070f146100f7578063c98166c014610127575b600080fd5b34801561005b57600080fd5b506100837f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020015b60405180910390f35b6100b36100ae36600461059d565b61015b565b005b3480156100c157600080fd5b506100e97f000000000000000000000000000000000000000000000000000000000000000081565b604051908152602001610097565b34801561010357600080fd5b50610117610112366004610584565b61042d565b6040519015158152602001610097565b34801561013357600080fd5b506100e97f000000000000000000000000000000000000000000000000000000000000000081565b336001600160a01b0385161461017057600080fd5b7f0000000000000000000000000000000000000000000000000000000000000000341461019c57600080fd5b6101a58561042d565b1561020c5760405162461bcd60e51b815260206004820152602c60248201527f47656e657369734b65794469737472696275746f723a2044726f7020616c726560448201526b30b23c9031b630b4b6b2b21760a11b60648201526084015b60405180910390fd5b60408051602081018790526001600160601b0319606087901b1691810191909152605481018490526000906074016040516020818303038152906040528051906020012090506102b28383808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152507f0000000000000000000000000000000000000000000000000000000000000000925085915061046e9050565b61030c5760405162461bcd60e51b815260206004820152602560248201527f47656e657369734b65794469737472696275746f723a20496e76616c696420706044820152643937b7b31760d91b6064820152608401610203565b6103158661051d565b60405163df051a3d60e01b81526001600160a01b0386811660048301527f0000000000000000000000000000000000000000000000000000000000000000602483018190527f00000000000000000000000000000000000000000000000000000000000000009091169163df051a3d91906044016020604051808303818588803b1580156103a257600080fd5b505af11580156103b6573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052508101906103db919061055b565b50604080518781526001600160a01b03871660208201529081018590527f4ec90e965519d92681267467f775ada5bd214aa92c0dc93d90a5e880ce9ed0269060600160405180910390a1505050505050565b60008061043c61010084610641565b9050600061044c6101008561067e565b60009283526020839052604090922054600190921b9182169091149392505050565b600081815b8551811015610512576000868281518110610490576104906106a8565b602002602001015190508083116104d25760408051602081018590529081018290526060016040516020818303038152906040528051906020012092506104ff565b60408051602081018390529081018490526060016040516020818303038152906040528051906020012092505b508061050a81610655565b915050610473565b509092149392505050565b600061052b61010083610641565b9050600061053b6101008461067e565b6000928352602083905260409092208054600190931b9092179091555050565b60006020828403121561056d57600080fd5b8151801515811461057d57600080fd5b9392505050565b60006020828403121561059657600080fd5b5035919050565b6000806000806000608086880312156105b557600080fd5b8535945060208601356001600160a01b03811681146105d357600080fd5b93506040860135925060608601356001600160401b03808211156105f657600080fd5b818801915088601f83011261060a57600080fd5b81358181111561061957600080fd5b8960208260051b850101111561062e57600080fd5b9699959850939650602001949392505050565b60008261065057610650610692565b500490565b600060001982141561067757634e487b7160e01b600052601160045260246000fd5b5060010190565b60008261068d5761068d610692565b500690565b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603260045260246000fdfea164736f6c6343000806000a0000000000000000000000008fb5a7894ab461a59acdfab8918335768e41141473bbb077cade1abd15b76f3ff908a5f42413d1e42f1f03b87f94e0606221974700000000000000000000000000000000000000000000000006f05b59d3b20000
Deployed Bytecode
0x60806040526004361061004a5760003560e01c8063034e68ab1461004f5780632e7ba6ef146100a05780632eb4a7ab146100b55780639e34070f146100f7578063c98166c014610127575b600080fd5b34801561005b57600080fd5b506100837f0000000000000000000000008fb5a7894ab461a59acdfab8918335768e41141481565b6040516001600160a01b0390911681526020015b60405180910390f35b6100b36100ae36600461059d565b61015b565b005b3480156100c157600080fd5b506100e97f73bbb077cade1abd15b76f3ff908a5f42413d1e42f1f03b87f94e0606221974781565b604051908152602001610097565b34801561010357600080fd5b50610117610112366004610584565b61042d565b6040519015158152602001610097565b34801561013357600080fd5b506100e97f00000000000000000000000000000000000000000000000006f05b59d3b2000081565b336001600160a01b0385161461017057600080fd5b7f00000000000000000000000000000000000000000000000006f05b59d3b20000341461019c57600080fd5b6101a58561042d565b1561020c5760405162461bcd60e51b815260206004820152602c60248201527f47656e657369734b65794469737472696275746f723a2044726f7020616c726560448201526b30b23c9031b630b4b6b2b21760a11b60648201526084015b60405180910390fd5b60408051602081018790526001600160601b0319606087901b1691810191909152605481018490526000906074016040516020818303038152906040528051906020012090506102b28383808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152507f73bbb077cade1abd15b76f3ff908a5f42413d1e42f1f03b87f94e06062219747925085915061046e9050565b61030c5760405162461bcd60e51b815260206004820152602560248201527f47656e657369734b65794469737472696275746f723a20496e76616c696420706044820152643937b7b31760d91b6064820152608401610203565b6103158661051d565b60405163df051a3d60e01b81526001600160a01b0386811660048301527f00000000000000000000000000000000000000000000000006f05b59d3b20000602483018190527f0000000000000000000000008fb5a7894ab461a59acdfab8918335768e4114149091169163df051a3d91906044016020604051808303818588803b1580156103a257600080fd5b505af11580156103b6573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052508101906103db919061055b565b50604080518781526001600160a01b03871660208201529081018590527f4ec90e965519d92681267467f775ada5bd214aa92c0dc93d90a5e880ce9ed0269060600160405180910390a1505050505050565b60008061043c61010084610641565b9050600061044c6101008561067e565b60009283526020839052604090922054600190921b9182169091149392505050565b600081815b8551811015610512576000868281518110610490576104906106a8565b602002602001015190508083116104d25760408051602081018590529081018290526060016040516020818303038152906040528051906020012092506104ff565b60408051602081018390529081018490526060016040516020818303038152906040528051906020012092505b508061050a81610655565b915050610473565b509092149392505050565b600061052b61010083610641565b9050600061053b6101008461067e565b6000928352602083905260409092208054600190931b9092179091555050565b60006020828403121561056d57600080fd5b8151801515811461057d57600080fd5b9392505050565b60006020828403121561059657600080fd5b5035919050565b6000806000806000608086880312156105b557600080fd5b8535945060208601356001600160a01b03811681146105d357600080fd5b93506040860135925060608601356001600160401b03808211156105f657600080fd5b818801915088601f83011261060a57600080fd5b81358181111561061957600080fd5b8960208260051b850101111561062e57600080fd5b9699959850939650602001949392505050565b60008261065057610650610692565b500490565b600060001982141561067757634e487b7160e01b600052601160045260246000fd5b5060010190565b60008261068d5761068d610692565b500690565b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603260045260246000fdfea164736f6c6343000806000a
Loading...
Loading
Loading...
Loading
Net Worth in USD
$0.00
Net Worth in ETH
0
Multichain Portfolio | 34 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|
Loading...
Loading
Loading...
Loading
Loading...
Loading
[ Download: CSV Export ]
[ 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.