More Info
Private Name Tags
ContractCreator
Latest 8 from a total of 8 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Claim | 12375628 | 1 hr ago | IN | 0 S | 0.00597371 | ||||
Claim | 12356809 | 4 hrs ago | IN | 0 S | 0.00591313 | ||||
Claim | 12331371 | 7 hrs ago | IN | 0 S | 0.00689964 | ||||
Claim | 12284514 | 12 hrs ago | IN | 0 S | 0.00597201 | ||||
Claim | 12270646 | 13 hrs ago | IN | 0 S | 0.00690094 | ||||
Claim | 12257517 | 15 hrs ago | IN | 0 S | 0.0082791 | ||||
Transfer Ownersh... | 11993532 | 44 hrs ago | IN | 0 S | 0.00210374 | ||||
Set Authority | 11993427 | 45 hrs ago | IN | 0 S | 0.00275143 |
Latest 1 internal transaction
Parent Transaction Hash | Block | From | To | |||
---|---|---|---|---|---|---|
600138 | 79 days ago | Contract Creation | 0 S |
Loading...
Loading
Contract Name:
IncentiveDistributor
Compiler Version
v0.8.21+commit.d9974bed
Optimization Enabled:
Yes with 200 runs
Other Settings:
shanghai EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.0; import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol"; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol"; import {Owned} from "@solmate/auth/Owned.sol"; import {Auth, Authority} from "@solmate/auth/Auth.sol"; contract IncentiveDistributor is Auth { using SafeERC20 for IERC20; // merkleroot -> bool mapping(bytes32 => bool) public merkleAvailable; //merkleroot -> user address -> bool mapping(bytes32 => mapping(address => bool)) public claimed; event RegisteredMerkleTree(bytes32 rootHash); event UnRegisteredMerkleTree(bytes32 rootHash); event Claimed(bytes32 rootHash, address user, address token, uint256 balance); constructor(address _owner, Authority _authority) Auth(_owner, _authority) {} function registerMerkleTree(bytes32 _rootHash) external requiresAuth { require(!merkleAvailable[_rootHash], "Already registered"); merkleAvailable[_rootHash] = true; emit RegisteredMerkleTree(_rootHash); } function unregisterMerkleTree(bytes32 _rootHash) external requiresAuth { require(merkleAvailable[_rootHash], "Not registered"); merkleAvailable[_rootHash] = false; emit UnRegisteredMerkleTree(_rootHash); } function claim( address _to, bytes32[] calldata _rootHashes, address[] calldata _tokens, uint256[] calldata _balances, bytes32[][] calldata _merkleProofs ) external requiresAuth { uint256 length = _rootHashes.length; require(_tokens.length == length, "Incorrect array length"); require(_balances.length == length, "Incorrect array length"); require(_merkleProofs.length == length, "Incorrect array length"); for (uint256 i; i < length; ++i) { _claim(_to, _tokens[i], _balances[i], _rootHashes[i], _merkleProofs[i]); _pay(_to, _tokens[i], _balances[i]); } } function verifyClaim( address _to, address _token, uint256 _balance, bytes32 _rootHash, bytes32[] calldata _merkleProof ) external view returns (bool) { require(merkleAvailable[_rootHash] == true, "Not available merkle root"); return _verifyClaim(_to, _token, _balance, _rootHash, _merkleProof); } function withdraw(address _to, address _token, uint256 _balance) external requiresAuth { uint256 tokenAmount = _balance; if (_balance == 0) { tokenAmount = IERC20(_token).balanceOf(address(this)); } IERC20(_token).safeTransfer(_to, tokenAmount); } function _claim(address _to, address _token, uint256 _balance, bytes32 _rootHash, bytes32[] calldata _merkleProof) private { require(merkleAvailable[_rootHash] == true, "Not available merkle root"); require(!claimed[_rootHash][_to], "It has already claimed"); require(_verifyClaim(_to, _token, _balance, _rootHash, _merkleProof), "Incorrect merkle proof"); claimed[_rootHash][_to] = true; emit Claimed(_rootHash, _to, _token, _balance); } function _verifyClaim( address _to, address _token, uint256 _balance, bytes32 _rootHash, bytes32[] calldata _merkleProof ) private pure returns (bool) { bytes32 leaf = keccak256(bytes.concat(keccak256(abi.encode(_to, _token, _balance)))); return MerkleProof.verify(_merkleProof, _rootHash, leaf); } function _pay(address _to, address _token, uint256 _balance) private { require(_balance > 0, "No balance would be transferred"); IERC20(_token).safeTransfer(_to, _balance); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/cryptography/MerkleProof.sol) pragma solidity ^0.8.20; /** * @dev These functions deal with verification of Merkle Tree proofs. * * The tree and the proofs can be generated using our * https://github.com/OpenZeppelin/merkle-tree[JavaScript library]. * You will find a quickstart guide in the readme. * * WARNING: You should avoid using leaf values that are 64 bytes long prior to * hashing, or use a hash function other than keccak256 for hashing leaves. * This is because the concatenation of a sorted pair of internal nodes in * the Merkle tree could be reinterpreted as a leaf value. * OpenZeppelin's JavaScript library generates Merkle trees that are safe * against this attack out of the box. */ library MerkleProof { /** *@dev The multiproof provided is not valid. */ error MerkleProofInvalidMultiproof(); /** * @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) { return processProof(proof, leaf) == root; } /** * @dev Calldata version of {verify} */ function verifyCalldata(bytes32[] calldata proof, bytes32 root, bytes32 leaf) internal pure returns (bool) { return processProofCalldata(proof, leaf) == root; } /** * @dev Returns the rebuilt hash obtained by traversing a Merkle tree up * from `leaf` using `proof`. A `proof` is valid if and only if the rebuilt * hash matches the root of the tree. When processing the proof, the pairs * of leafs & pre-images are assumed to be sorted. */ function processProof(bytes32[] memory proof, bytes32 leaf) internal pure returns (bytes32) { bytes32 computedHash = leaf; for (uint256 i = 0; i < proof.length; i++) { computedHash = _hashPair(computedHash, proof[i]); } return computedHash; } /** * @dev Calldata version of {processProof} */ function processProofCalldata(bytes32[] calldata proof, bytes32 leaf) internal pure returns (bytes32) { bytes32 computedHash = leaf; for (uint256 i = 0; i < proof.length; i++) { computedHash = _hashPair(computedHash, proof[i]); } return computedHash; } /** * @dev Returns true if the `leaves` can be simultaneously proven to be a part of a Merkle tree defined by * `root`, according to `proof` and `proofFlags` as described in {processMultiProof}. * * CAUTION: Not all Merkle trees admit multiproofs. See {processMultiProof} for details. */ function multiProofVerify( bytes32[] memory proof, bool[] memory proofFlags, bytes32 root, bytes32[] memory leaves ) internal pure returns (bool) { return processMultiProof(proof, proofFlags, leaves) == root; } /** * @dev Calldata version of {multiProofVerify} * * CAUTION: Not all Merkle trees admit multiproofs. See {processMultiProof} for details. */ function multiProofVerifyCalldata( bytes32[] calldata proof, bool[] calldata proofFlags, bytes32 root, bytes32[] memory leaves ) internal pure returns (bool) { return processMultiProofCalldata(proof, proofFlags, leaves) == root; } /** * @dev Returns the root of a tree reconstructed from `leaves` and sibling nodes in `proof`. The reconstruction * proceeds by incrementally reconstructing all inner nodes by combining a leaf/inner node with either another * leaf/inner node or a proof sibling node, depending on whether each `proofFlags` item is true or false * respectively. * * CAUTION: Not all Merkle trees admit multiproofs. To use multiproofs, it is sufficient to ensure that: 1) the tree * is complete (but not necessarily perfect), 2) the leaves to be proven are in the opposite order they are in the * tree (i.e., as seen from right to left starting at the deepest layer and continuing at the next layer). */ function processMultiProof( bytes32[] memory proof, bool[] memory proofFlags, bytes32[] memory leaves ) internal pure returns (bytes32 merkleRoot) { // This function rebuilds the root hash by traversing the tree up from the leaves. The root is rebuilt by // consuming and producing values on a queue. The queue starts with the `leaves` array, then goes onto the // `hashes` array. At the end of the process, the last hash in the `hashes` array should contain the root of // the Merkle tree. uint256 leavesLen = leaves.length; uint256 proofLen = proof.length; uint256 totalHashes = proofFlags.length; // Check proof validity. if (leavesLen + proofLen != totalHashes + 1) { revert MerkleProofInvalidMultiproof(); } // The xxxPos values are "pointers" to the next value to consume in each array. All accesses are done using // `xxx[xxxPos++]`, which return the current value and increment the pointer, thus mimicking a queue's "pop". bytes32[] memory hashes = new bytes32[](totalHashes); uint256 leafPos = 0; uint256 hashPos = 0; uint256 proofPos = 0; // At each step, we compute the next hash using two values: // - a value from the "main queue". If not all leaves have been consumed, we get the next leaf, otherwise we // get the next hash. // - depending on the flag, either another value from the "main queue" (merging branches) or an element from the // `proof` array. for (uint256 i = 0; i < totalHashes; i++) { bytes32 a = leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++]; bytes32 b = proofFlags[i] ? (leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++]) : proof[proofPos++]; hashes[i] = _hashPair(a, b); } if (totalHashes > 0) { if (proofPos != proofLen) { revert MerkleProofInvalidMultiproof(); } unchecked { return hashes[totalHashes - 1]; } } else if (leavesLen > 0) { return leaves[0]; } else { return proof[0]; } } /** * @dev Calldata version of {processMultiProof}. * * CAUTION: Not all Merkle trees admit multiproofs. See {processMultiProof} for details. */ function processMultiProofCalldata( bytes32[] calldata proof, bool[] calldata proofFlags, bytes32[] memory leaves ) internal pure returns (bytes32 merkleRoot) { // This function rebuilds the root hash by traversing the tree up from the leaves. The root is rebuilt by // consuming and producing values on a queue. The queue starts with the `leaves` array, then goes onto the // `hashes` array. At the end of the process, the last hash in the `hashes` array should contain the root of // the Merkle tree. uint256 leavesLen = leaves.length; uint256 proofLen = proof.length; uint256 totalHashes = proofFlags.length; // Check proof validity. if (leavesLen + proofLen != totalHashes + 1) { revert MerkleProofInvalidMultiproof(); } // The xxxPos values are "pointers" to the next value to consume in each array. All accesses are done using // `xxx[xxxPos++]`, which return the current value and increment the pointer, thus mimicking a queue's "pop". bytes32[] memory hashes = new bytes32[](totalHashes); uint256 leafPos = 0; uint256 hashPos = 0; uint256 proofPos = 0; // At each step, we compute the next hash using two values: // - a value from the "main queue". If not all leaves have been consumed, we get the next leaf, otherwise we // get the next hash. // - depending on the flag, either another value from the "main queue" (merging branches) or an element from the // `proof` array. for (uint256 i = 0; i < totalHashes; i++) { bytes32 a = leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++]; bytes32 b = proofFlags[i] ? (leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++]) : proof[proofPos++]; hashes[i] = _hashPair(a, b); } if (totalHashes > 0) { if (proofPos != proofLen) { revert MerkleProofInvalidMultiproof(); } unchecked { return hashes[totalHashes - 1]; } } else if (leavesLen > 0) { return leaves[0]; } else { return proof[0]; } } /** * @dev Sorts the pair (a, b) and hashes the result. */ function _hashPair(bytes32 a, bytes32 b) private pure returns (bytes32) { return a < b ? _efficientHash(a, b) : _efficientHash(b, a); } /** * @dev Implementation of keccak256(abi.encode(a, b)) that doesn't allocate or expand memory. */ function _efficientHash(bytes32 a, bytes32 b) private pure returns (bytes32 value) { /// @solidity memory-safe-assembly assembly { mstore(0x00, a) mstore(0x20, b) value := keccak256(0x00, 0x40) } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/IERC20.sol) pragma solidity ^0.8.20; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @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); /** * @dev Returns the value of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the value of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves a `value` amount of tokens from the caller's account to `to`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address to, uint256 value) 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 a `value` amount of tokens 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 value) external returns (bool); /** * @dev Moves a `value` amount of tokens from `from` to `to` using the * allowance mechanism. `value` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom(address from, address to, uint256 value) external returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/utils/SafeERC20.sol) pragma solidity ^0.8.20; import {IERC20} from "../IERC20.sol"; import {IERC20Permit} from "../extensions/IERC20Permit.sol"; import {Address} from "../../../utils/Address.sol"; /** * @title SafeERC20 * @dev Wrappers around ERC20 operations that throw on failure (when the token * contract returns false). Tokens that return no value (and instead revert or * throw on failure) are also supported, non-reverting calls are assumed to be * successful. * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract, * which allows you to call the safe operations as `token.safeTransfer(...)`, etc. */ library SafeERC20 { using Address for address; /** * @dev An operation with an ERC20 token failed. */ error SafeERC20FailedOperation(address token); /** * @dev Indicates a failed `decreaseAllowance` request. */ error SafeERC20FailedDecreaseAllowance(address spender, uint256 currentAllowance, uint256 requestedDecrease); /** * @dev Transfer `value` amount of `token` from the calling contract to `to`. If `token` returns no value, * non-reverting calls are assumed to be successful. */ function safeTransfer(IERC20 token, address to, uint256 value) internal { _callOptionalReturn(token, abi.encodeCall(token.transfer, (to, value))); } /** * @dev Transfer `value` amount of `token` from `from` to `to`, spending the approval given by `from` to the * calling contract. If `token` returns no value, non-reverting calls are assumed to be successful. */ function safeTransferFrom(IERC20 token, address from, address to, uint256 value) internal { _callOptionalReturn(token, abi.encodeCall(token.transferFrom, (from, to, value))); } /** * @dev Increase the calling contract's allowance toward `spender` by `value`. If `token` returns no value, * non-reverting calls are assumed to be successful. */ function safeIncreaseAllowance(IERC20 token, address spender, uint256 value) internal { uint256 oldAllowance = token.allowance(address(this), spender); forceApprove(token, spender, oldAllowance + value); } /** * @dev Decrease the calling contract's allowance toward `spender` by `requestedDecrease`. If `token` returns no * value, non-reverting calls are assumed to be successful. */ function safeDecreaseAllowance(IERC20 token, address spender, uint256 requestedDecrease) internal { unchecked { uint256 currentAllowance = token.allowance(address(this), spender); if (currentAllowance < requestedDecrease) { revert SafeERC20FailedDecreaseAllowance(spender, currentAllowance, requestedDecrease); } forceApprove(token, spender, currentAllowance - requestedDecrease); } } /** * @dev Set the calling contract's allowance toward `spender` to `value`. If `token` returns no value, * non-reverting calls are assumed to be successful. Meant to be used with tokens that require the approval * to be set to zero before setting it to a non-zero value, such as USDT. */ function forceApprove(IERC20 token, address spender, uint256 value) internal { bytes memory approvalCall = abi.encodeCall(token.approve, (spender, value)); if (!_callOptionalReturnBool(token, approvalCall)) { _callOptionalReturn(token, abi.encodeCall(token.approve, (spender, 0))); _callOptionalReturn(token, approvalCall); } } /** * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement * on the return value: the return value is optional (but if data is returned, it must not be false). * @param token The token targeted by the call. * @param data The call data (encoded using abi.encode or one of its variants). */ function _callOptionalReturn(IERC20 token, bytes memory data) private { // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since // we're implementing it ourselves. We use {Address-functionCall} to perform this call, which verifies that // the target address contains contract code and also asserts for success in the low-level call. bytes memory returndata = address(token).functionCall(data); if (returndata.length != 0 && !abi.decode(returndata, (bool))) { revert SafeERC20FailedOperation(address(token)); } } /** * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement * on the return value: the return value is optional (but if data is returned, it must not be false). * @param token The token targeted by the call. * @param data The call data (encoded using abi.encode or one of its variants). * * This is a variant of {_callOptionalReturn} that silents catches all reverts and returns a bool instead. */ function _callOptionalReturnBool(IERC20 token, bytes memory data) private returns (bool) { // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since // we're implementing it ourselves. We cannot use {Address-functionCall} here since this should return false // and not revert is the subcall reverts. (bool success, bytes memory returndata) = address(token).call(data); return success && (returndata.length == 0 || abi.decode(returndata, (bool))) && address(token).code.length > 0; } }
// SPDX-License-Identifier: AGPL-3.0-only pragma solidity >=0.8.0; /// @notice Simple single owner authorization mixin. /// @author Solmate (https://github.com/transmissions11/solmate/blob/main/src/auth/Owned.sol) abstract contract Owned { /*////////////////////////////////////////////////////////////// EVENTS //////////////////////////////////////////////////////////////*/ event OwnershipTransferred(address indexed user, address indexed newOwner); /*////////////////////////////////////////////////////////////// OWNERSHIP STORAGE //////////////////////////////////////////////////////////////*/ address public owner; modifier onlyOwner() virtual { require(msg.sender == owner, "UNAUTHORIZED"); _; } /*////////////////////////////////////////////////////////////// CONSTRUCTOR //////////////////////////////////////////////////////////////*/ constructor(address _owner) { owner = _owner; emit OwnershipTransferred(address(0), _owner); } /*////////////////////////////////////////////////////////////// OWNERSHIP LOGIC //////////////////////////////////////////////////////////////*/ function transferOwnership(address newOwner) public virtual onlyOwner { owner = newOwner; emit OwnershipTransferred(msg.sender, newOwner); } }
// SPDX-License-Identifier: AGPL-3.0-only pragma solidity >=0.8.0; /// @notice Provides a flexible and updatable auth pattern which is completely separate from application logic. /// @author Solmate (https://github.com/transmissions11/solmate/blob/main/src/auth/Auth.sol) /// @author Modified from Dappsys (https://github.com/dapphub/ds-auth/blob/master/src/auth.sol) abstract contract Auth { event OwnershipTransferred(address indexed user, address indexed newOwner); event AuthorityUpdated(address indexed user, Authority indexed newAuthority); address public owner; Authority public authority; constructor(address _owner, Authority _authority) { owner = _owner; authority = _authority; emit OwnershipTransferred(msg.sender, _owner); emit AuthorityUpdated(msg.sender, _authority); } modifier requiresAuth() virtual { require(isAuthorized(msg.sender, msg.sig), "UNAUTHORIZED"); _; } function isAuthorized(address user, bytes4 functionSig) internal view virtual returns (bool) { Authority auth = authority; // Memoizing authority saves us a warm SLOAD, around 100 gas. // Checking if the caller is the owner only after calling the authority saves gas in most cases, but be // aware that this makes protected functions uncallable even to the owner if the authority is out of order. return (address(auth) != address(0) && auth.canCall(user, address(this), functionSig)) || user == owner; } function setAuthority(Authority newAuthority) public virtual { // We check if the caller is the owner first because we want to ensure they can // always swap out the authority even if it's reverting or using up a lot of gas. require(msg.sender == owner || authority.canCall(msg.sender, address(this), msg.sig)); authority = newAuthority; emit AuthorityUpdated(msg.sender, newAuthority); } function transferOwnership(address newOwner) public virtual requiresAuth { owner = newOwner; emit OwnershipTransferred(msg.sender, newOwner); } } /// @notice A generic interface for a contract which provides authorization data to an Auth instance. /// @author Solmate (https://github.com/transmissions11/solmate/blob/main/src/auth/Auth.sol) /// @author Modified from Dappsys (https://github.com/dapphub/ds-auth/blob/master/src/auth.sol) interface Authority { function canCall( address user, address target, bytes4 functionSig ) external view returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/extensions/IERC20Permit.sol) pragma solidity ^0.8.20; /** * @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612]. * * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by * presenting a message signed by the account. By not relying on {IERC20-approve}, the token holder account doesn't * need to send a transaction, and thus is not required to hold Ether at all. * * ==== Security Considerations * * There are two important considerations concerning the use of `permit`. The first is that a valid permit signature * expresses an allowance, and it should not be assumed to convey additional meaning. In particular, it should not be * considered as an intention to spend the allowance in any specific way. The second is that because permits have * built-in replay protection and can be submitted by anyone, they can be frontrun. A protocol that uses permits should * take this into consideration and allow a `permit` call to fail. Combining these two aspects, a pattern that may be * generally recommended is: * * ```solidity * function doThingWithPermit(..., uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s) public { * try token.permit(msg.sender, address(this), value, deadline, v, r, s) {} catch {} * doThing(..., value); * } * * function doThing(..., uint256 value) public { * token.safeTransferFrom(msg.sender, address(this), value); * ... * } * ``` * * Observe that: 1) `msg.sender` is used as the owner, leaving no ambiguity as to the signer intent, and 2) the use of * `try/catch` allows the permit to fail and makes the code tolerant to frontrunning. (See also * {SafeERC20-safeTransferFrom}). * * Additionally, note that smart contract wallets (such as Argent or Safe) are not able to produce permit signatures, so * contracts should have entry points that don't rely on permit. */ interface IERC20Permit { /** * @dev Sets `value` as the allowance of `spender` over ``owner``'s tokens, * given ``owner``'s signed approval. * * IMPORTANT: The same issues {IERC20-approve} has related to transaction * ordering also apply here. * * Emits an {Approval} event. * * Requirements: * * - `spender` cannot be the zero address. * - `deadline` must be a timestamp in the future. * - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner` * over the EIP712-formatted function arguments. * - the signature must use ``owner``'s current nonce (see {nonces}). * * For more information on the signature format, see the * https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP * section]. * * CAUTION: See Security Considerations above. */ function permit( address owner, address spender, uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s ) external; /** * @dev Returns the current nonce for `owner`. This value must be * included whenever a signature is generated for {permit}. * * Every successful call to {permit} increases ``owner``'s nonce by one. This * prevents a signature from being used multiple times. */ function nonces(address owner) external view returns (uint256); /** * @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}. */ // solhint-disable-next-line func-name-mixedcase function DOMAIN_SEPARATOR() external view returns (bytes32); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/Address.sol) pragma solidity ^0.8.20; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev The ETH balance of the account is not enough to perform the operation. */ error AddressInsufficientBalance(address account); /** * @dev There's no code at `target` (it is not a contract). */ error AddressEmptyCode(address target); /** * @dev A call to an address target failed. The target may have reverted. */ error FailedInnerCall(); /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://consensys.net/diligence/blog/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.8.20/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { if (address(this).balance < amount) { revert AddressInsufficientBalance(address(this)); } (bool success, ) = recipient.call{value: amount}(""); if (!success) { revert FailedInnerCall(); } } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason or custom error, it is bubbled * up by this function (like regular Solidity function calls). However, if * the call reverted with no returned reason, this function reverts with a * {FailedInnerCall} error. * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCallWithValue(target, data, 0); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. */ function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) { if (address(this).balance < value) { revert AddressInsufficientBalance(address(this)); } (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResultFromTarget(target, success, returndata); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResultFromTarget(target, success, returndata); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResultFromTarget(target, success, returndata); } /** * @dev Tool to verify that a low level call to smart-contract was successful, and reverts if the target * was not a contract or bubbling up the revert reason (falling back to {FailedInnerCall}) in case of an * unsuccessful call. */ function verifyCallResultFromTarget( address target, bool success, bytes memory returndata ) internal view returns (bytes memory) { if (!success) { _revert(returndata); } else { // only check if target is a contract if the call was successful and the return data is empty // otherwise we already know that it was a contract if (returndata.length == 0 && target.code.length == 0) { revert AddressEmptyCode(target); } return returndata; } } /** * @dev Tool to verify that a low level call was successful, and reverts if it wasn't, either by bubbling the * revert reason or with a default {FailedInnerCall} error. */ function verifyCallResult(bool success, bytes memory returndata) internal pure returns (bytes memory) { if (!success) { _revert(returndata); } else { return returndata; } } /** * @dev Reverts with returndata if present. Otherwise reverts with {FailedInnerCall}. */ function _revert(bytes memory returndata) private pure { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly /// @solidity memory-safe-assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert FailedInnerCall(); } } }
{ "remappings": [ "@solmate/=lib/solmate/src/", "@forge-std/=lib/forge-std/src/", "@ds-test/=lib/forge-std/lib/ds-test/src/", "ds-test/=lib/forge-std/lib/ds-test/src/", "@openzeppelin/=lib/openzeppelin-contracts/", "@ccip/=lib/ccip/", "@oapp-auth/=lib/OAppAuth/src/", "@devtools-oapp-evm/=lib/OAppAuth/lib/devtools/packages/oapp-evm/contracts/oapp/", "@layerzerolabs/lz-evm-messagelib-v2/=lib/OAppAuth/node_modules/@layerzerolabs/lz-evm-messagelib-v2/", "@layerzerolabs/lz-evm-protocol-v2/=lib/OAppAuth/lib/LayerZero-V2/packages/layerzero-v2/evm/protocol/", "@layerzerolabs/oapp-evm/=lib/OAppAuth/lib/devtools/packages/oapp-evm/", "@lz-oapp-evm/=lib/OAppAuth/lib/LayerZero-V2/packages/layerzero-v2/evm/oapp/contracts/oapp/", "@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts/", "@sbu/=lib/OAppAuth/lib/solidity-bytes-utils/", "LayerZero-V2/=lib/OAppAuth/lib/", "OAppAuth/=lib/OAppAuth/", "ccip/=lib/ccip/contracts/", "erc4626-tests/=lib/openzeppelin-contracts/lib/erc4626-tests/", "forge-std/=lib/forge-std/src/", "halmos-cheatcodes/=lib/OAppAuth/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/", "openzeppelin-contracts/=lib/openzeppelin-contracts/", "solidity-bytes-utils/=lib/OAppAuth/node_modules/solidity-bytes-utils/", "solmate/=lib/solmate/src/" ], "optimizer": { "enabled": true, "runs": 200 }, "metadata": { "useLiteralContent": false, "bytecodeHash": "ipfs", "appendCBOR": true }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "evmVersion": "shanghai", "viaIR": false, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[{"internalType":"address","name":"_owner","type":"address"},{"internalType":"contract Authority","name":"_authority","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"target","type":"address"}],"name":"AddressEmptyCode","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"AddressInsufficientBalance","type":"error"},{"inputs":[],"name":"FailedInnerCall","type":"error"},{"inputs":[{"internalType":"address","name":"token","type":"address"}],"name":"SafeERC20FailedOperation","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"contract Authority","name":"newAuthority","type":"address"}],"name":"AuthorityUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"rootHash","type":"bytes32"},{"indexed":false,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"balance","type":"uint256"}],"name":"Claimed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"rootHash","type":"bytes32"}],"name":"RegisteredMerkleTree","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"rootHash","type":"bytes32"}],"name":"UnRegisteredMerkleTree","type":"event"},{"inputs":[],"name":"authority","outputs":[{"internalType":"contract Authority","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"bytes32[]","name":"_rootHashes","type":"bytes32[]"},{"internalType":"address[]","name":"_tokens","type":"address[]"},{"internalType":"uint256[]","name":"_balances","type":"uint256[]"},{"internalType":"bytes32[][]","name":"_merkleProofs","type":"bytes32[][]"}],"name":"claim","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"},{"internalType":"address","name":"","type":"address"}],"name":"claimed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"merkleAvailable","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_rootHash","type":"bytes32"}],"name":"registerMerkleTree","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract Authority","name":"newAuthority","type":"address"}],"name":"setAuthority","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_rootHash","type":"bytes32"}],"name":"unregisterMerkleTree","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_balance","type":"uint256"},{"internalType":"bytes32","name":"_rootHash","type":"bytes32"},{"internalType":"bytes32[]","name":"_merkleProof","type":"bytes32[]"}],"name":"verifyClaim","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_balance","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
608060405234801561000f575f80fd5b5060405161124e38038061124e83398101604081905261002e916100dd565b5f80546001600160a01b03199081166001600160a01b0385811691821784556001805490931690851617909155604051849284929133917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a36040516001600160a01b0382169033907fa3396fd7f6e0a21b50e5089d2da70d5ac0a3bbbd1f617a93f134b76389980198905f90a350505050610115565b6001600160a01b03811681146100da575f80fd5b50565b5f80604083850312156100ee575f80fd5b82516100f9816100c6565b602084015190925061010a816100c6565b809150509250929050565b61112c806101225f395ff3fe608060405234801561000f575f80fd5b50600436106100a6575f3560e01c8063bf7e214f1161006e578063bf7e214f14610146578063d9caed1214610159578063dfcae6221461016c578063ea67517714610199578063f2fde38b146101ac578063f3aed331146101bf575f80fd5b80632546ff62146100aa5780632e1bf1f9146100bf5780636667843b146100e75780637a9e5e4b146101095780638da5cb5b1461011c575b5f80fd5b6100bd6100b8366004610d53565b6101d2565b005b6100d26100cd366004610dc6565b6102ac565b60405190151581526020015b60405180910390f35b6100d26100f5366004610d53565b60026020525f908152604090205460ff1681565b6100bd610117366004610e3d565b610323565b5f5461012e906001600160a01b031681565b6040516001600160a01b0390911681526020016100de565b60015461012e906001600160a01b031681565b6100bd610167366004610e58565b610407565b6100d261017a366004610e96565b600360209081525f928352604080842090915290825290205460ff1681565b6100bd6101a7366004610d53565b6104c4565b6100bd6101ba366004610e3d565b610592565b6100bd6101cd366004610ec4565b61060d565b6101e7335f356001600160e01b031916610792565b61020c5760405162461bcd60e51b815260040161020390610f93565b60405180910390fd5b5f8181526002602052604090205460ff1661025a5760405162461bcd60e51b815260206004820152600e60248201526d139bdd081c9959da5cdd195c995960921b6044820152606401610203565b5f8181526002602052604090819020805460ff19169055517f3c7f98ea33e2313c4290aa5b7c9c736c23b8c2d291464f4134dc92686637a680906102a19083815260200190565b60405180910390a150565b5f8381526002602052604081205460ff16151560011461030a5760405162461bcd60e51b8152602060048201526019602482015278139bdd08185d985a5b18589b19481b595c9adb19481c9bdbdd603a1b6044820152606401610203565b610318878787878787610838565b979650505050505050565b5f546001600160a01b03163314806103b4575060015460405163b700961360e01b81526001600160a01b039091169063b70096139061037590339030906001600160e01b03195f351690600401610fb9565b602060405180830381865afa158015610390573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906103b49190610fe6565b6103bc575f80fd5b600180546001600160a01b0319166001600160a01b03831690811790915560405133907fa3396fd7f6e0a21b50e5089d2da70d5ac0a3bbbd1f617a93f134b76389980198905f90a350565b61041c335f356001600160e01b031916610792565b6104385760405162461bcd60e51b815260040161020390610f93565b805f8190036104aa576040516370a0823160e01b81523060048201526001600160a01b038416906370a0823190602401602060405180830381865afa158015610483573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906104a79190611005565b90505b6104be6001600160a01b03841685836108e3565b50505050565b6104d9335f356001600160e01b031916610792565b6104f55760405162461bcd60e51b815260040161020390610f93565b5f8181526002602052604090205460ff16156105485760405162461bcd60e51b8152602060048201526012602482015271105b1c9958591e481c9959da5cdd195c995960721b6044820152606401610203565b5f8181526002602052604090819020805460ff19166001179055517f5758f3e96c5841077c66799825e4296712b1562e1c673c4e13370723a1c4515b906102a19083815260200190565b6105a7335f356001600160e01b031916610792565b6105c35760405162461bcd60e51b815260040161020390610f93565b5f80546001600160a01b0319166001600160a01b0383169081178255604051909133917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a350565b610622335f356001600160e01b031916610792565b61063e5760405162461bcd60e51b815260040161020390610f93565b8685811461065e5760405162461bcd60e51b81526004016102039061101c565b83811461067d5760405162461bcd60e51b81526004016102039061101c565b81811461069c5760405162461bcd60e51b81526004016102039061101c565b5f5b818110156107855761072c8b8989848181106106bc576106bc61104c565b90506020020160208101906106d19190610e3d565b8888858181106106e3576106e361104c565b905060200201358d8d868181106106fc576106fc61104c565b905060200201358888878181106107155761071561104c565b90506020028101906107279190611060565b61093a565b6107758b8989848181106107425761074261104c565b90506020020160208101906107579190610e3d565b8888858181106107695761076961104c565b90506020020135610ad2565b61077e816110a6565b905061069e565b5050505050505050505050565b6001545f906001600160a01b03168015801590610819575060405163b700961360e01b81526001600160a01b0382169063b7009613906107da90879030908890600401610fb9565b602060405180830381865afa1580156107f5573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906108199190610fe6565b8061083057505f546001600160a01b038581169116145b949350505050565b604080516001600160a01b038089166020830152871691810191909152606081018590525f90819060800160408051601f19818403018152828252805160209182012090830152016040516020818303038152906040528051906020012090506108d78484808060200260200160405190810160405280939291908181526020018383602002808284375f92019190915250899250859150610b359050565b98975050505050505050565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b179052610935908490610b4c565b505050565b5f8381526002602052604090205460ff1615156001146109985760405162461bcd60e51b8152602060048201526019602482015278139bdd08185d985a5b18589b19481b595c9adb19481c9bdbdd603a1b6044820152606401610203565b5f8381526003602090815260408083206001600160a01b038a16845290915290205460ff1615610a035760405162461bcd60e51b8152602060048201526016602482015275125d081a185cc8185b1c9958591e4818db185a5b595960521b6044820152606401610203565b610a11868686868686610838565b610a565760405162461bcd60e51b815260206004820152601660248201527524b731b7b93932b1ba1036b2b935b63290383937b7b360511b6044820152606401610203565b5f8381526003602090815260408083206001600160a01b038a811680865291845293829020805460ff19166001179055815187815292830152918716818301526060810186905290517f8b1927e0809f1e7682bb8c52fafe4c0445fea47afef60dd27e037e91fd104d2e916080908290030190a1505050505050565b5f8111610b215760405162461bcd60e51b815260206004820152601f60248201527f4e6f2062616c616e636520776f756c64206265207472616e73666572726564006044820152606401610203565b6109356001600160a01b03831684836108e3565b5f82610b418584610bad565b1490505b9392505050565b5f610b606001600160a01b03841683610bf9565b905080515f14158015610b84575080806020019051810190610b829190610fe6565b155b1561093557604051635274afe760e01b81526001600160a01b0384166004820152602401610203565b5f81815b8451811015610bf157610bdd82868381518110610bd057610bd061104c565b6020026020010151610c06565b915080610be9816110a6565b915050610bb1565b509392505050565b6060610b4583835f610c32565b5f818310610c20575f828152602084905260409020610b45565b5f838152602083905260409020610b45565b606081471015610c575760405163cd78605960e01b8152306004820152602401610203565b5f80856001600160a01b03168486604051610c7291906110ca565b5f6040518083038185875af1925050503d805f8114610cac576040519150601f19603f3d011682016040523d82523d5f602084013e610cb1565b606091505b5091509150610cc1868383610ccb565b9695505050505050565b606082610ce057610cdb82610d27565b610b45565b8151158015610cf757506001600160a01b0384163b155b15610d2057604051639996b31560e01b81526001600160a01b0385166004820152602401610203565b5080610b45565b805115610d375780518082602001fd5b604051630a12f52160e11b815260040160405180910390fd5b50565b5f60208284031215610d63575f80fd5b5035919050565b6001600160a01b0381168114610d50575f80fd5b5f8083601f840112610d8e575f80fd5b50813567ffffffffffffffff811115610da5575f80fd5b6020830191508360208260051b8501011115610dbf575f80fd5b9250929050565b5f805f805f8060a08789031215610ddb575f80fd5b8635610de681610d6a565b95506020870135610df681610d6a565b94506040870135935060608701359250608087013567ffffffffffffffff811115610e1f575f80fd5b610e2b89828a01610d7e565b979a9699509497509295939492505050565b5f60208284031215610e4d575f80fd5b8135610b4581610d6a565b5f805f60608486031215610e6a575f80fd5b8335610e7581610d6a565b92506020840135610e8581610d6a565b929592945050506040919091013590565b5f8060408385031215610ea7575f80fd5b823591506020830135610eb981610d6a565b809150509250929050565b5f805f805f805f805f60a08a8c031215610edc575f80fd5b8935610ee781610d6a565b985060208a013567ffffffffffffffff80821115610f03575f80fd5b610f0f8d838e01610d7e565b909a50985060408c0135915080821115610f27575f80fd5b610f338d838e01610d7e565b909850965060608c0135915080821115610f4b575f80fd5b610f578d838e01610d7e565b909650945060808c0135915080821115610f6f575f80fd5b50610f7c8c828d01610d7e565b915080935050809150509295985092959850929598565b6020808252600c908201526b15539055551213d49256915160a21b604082015260600190565b6001600160a01b0393841681529190921660208201526001600160e01b0319909116604082015260600190565b5f60208284031215610ff6575f80fd5b81518015158114610b45575f80fd5b5f60208284031215611015575f80fd5b5051919050565b602080825260169082015275092dcc6dee4e4cac6e840c2e4e4c2f240d8cadccee8d60531b604082015260600190565b634e487b7160e01b5f52603260045260245ffd5b5f808335601e19843603018112611075575f80fd5b83018035915067ffffffffffffffff82111561108f575f80fd5b6020019150600581901b3603821315610dbf575f80fd5b5f600182016110c357634e487b7160e01b5f52601160045260245ffd5b5060010190565b5f82515f5b818110156110e957602081860181015185830152016110cf565b505f92019182525091905056fea26469706673582212209f38677786534e6e7f8629f5d6b434b4d076b0d39e707c169ee566e60dcd81d264736f6c63430008150033000000000000000000000000f8553c8552f906c19286f21711721e206ee4909e0000000000000000000000000000000000000000000000000000000000000000
Deployed Bytecode
0x608060405234801561000f575f80fd5b50600436106100a6575f3560e01c8063bf7e214f1161006e578063bf7e214f14610146578063d9caed1214610159578063dfcae6221461016c578063ea67517714610199578063f2fde38b146101ac578063f3aed331146101bf575f80fd5b80632546ff62146100aa5780632e1bf1f9146100bf5780636667843b146100e75780637a9e5e4b146101095780638da5cb5b1461011c575b5f80fd5b6100bd6100b8366004610d53565b6101d2565b005b6100d26100cd366004610dc6565b6102ac565b60405190151581526020015b60405180910390f35b6100d26100f5366004610d53565b60026020525f908152604090205460ff1681565b6100bd610117366004610e3d565b610323565b5f5461012e906001600160a01b031681565b6040516001600160a01b0390911681526020016100de565b60015461012e906001600160a01b031681565b6100bd610167366004610e58565b610407565b6100d261017a366004610e96565b600360209081525f928352604080842090915290825290205460ff1681565b6100bd6101a7366004610d53565b6104c4565b6100bd6101ba366004610e3d565b610592565b6100bd6101cd366004610ec4565b61060d565b6101e7335f356001600160e01b031916610792565b61020c5760405162461bcd60e51b815260040161020390610f93565b60405180910390fd5b5f8181526002602052604090205460ff1661025a5760405162461bcd60e51b815260206004820152600e60248201526d139bdd081c9959da5cdd195c995960921b6044820152606401610203565b5f8181526002602052604090819020805460ff19169055517f3c7f98ea33e2313c4290aa5b7c9c736c23b8c2d291464f4134dc92686637a680906102a19083815260200190565b60405180910390a150565b5f8381526002602052604081205460ff16151560011461030a5760405162461bcd60e51b8152602060048201526019602482015278139bdd08185d985a5b18589b19481b595c9adb19481c9bdbdd603a1b6044820152606401610203565b610318878787878787610838565b979650505050505050565b5f546001600160a01b03163314806103b4575060015460405163b700961360e01b81526001600160a01b039091169063b70096139061037590339030906001600160e01b03195f351690600401610fb9565b602060405180830381865afa158015610390573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906103b49190610fe6565b6103bc575f80fd5b600180546001600160a01b0319166001600160a01b03831690811790915560405133907fa3396fd7f6e0a21b50e5089d2da70d5ac0a3bbbd1f617a93f134b76389980198905f90a350565b61041c335f356001600160e01b031916610792565b6104385760405162461bcd60e51b815260040161020390610f93565b805f8190036104aa576040516370a0823160e01b81523060048201526001600160a01b038416906370a0823190602401602060405180830381865afa158015610483573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906104a79190611005565b90505b6104be6001600160a01b03841685836108e3565b50505050565b6104d9335f356001600160e01b031916610792565b6104f55760405162461bcd60e51b815260040161020390610f93565b5f8181526002602052604090205460ff16156105485760405162461bcd60e51b8152602060048201526012602482015271105b1c9958591e481c9959da5cdd195c995960721b6044820152606401610203565b5f8181526002602052604090819020805460ff19166001179055517f5758f3e96c5841077c66799825e4296712b1562e1c673c4e13370723a1c4515b906102a19083815260200190565b6105a7335f356001600160e01b031916610792565b6105c35760405162461bcd60e51b815260040161020390610f93565b5f80546001600160a01b0319166001600160a01b0383169081178255604051909133917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a350565b610622335f356001600160e01b031916610792565b61063e5760405162461bcd60e51b815260040161020390610f93565b8685811461065e5760405162461bcd60e51b81526004016102039061101c565b83811461067d5760405162461bcd60e51b81526004016102039061101c565b81811461069c5760405162461bcd60e51b81526004016102039061101c565b5f5b818110156107855761072c8b8989848181106106bc576106bc61104c565b90506020020160208101906106d19190610e3d565b8888858181106106e3576106e361104c565b905060200201358d8d868181106106fc576106fc61104c565b905060200201358888878181106107155761071561104c565b90506020028101906107279190611060565b61093a565b6107758b8989848181106107425761074261104c565b90506020020160208101906107579190610e3d565b8888858181106107695761076961104c565b90506020020135610ad2565b61077e816110a6565b905061069e565b5050505050505050505050565b6001545f906001600160a01b03168015801590610819575060405163b700961360e01b81526001600160a01b0382169063b7009613906107da90879030908890600401610fb9565b602060405180830381865afa1580156107f5573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906108199190610fe6565b8061083057505f546001600160a01b038581169116145b949350505050565b604080516001600160a01b038089166020830152871691810191909152606081018590525f90819060800160408051601f19818403018152828252805160209182012090830152016040516020818303038152906040528051906020012090506108d78484808060200260200160405190810160405280939291908181526020018383602002808284375f92019190915250899250859150610b359050565b98975050505050505050565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b179052610935908490610b4c565b505050565b5f8381526002602052604090205460ff1615156001146109985760405162461bcd60e51b8152602060048201526019602482015278139bdd08185d985a5b18589b19481b595c9adb19481c9bdbdd603a1b6044820152606401610203565b5f8381526003602090815260408083206001600160a01b038a16845290915290205460ff1615610a035760405162461bcd60e51b8152602060048201526016602482015275125d081a185cc8185b1c9958591e4818db185a5b595960521b6044820152606401610203565b610a11868686868686610838565b610a565760405162461bcd60e51b815260206004820152601660248201527524b731b7b93932b1ba1036b2b935b63290383937b7b360511b6044820152606401610203565b5f8381526003602090815260408083206001600160a01b038a811680865291845293829020805460ff19166001179055815187815292830152918716818301526060810186905290517f8b1927e0809f1e7682bb8c52fafe4c0445fea47afef60dd27e037e91fd104d2e916080908290030190a1505050505050565b5f8111610b215760405162461bcd60e51b815260206004820152601f60248201527f4e6f2062616c616e636520776f756c64206265207472616e73666572726564006044820152606401610203565b6109356001600160a01b03831684836108e3565b5f82610b418584610bad565b1490505b9392505050565b5f610b606001600160a01b03841683610bf9565b905080515f14158015610b84575080806020019051810190610b829190610fe6565b155b1561093557604051635274afe760e01b81526001600160a01b0384166004820152602401610203565b5f81815b8451811015610bf157610bdd82868381518110610bd057610bd061104c565b6020026020010151610c06565b915080610be9816110a6565b915050610bb1565b509392505050565b6060610b4583835f610c32565b5f818310610c20575f828152602084905260409020610b45565b5f838152602083905260409020610b45565b606081471015610c575760405163cd78605960e01b8152306004820152602401610203565b5f80856001600160a01b03168486604051610c7291906110ca565b5f6040518083038185875af1925050503d805f8114610cac576040519150601f19603f3d011682016040523d82523d5f602084013e610cb1565b606091505b5091509150610cc1868383610ccb565b9695505050505050565b606082610ce057610cdb82610d27565b610b45565b8151158015610cf757506001600160a01b0384163b155b15610d2057604051639996b31560e01b81526001600160a01b0385166004820152602401610203565b5080610b45565b805115610d375780518082602001fd5b604051630a12f52160e11b815260040160405180910390fd5b50565b5f60208284031215610d63575f80fd5b5035919050565b6001600160a01b0381168114610d50575f80fd5b5f8083601f840112610d8e575f80fd5b50813567ffffffffffffffff811115610da5575f80fd5b6020830191508360208260051b8501011115610dbf575f80fd5b9250929050565b5f805f805f8060a08789031215610ddb575f80fd5b8635610de681610d6a565b95506020870135610df681610d6a565b94506040870135935060608701359250608087013567ffffffffffffffff811115610e1f575f80fd5b610e2b89828a01610d7e565b979a9699509497509295939492505050565b5f60208284031215610e4d575f80fd5b8135610b4581610d6a565b5f805f60608486031215610e6a575f80fd5b8335610e7581610d6a565b92506020840135610e8581610d6a565b929592945050506040919091013590565b5f8060408385031215610ea7575f80fd5b823591506020830135610eb981610d6a565b809150509250929050565b5f805f805f805f805f60a08a8c031215610edc575f80fd5b8935610ee781610d6a565b985060208a013567ffffffffffffffff80821115610f03575f80fd5b610f0f8d838e01610d7e565b909a50985060408c0135915080821115610f27575f80fd5b610f338d838e01610d7e565b909850965060608c0135915080821115610f4b575f80fd5b610f578d838e01610d7e565b909650945060808c0135915080821115610f6f575f80fd5b50610f7c8c828d01610d7e565b915080935050809150509295985092959850929598565b6020808252600c908201526b15539055551213d49256915160a21b604082015260600190565b6001600160a01b0393841681529190921660208201526001600160e01b0319909116604082015260600190565b5f60208284031215610ff6575f80fd5b81518015158114610b45575f80fd5b5f60208284031215611015575f80fd5b5051919050565b602080825260169082015275092dcc6dee4e4cac6e840c2e4e4c2f240d8cadccee8d60531b604082015260600190565b634e487b7160e01b5f52603260045260245ffd5b5f808335601e19843603018112611075575f80fd5b83018035915067ffffffffffffffff82111561108f575f80fd5b6020019150600581901b3603821315610dbf575f80fd5b5f600182016110c357634e487b7160e01b5f52601160045260245ffd5b5060010190565b5f82515f5b818110156110e957602081860181015185830152016110cf565b505f92019182525091905056fea26469706673582212209f38677786534e6e7f8629f5d6b434b4d076b0d39e707c169ee566e60dcd81d264736f6c63430008150033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000f8553c8552f906c19286f21711721e206ee4909e0000000000000000000000000000000000000000000000000000000000000000
-----Decoded View---------------
Arg [0] : _owner (address): 0xf8553c8552f906C19286F21711721E206EE4909E
Arg [1] : _authority (address): 0x0000000000000000000000000000000000000000
-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 000000000000000000000000f8553c8552f906c19286f21711721e206ee4909e
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000000
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 31 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
[ 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.