Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
Latest 16 from a total of 16 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Withdraw | 15689913 | 858 days ago | IN | 0 ETH | 0.0028448 | ||||
Withdraw | 15689913 | 858 days ago | IN | 0 ETH | 0.00284556 | ||||
Withdraw | 15689828 | 858 days ago | IN | 0 ETH | 0.00435746 | ||||
Withdraw | 15689822 | 858 days ago | IN | 0 ETH | 0.00265143 | ||||
Deposit | 15648711 | 864 days ago | IN | 0 ETH | 0.00166587 | ||||
Deposit | 15648646 | 864 days ago | IN | 0 ETH | 0.00170397 | ||||
Deposit | 15648205 | 864 days ago | IN | 0 ETH | 0.00146852 | ||||
Deposit | 15648003 | 864 days ago | IN | 0 ETH | 0.00166147 | ||||
Withdraw | 15641248 | 865 days ago | IN | 0 ETH | 0.00153718 | ||||
Deposit | 15641026 | 865 days ago | IN | 0 ETH | 0.0024673 | ||||
Transfer Ownersh... | 15634359 | 866 days ago | IN | 0 ETH | 0.0003332 | ||||
Set Hold Period | 15629531 | 866 days ago | IN | 0 ETH | 0.0002718 | ||||
Withdraw | 15629500 | 866 days ago | IN | 0 ETH | 0.00076601 | ||||
Deposit | 15629492 | 866 days ago | IN | 0 ETH | 0.00142708 | ||||
Withdraw | 15629470 | 866 days ago | IN | 0 ETH | 0.00083609 | ||||
Deposit | 15629442 | 866 days ago | IN | 0 ETH | 0.00117575 |
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Source Code Verified (Exact Match)
Contract Name:
NFTBorrow
Compiler Version
v0.8.17+commit.8df45f5f
Contract Source Code (Solidity)
/** *Submitted for verification at Etherscan.io on 2022-09-28 */ // File: NFT.sol pragma solidity ^0.8.17; type NFTHash is bytes32; /** * @dev Struct representing an individual NFT */ struct NFT { address token; uint256 tokenId; } /** * @dev Creates a hash of an NFT type */ function hashNFT(NFT memory nft) pure returns (NFTHash) { return NFTHash.wrap(keccak256(abi.encodePacked(nft.token, nft.tokenId))); } // File: @openzeppelin/contracts/utils/Context.sol // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } } // File: @openzeppelin/contracts/access/Ownable.sol // OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol) pragma solidity ^0.8.0; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _transferOwnership(_msgSender()); } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { _checkOwner(); _; } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { require(owner() == _msgSender(), "Ownable: caller is not the owner"); } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } } // File: @openzeppelin/contracts/token/ERC721/IERC721Receiver.sol // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721Receiver.sol) pragma solidity ^0.8.0; /** * @title ERC721 token receiver interface * @dev Interface for any contract that wants to support safeTransfers * from ERC721 asset contracts. */ interface IERC721Receiver { /** * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom} * by `operator` from `from`, this function is called. * * It must return its Solidity selector to confirm the token transfer. * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted. * * The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`. */ function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); } // File: @openzeppelin/contracts/utils/introspection/IERC165.sol // OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165 { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); } // File: @openzeppelin/contracts/token/ERC721/IERC721.sol // OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/IERC721.sol) pragma solidity ^0.8.0; /** * @dev Required interface of an ERC721 compliant contract. */ interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets. */ event ApprovalForAll(address indexed owner, address indexed operator, bool approved); /** * @dev Returns the number of tokens in ``owner``'s account. */ function balanceOf(address owner) external view returns (uint256 balance); /** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function ownerOf(uint256 tokenId) external view returns (address owner); /** * @dev Safely transfers `tokenId` token from `from` to `to`. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes calldata data ) external; /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must have been allowed to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Transfers `tokenId` token from `from` to `to`. * * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Gives permission to `to` to transfer `tokenId` token to another account. * The approval is cleared when the token is transferred. * * Only a single account can be approved at a time, so approving the zero address clears previous approvals. * * Requirements: * * - The caller must own the token or be an approved operator. * - `tokenId` must exist. * * Emits an {Approval} event. */ function approve(address to, uint256 tokenId) external; /** * @dev Approve or remove `operator` as an operator for the caller. * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller. * * Requirements: * * - The `operator` cannot be the caller. * * Emits an {ApprovalForAll} event. */ function setApprovalForAll(address operator, bool _approved) external; /** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) external view returns (address operator); /** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll} */ function isApprovedForAll(address owner, address operator) external view returns (bool); } // File: NFTBorrow.sol pragma solidity ^0.8.17; /** * Defines an NFT "borrow" contract that holds NFTs for a specified amount of * time. The contract owner can always return an NFT to its depositor, and * depositors can forcibly take back their NFTs after the hold period is over. * * Deposits to the contract are done using the callback of a `safeTransferFrom` * call to the NFT or by first approving the NFT for use by this contract and * making a `deposit` transaction. * * The contract owner can recover NFTs accidentally sent directly to the * contract address but is unable to steal tokens deposited correctly. */ contract NFTBorrow is IERC721Receiver, Ownable { /** * @dev Maps individual NFTs to their original depositors, which are the * withdrawal destination addresses */ mapping (NFTHash => address) public depositors; /** * @dev Maps individual NFTs to their unlock times */ mapping (NFTHash => uint256) public unlockTime; /** * @dev Stores the amount of time an NFT is held in the contract before it can be * withdrawn */ uint256 public holdPeriod; /** * @dev Emitted when an NFT is deposited to the contract * `unlockTime` describes when the contract owner can withdraw the NFTs */ event Deposit(NFT nft, address depositor, uint256 unlockTime); /** * @dev Emitted when an NFT is withdrawn from the contract */ event Withdrawal(NFT nft, address depositor); /** * @dev Initializes the contract with a specified hold period and the sender * as the owner. */ constructor(uint _holdPeriod) { setHoldPeriod(_holdPeriod); } // ---------- Public methods ---------- // /** * @dev Sets the hold period for new NFTs, in seconds * The owner could frontrun deposits and set an increased hold period using * this function, so there is an upper bound to prevent the owner from * locking a token forever. */ function setHoldPeriod(uint _holdPeriod) public onlyOwner { require( _holdPeriod < 36 weeks, "Hold period must be shorter than 36 weeks" ); holdPeriod = _holdPeriod; } /** * @dev Deposits an NFT using the approve-transferFrom style. * Required for NFTs that do not implement safeTransferFrom. */ function deposit(NFT calldata nft) public { IERC721(nft.token).transferFrom(msg.sender, address(this), nft.tokenId); registerDeposit(nft, msg.sender); } /** * @dev Withdraws an NFT to its original owner. May be called either by * the owner of the smart contract or the depositor. */ function withdraw(NFT calldata nft, bool safe) public { NFTHash nfth = hashNFT(nft); address depositor = depositors[nfth]; require(msg.sender != address(0), "NFT not registered"); require(msg.sender == depositor || msg.sender == owner(), "You must be the NFT depositor or contract owner"); require(block.timestamp >= unlockTime[nfth] || msg.sender == owner(), "You cannot withdraw the NFT yet"); // Unregister NFT delete depositors[nfth]; delete unlockTime[nfth]; // Send the NFT transferNFT(nft, depositor, safe); } /** * @dev Accepts NFTs and records the deposit. The NFT must have been transferred * via the `safeTransferFrom` function or similar that uses a callback. * * Returns `IERC721Receiver.onERC721Received.selector` if the transfer is accepted. */ function onERC721Received( address, address from, uint256 tokenId, bytes calldata ) public virtual override returns (bytes4) { // Record owner and unlock time NFT memory nft = NFT(msg.sender, tokenId); registerDeposit(nft, from); return this.onERC721Received.selector; } /** * @dev Allows for the recovery of an unregistered NFT that did not trigger a * deposit via `onERC721Received`. */ function recoverUnregisteredNFT(NFT calldata nft, address dest, bool safe) public onlyOwner { // Ensure this NFT has not been registered (or was minted to this address) NFTHash nfth = hashNFT(nft); require(depositors[nfth] == address(0), "NFT already registered"); // Transfer to destination transferNFT(nft, dest, safe); } /** * @dev Convenience function to help with creating keys for the public mappings */ function getNFTHash(NFT calldata nft) public pure returns (NFTHash) { return hashNFT(nft); } // ---------- Private methods ---------- // /** * @dev Registers an NFT as having been deposited * This method assumes that the NFT depositor's address is verified. */ function registerDeposit(NFT memory nft, address from) private { // Prevents a case where the owner recovers an NFT to this contract require(from != address(this), "Depositor cannot be this contract"); NFTHash nfth = hashNFT(nft); depositors[nfth] = from; unlockTime[nfth] = block.timestamp + holdPeriod; emit Deposit(nft, depositors[nfth], unlockTime[nfth]); } /** * @dev Transfers an NFT from this contract to a destination address * This method assumes the operation has already been authorized */ function transferNFT(NFT memory nft, address to, bool safe) private { if (safe) { IERC721(nft.token).safeTransferFrom(address(this), to, nft.tokenId); } else { // Unsafe transfer for special NFTs (CryptoKitties) that do not support // safeTransferFrom // The CryptoKitties contract does not consider the owner to be approved, // so we must call the approve function on ourselves IERC721(nft.token).approve(address(this), nft.tokenId); IERC721(nft.token).transferFrom(address(this), to, nft.tokenId); } emit Withdrawal(nft, to); } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"uint256","name":"_holdPeriod","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"components":[{"internalType":"address","name":"token","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"indexed":false,"internalType":"struct NFT","name":"nft","type":"tuple"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":false,"internalType":"uint256","name":"unlockTime","type":"uint256"}],"name":"Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"components":[{"internalType":"address","name":"token","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"indexed":false,"internalType":"struct NFT","name":"nft","type":"tuple"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"}],"name":"Withdrawal","type":"event"},{"inputs":[{"components":[{"internalType":"address","name":"token","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"internalType":"struct NFT","name":"nft","type":"tuple"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"NFTHash","name":"","type":"bytes32"}],"name":"depositors","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"token","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"internalType":"struct NFT","name":"nft","type":"tuple"}],"name":"getNFTHash","outputs":[{"internalType":"NFTHash","name":"","type":"bytes32"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"holdPeriod","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"from","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC721Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"token","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"internalType":"struct NFT","name":"nft","type":"tuple"},{"internalType":"address","name":"dest","type":"address"},{"internalType":"bool","name":"safe","type":"bool"}],"name":"recoverUnregisteredNFT","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_holdPeriod","type":"uint256"}],"name":"setHoldPeriod","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"NFTHash","name":"","type":"bytes32"}],"name":"unlockTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"token","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"internalType":"struct NFT","name":"nft","type":"tuple"},{"internalType":"bool","name":"safe","type":"bool"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
608060405234801561001057600080fd5b50604051610de3380380610de383398101604081905261002f9161016a565b61003833610047565b61004181610097565b50610183565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b61009f61010e565b63014c3a0081106101095760405162461bcd60e51b815260206004820152602960248201527f486f6c6420706572696f64206d7573742062652073686f72746572207468616e604482015268203336207765656b7360b81b60648201526084015b60405180910390fd5b600355565b6000546001600160a01b031633146101685760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610100565b565b60006020828403121561017c57600080fd5b5051919050565b610c51806101926000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c80638da5cb5b116100715780638da5cb5b14610189578063b72d62981461019a578063be809cbe146101ad578063bf5662f6146101c0578063f2fde38b146101d3578063f5967a2f146101e657600080fd5b8063150b7a02146100b9578063243670d7146100ea5780634df5b08c1461012b5780634f84067c146101405780635c7a2a801461016e578063715018a614610181575b600080fd5b6100cc6100c7366004610a03565b6101ef565b6040516001600160e01b031990911681526020015b60405180910390f35b6101136100f8366004610a9e565b6001602052600090815260409020546001600160a01b031681565b6040516001600160a01b0390911681526020016100e1565b61013e610139366004610a9e565b610223565b005b61016061014e366004610a9e565b60026020526000908152604090205481565b6040519081526020016100e1565b61013e61017c366004610acf565b61029a565b61013e61032f565b6000546001600160a01b0316610113565b61013e6101a8366004610b02565b610343565b61013e6101bb366004610b36565b6104f7565b6101606101ce366004610acf565b61058d565b61013e6101e1366004610b7a565b6105a7565b61016060035481565b6040805180820190915233815260208101849052600090610210818761061d565b50630a85bd0160e11b9695505050505050565b61022b610741565b63014c3a0081106102955760405162461bcd60e51b815260206004820152602960248201527f486f6c6420706572696f64206d7573742062652073686f72746572207468616e604482015268203336207765656b7360b81b60648201526084015b60405180910390fd5b600355565b6102a76020820182610b7a565b6040516323b872dd60e01b8152336004820152306024820152602083013560448201526001600160a01b0391909116906323b872dd90606401600060405180830381600087803b1580156102fa57600080fd5b505af115801561030e573d6000803e3d6000fd5b5050505061032c818036038101906103269190610b95565b3361061d565b50565b610337610741565b610341600061079b565b565b600061035c61035736859003850185610b95565b6107eb565b6000818152600160205260409020549091506001600160a01b0316336103b95760405162461bcd60e51b8152602060048201526012602482015271139195081b9bdd081c9959da5cdd195c995960721b604482015260640161028c565b336001600160a01b03821614806103da57506000546001600160a01b031633145b61043e5760405162461bcd60e51b815260206004820152602f60248201527f596f75206d75737420626520746865204e4654206465706f7369746f72206f7260448201526e1031b7b73a3930b1ba1037bbb732b960891b606482015260840161028c565b6000828152600260205260409020544210158061046557506000546001600160a01b031633145b6104b15760405162461bcd60e51b815260206004820152601f60248201527f596f752063616e6e6f7420776974686472617720746865204e46542079657400604482015260640161028c565b600082815260016020908152604080832080546001600160a01b031916905560029091528120556104f16104ea36869003860186610b95565b8285610842565b50505050565b6104ff610741565b600061051361035736869003860186610b95565b6000818152600160205260409020549091506001600160a01b0316156105745760405162461bcd60e51b815260206004820152601660248201527513919508185b1c9958591e481c9959da5cdd195c995960521b604482015260640161028c565b6104f161058636869003860186610b95565b8484610842565b60006105a161035736849003840184610b95565b92915050565b6105af610741565b6001600160a01b0381166106145760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b606482015260840161028c565b61032c8161079b565b306001600160a01b0382160361067f5760405162461bcd60e51b815260206004820152602160248201527f4465706f7369746f722063616e6e6f74206265207468697320636f6e747261636044820152601d60fa1b606482015260840161028c565b600061068a836107eb565b600081815260016020526040902080546001600160a01b0319166001600160a01b0385161790556003549091506106c19042610bfa565b6000828152600260208181526040808420859055600182529283902054918152825187516001600160a01b039081168252888301519282019290925291169181019190915260608101919091527fe90874aae6335c4163f647a979483c52d4fe0571af0ebcc9799ffffe99ac32db906080015b60405180910390a1505050565b6000546001600160a01b031633146103415760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161028c565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60008160000151826020015160405160200161082592919060609290921b6bffffffffffffffffffffffff19168252601482015260340190565b604051602081830303815290604052805190602001209050919050565b80156108bd5782516020840151604051632142170760e11b81523060048201526001600160a01b03858116602483015260448201929092529116906342842e0e90606401600060405180830381600087803b1580156108a057600080fd5b505af11580156108b4573d6000803e3d6000fd5b50505050610997565b8251602084015160405163095ea7b360e01b815230600482015260248101919091526001600160a01b039091169063095ea7b390604401600060405180830381600087803b15801561090e57600080fd5b505af1158015610922573d6000803e3d6000fd5b5050845160208601516040516323b872dd60e01b81523060048201526001600160a01b0387811660248301526044820192909252911692506323b872dd9150606401600060405180830381600087803b15801561097e57600080fd5b505af1158015610992573d6000803e3d6000fd5b505050505b6040805184516001600160a01b039081168252602080870151908301528416918101919091527f2eb7d7966d1f7fbd1b79e1e59740cbe1ff74f396d93e8c9e220d5070fd6abc3090606001610734565b80356001600160a01b03811681146109fe57600080fd5b919050565b600080600080600060808688031215610a1b57600080fd5b610a24866109e7565b9450610a32602087016109e7565b935060408601359250606086013567ffffffffffffffff80821115610a5657600080fd5b818801915088601f830112610a6a57600080fd5b813581811115610a7957600080fd5b896020828501011115610a8b57600080fd5b9699959850939650602001949392505050565b600060208284031215610ab057600080fd5b5035919050565b600060408284031215610ac957600080fd5b50919050565b600060408284031215610ae157600080fd5b610aeb8383610ab7565b9392505050565b803580151581146109fe57600080fd5b60008060608385031215610b1557600080fd5b610b1f8484610ab7565b9150610b2d60408401610af2565b90509250929050565b600080600060808486031215610b4b57600080fd5b610b558585610ab7565b9250610b63604085016109e7565b9150610b7160608501610af2565b90509250925092565b600060208284031215610b8c57600080fd5b610aeb826109e7565b600060408284031215610ba757600080fd5b6040516040810181811067ffffffffffffffff82111715610bd857634e487b7160e01b600052604160045260246000fd5b604052610be4836109e7565b8152602083013560208201528091505092915050565b808201808211156105a157634e487b7160e01b600052601160045260246000fdfea2646970667358221220fabb8a0887cabf100942bfead917030a10ececd4a85ad0f084602768f9299ab464736f6c63430008110033000000000000000000000000000000000000000000000000000000000000012c
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106100b45760003560e01c80638da5cb5b116100715780638da5cb5b14610189578063b72d62981461019a578063be809cbe146101ad578063bf5662f6146101c0578063f2fde38b146101d3578063f5967a2f146101e657600080fd5b8063150b7a02146100b9578063243670d7146100ea5780634df5b08c1461012b5780634f84067c146101405780635c7a2a801461016e578063715018a614610181575b600080fd5b6100cc6100c7366004610a03565b6101ef565b6040516001600160e01b031990911681526020015b60405180910390f35b6101136100f8366004610a9e565b6001602052600090815260409020546001600160a01b031681565b6040516001600160a01b0390911681526020016100e1565b61013e610139366004610a9e565b610223565b005b61016061014e366004610a9e565b60026020526000908152604090205481565b6040519081526020016100e1565b61013e61017c366004610acf565b61029a565b61013e61032f565b6000546001600160a01b0316610113565b61013e6101a8366004610b02565b610343565b61013e6101bb366004610b36565b6104f7565b6101606101ce366004610acf565b61058d565b61013e6101e1366004610b7a565b6105a7565b61016060035481565b6040805180820190915233815260208101849052600090610210818761061d565b50630a85bd0160e11b9695505050505050565b61022b610741565b63014c3a0081106102955760405162461bcd60e51b815260206004820152602960248201527f486f6c6420706572696f64206d7573742062652073686f72746572207468616e604482015268203336207765656b7360b81b60648201526084015b60405180910390fd5b600355565b6102a76020820182610b7a565b6040516323b872dd60e01b8152336004820152306024820152602083013560448201526001600160a01b0391909116906323b872dd90606401600060405180830381600087803b1580156102fa57600080fd5b505af115801561030e573d6000803e3d6000fd5b5050505061032c818036038101906103269190610b95565b3361061d565b50565b610337610741565b610341600061079b565b565b600061035c61035736859003850185610b95565b6107eb565b6000818152600160205260409020549091506001600160a01b0316336103b95760405162461bcd60e51b8152602060048201526012602482015271139195081b9bdd081c9959da5cdd195c995960721b604482015260640161028c565b336001600160a01b03821614806103da57506000546001600160a01b031633145b61043e5760405162461bcd60e51b815260206004820152602f60248201527f596f75206d75737420626520746865204e4654206465706f7369746f72206f7260448201526e1031b7b73a3930b1ba1037bbb732b960891b606482015260840161028c565b6000828152600260205260409020544210158061046557506000546001600160a01b031633145b6104b15760405162461bcd60e51b815260206004820152601f60248201527f596f752063616e6e6f7420776974686472617720746865204e46542079657400604482015260640161028c565b600082815260016020908152604080832080546001600160a01b031916905560029091528120556104f16104ea36869003860186610b95565b8285610842565b50505050565b6104ff610741565b600061051361035736869003860186610b95565b6000818152600160205260409020549091506001600160a01b0316156105745760405162461bcd60e51b815260206004820152601660248201527513919508185b1c9958591e481c9959da5cdd195c995960521b604482015260640161028c565b6104f161058636869003860186610b95565b8484610842565b60006105a161035736849003840184610b95565b92915050565b6105af610741565b6001600160a01b0381166106145760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b606482015260840161028c565b61032c8161079b565b306001600160a01b0382160361067f5760405162461bcd60e51b815260206004820152602160248201527f4465706f7369746f722063616e6e6f74206265207468697320636f6e747261636044820152601d60fa1b606482015260840161028c565b600061068a836107eb565b600081815260016020526040902080546001600160a01b0319166001600160a01b0385161790556003549091506106c19042610bfa565b6000828152600260208181526040808420859055600182529283902054918152825187516001600160a01b039081168252888301519282019290925291169181019190915260608101919091527fe90874aae6335c4163f647a979483c52d4fe0571af0ebcc9799ffffe99ac32db906080015b60405180910390a1505050565b6000546001600160a01b031633146103415760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161028c565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60008160000151826020015160405160200161082592919060609290921b6bffffffffffffffffffffffff19168252601482015260340190565b604051602081830303815290604052805190602001209050919050565b80156108bd5782516020840151604051632142170760e11b81523060048201526001600160a01b03858116602483015260448201929092529116906342842e0e90606401600060405180830381600087803b1580156108a057600080fd5b505af11580156108b4573d6000803e3d6000fd5b50505050610997565b8251602084015160405163095ea7b360e01b815230600482015260248101919091526001600160a01b039091169063095ea7b390604401600060405180830381600087803b15801561090e57600080fd5b505af1158015610922573d6000803e3d6000fd5b5050845160208601516040516323b872dd60e01b81523060048201526001600160a01b0387811660248301526044820192909252911692506323b872dd9150606401600060405180830381600087803b15801561097e57600080fd5b505af1158015610992573d6000803e3d6000fd5b505050505b6040805184516001600160a01b039081168252602080870151908301528416918101919091527f2eb7d7966d1f7fbd1b79e1e59740cbe1ff74f396d93e8c9e220d5070fd6abc3090606001610734565b80356001600160a01b03811681146109fe57600080fd5b919050565b600080600080600060808688031215610a1b57600080fd5b610a24866109e7565b9450610a32602087016109e7565b935060408601359250606086013567ffffffffffffffff80821115610a5657600080fd5b818801915088601f830112610a6a57600080fd5b813581811115610a7957600080fd5b896020828501011115610a8b57600080fd5b9699959850939650602001949392505050565b600060208284031215610ab057600080fd5b5035919050565b600060408284031215610ac957600080fd5b50919050565b600060408284031215610ae157600080fd5b610aeb8383610ab7565b9392505050565b803580151581146109fe57600080fd5b60008060608385031215610b1557600080fd5b610b1f8484610ab7565b9150610b2d60408401610af2565b90509250929050565b600080600060808486031215610b4b57600080fd5b610b558585610ab7565b9250610b63604085016109e7565b9150610b7160608501610af2565b90509250925092565b600060208284031215610b8c57600080fd5b610aeb826109e7565b600060408284031215610ba757600080fd5b6040516040810181811067ffffffffffffffff82111715610bd857634e487b7160e01b600052604160045260246000fd5b604052610be4836109e7565b8152602083013560208201528091505092915050565b808201808211156105a157634e487b7160e01b600052601160045260246000fdfea2646970667358221220fabb8a0887cabf100942bfead917030a10ececd4a85ad0f084602768f9299ab464736f6c63430008110033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000000000000000000000000000000000000000012c
-----Decoded View---------------
Arg [0] : _holdPeriod (uint256): 300
-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 000000000000000000000000000000000000000000000000000000000000012c
Deployed Bytecode Sourcemap
11483:5706:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;14598:362;;;;;;:::i;:::-;;:::i;:::-;;;-1:-1:-1;;;;;;1167:33:1;;;1149:52;;1137:2;1122:18;14598:362:0;;;;;;;;11680:46;;;;;;:::i;:::-;;;;;;;;;;;;-1:-1:-1;;;;;11680:46:0;;;;;;-1:-1:-1;;;;;1586:32:1;;;1568:51;;1556:2;1541:18;11680:46:0;1422:203:1;12923:225:0;;;;;;:::i;:::-;;:::i;:::-;;11807:46;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;1961:25:1;;;1949:2;1934:18;11807:46:0;1815:177:1;13311:175:0;;;;;;:::i;:::-;;:::i;3162:103::-;;;:::i;2514:87::-;2560:7;2587:6;-1:-1:-1;;;;;2587:6:0;2514:87;;13651:657;;;;;;:::i;:::-;;:::i;15113:373::-;;;;;;:::i;:::-;;:::i;15601:106::-;;;;;;:::i;:::-;;:::i;3420:201::-;;;;;;:::i;:::-;;:::i;11989:25::-;;;;;;14598:362;14833:24;;;;;;;;;14837:10;14833:24;;;;;;;;14756:6;;14868:26;14833:24;14889:4;14868:15;:26::i;:::-;-1:-1:-1;;;;14922:30:0;14598:362;-1:-1:-1;;;;;;14598:362:0:o;12923:225::-;2400:13;:11;:13::i;:::-;13028:8:::1;13014:11;:22;12992:113;;;::::0;-1:-1:-1;;;12992:113:0;;3825:2:1;12992:113:0::1;::::0;::::1;3807:21:1::0;3864:2;3844:18;;;3837:30;3903:34;3883:18;;;3876:62;-1:-1:-1;;;3954:18:1;;;3947:39;4003:19;;12992:113:0::1;;;;;;;;;13116:10;:24:::0;12923:225::o;13311:175::-;13372:9;;;;:3;:9;:::i;:::-;13364:71;;-1:-1:-1;;;13364:71:0;;13396:10;13364:71;;;4273:34:1;13416:4:0;4323:18:1;;;4316:43;13423:11:0;;;;4375:18:1;;;4368:34;-1:-1:-1;;;;;13364:31:0;;;;;;;4208:18:1;;13364:71:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13446:32;13462:3;13446:32;;;;;;;;;;:::i;:::-;13467:10;13446:15;:32::i;:::-;13311:175;:::o;3162:103::-;2400:13;:11;:13::i;:::-;3227:30:::1;3254:1;3227:18;:30::i;:::-;3162:103::o:0;13651:657::-;13716:12;13731;;;;;;;;13739:3;13731:12;:::i;:::-;:7;:12::i;:::-;13754:17;13774:16;;;:10;:16;;;;;;13716:27;;-1:-1:-1;;;;;;13774:16:0;13809:10;13801:55;;;;-1:-1:-1;;;13801:55:0;;5220:2:1;13801:55:0;;;5202:21:1;5259:2;5239:18;;;5232:30;-1:-1:-1;;;5278:18:1;;;5271:48;5336:18;;13801:55:0;5018:342:1;13801:55:0;13875:10;-1:-1:-1;;;;;13875:23:0;;;;:48;;-1:-1:-1;2560:7:0;2587:6;-1:-1:-1;;;;;2587:6:0;13902:10;:21;13875:48;13867:121;;;;-1:-1:-1;;;13867:121:0;;5567:2:1;13867:121:0;;;5549:21:1;5606:2;5586:18;;;5579:30;5645:34;5625:18;;;5618:62;-1:-1:-1;;;5696:18:1;;;5689:45;5751:19;;13867:121:0;5365:411:1;13867:121:0;14026:16;;;;:10;:16;;;;;;14007:15;:35;;;:60;;-1:-1:-1;2560:7:0;2587:6;-1:-1:-1;;;;;2587:6:0;14046:10;:21;14007:60;13999:117;;;;-1:-1:-1;;;13999:117:0;;5983:2:1;13999:117:0;;;5965:21:1;6022:2;6002:18;;;5995:30;6061:33;6041:18;;;6034:61;6112:18;;13999:117:0;5781:355:1;13999:117:0;14171:16;;;;:10;:16;;;;;;;;14164:23;;-1:-1:-1;;;;;;14164:23:0;;;14205:10;:16;;;;;14198:23;14267:33;;;;;;;;14279:3;14267:33;:::i;:::-;14284:9;14295:4;14267:11;:33::i;:::-;13705:603;;13651:657;;:::o;15113:373::-;2400:13;:11;:13::i;:::-;15300:12:::1;15315;;;::::0;;::::1;::::0;::::1;15323:3:::0;15315:12:::1;:::i;:::-;15374:1;15346:16:::0;;;:10:::1;:16;::::0;;;;;15300:27;;-1:-1:-1;;;;;;15346:16:0::1;:30:::0;15338:65:::1;;;::::0;-1:-1:-1;;;15338:65:0;;6343:2:1;15338:65:0::1;::::0;::::1;6325:21:1::0;6382:2;6362:18;;;6355:30;-1:-1:-1;;;6401:18:1;;;6394:52;6463:18;;15338:65:0::1;6141:346:1::0;15338:65:0::1;15450:28;;;::::0;;::::1;::::0;::::1;15462:3:::0;15450:28:::1;:::i;:::-;15467:4;15473;15450:11;:28::i;15601:106::-:0;15660:7;15687:12;;;;;;;;15695:3;15687:12;:::i;:::-;15680:19;15601:106;-1:-1:-1;;15601:106:0:o;3420:201::-;2400:13;:11;:13::i;:::-;-1:-1:-1;;;;;3509:22:0;::::1;3501:73;;;::::0;-1:-1:-1;;;3501:73:0;;6694:2:1;3501:73:0::1;::::0;::::1;6676:21:1::0;6733:2;6713:18;;;6706:30;6772:34;6752:18;;;6745:62;-1:-1:-1;;;6823:18:1;;;6816:36;6869:19;;3501:73:0::1;6492:402:1::0;3501:73:0::1;3585:28;3604:8;3585:18;:28::i;15921:430::-:0;16096:4;-1:-1:-1;;;;;16080:21:0;;;16072:67;;;;-1:-1:-1;;;16072:67:0;;7101:2:1;16072:67:0;;;7083:21:1;7140:2;7120:18;;;7113:30;7179:34;7159:18;;;7152:62;-1:-1:-1;;;7230:18:1;;;7223:31;7271:19;;16072:67:0;6899:397:1;16072:67:0;16150:12;16165;16173:3;16165:7;:12::i;:::-;16188:16;;;;:10;:16;;;;;:23;;-1:-1:-1;;;;;;16188:23:0;-1:-1:-1;;;;;16188:23:0;;;;;16259:10;;16188:16;;-1:-1:-1;16241:28:0;;:15;:28;:::i;:::-;16222:16;;;;:10;:16;;;;;;;;:47;;;16308:10;:16;;;;;;;16326;;;16295:48;;7601:12:1;;-1:-1:-1;;;;;7597:38:1;;;7585:51;;7674:16;;;7668:23;7652:14;;;7645:47;;;;16308:16:0;;7998:18:1;;;7991:60;;;;8082:2;8067:18;;8060:34;;;;16295:48:0;;7929:3:1;7914:19;16295:48:0;;;;;;;;15984:367;15921:430;;:::o;2679:132::-;2560:7;2587:6;-1:-1:-1;;;;;2587:6:0;1145:10;2743:23;2735:68;;;;-1:-1:-1;;;2735:68:0;;8307:2:1;2735:68:0;;;8289:21:1;;;8326:18;;;8319:30;8385:34;8365:18;;;8358:62;8437:18;;2735:68:0;8105:356:1;3781:191:0;3855:16;3874:6;;-1:-1:-1;;;;;3891:17:0;;;-1:-1:-1;;;;;;3891:17:0;;;;;;3924:40;;3874:6;;;;;;;3924:40;;3855:16;3924:40;3844:128;3781:191;:::o;245:139::-;292:7;355:3;:9;;;366:3;:11;;;338:40;;;;;;;;8643:2:1;8639:15;;;;-1:-1:-1;;8635:53:1;8623:66;;8714:2;8705:12;;8698:28;8751:2;8742:12;;8466:294;338:40:0;;;;;;;;;;;;;328:51;;;;;;308:72;;245:139;;;:::o;16525:661::-;16608:4;16604:540;;;16637:9;;16684:11;;;;16629:67;;-1:-1:-1;;;16629:67:0;;16673:4;16629:67;;;4273:34:1;-1:-1:-1;;;;;4343:15:1;;;4323:18;;;4316:43;4375:18;;;4368:34;;;;16629:35:0;;;;;4208:18:1;;16629:67:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;16604:540;;;17008:9;;17042:11;;;;17000:54;;-1:-1:-1;;;17000:54:0;;17035:4;17000:54;;;8939:51:1;9006:18;;;8999:34;;;;-1:-1:-1;;;;;17000:26:0;;;;;;8912:18:1;;17000:54:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;17077:9:0;;17120:11;;;;17069:63;;-1:-1:-1;;;17069:63:0;;17109:4;17069:63;;;4273:34:1;-1:-1:-1;;;;;4343:15:1;;;4323:18;;;4316:43;4375:18;;;4368:34;;;;17069:31:0;;;-1:-1:-1;17069:31:0;;-1:-1:-1;4208:18:1;;17069:63:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;16604:540;17159:19;;;7601:12:1;;-1:-1:-1;;;;;7597:38:1;;;7585:51;;7685:4;7674:16;;;7668:23;7652:14;;;7645:47;9330:32;;9310:18;;;9303:60;;;;17159:19:0;;9242:2:1;9227:18;17159:19:0;9044:325:1;14:173;82:20;;-1:-1:-1;;;;;131:31:1;;121:42;;111:70;;177:1;174;167:12;111:70;14:173;;;:::o;192:808::-;289:6;297;305;313;321;374:3;362:9;353:7;349:23;345:33;342:53;;;391:1;388;381:12;342:53;414:29;433:9;414:29;:::i;:::-;404:39;;462:38;496:2;485:9;481:18;462:38;:::i;:::-;452:48;;547:2;536:9;532:18;519:32;509:42;;602:2;591:9;587:18;574:32;625:18;666:2;658:6;655:14;652:34;;;682:1;679;672:12;652:34;720:6;709:9;705:22;695:32;;765:7;758:4;754:2;750:13;746:27;736:55;;787:1;784;777:12;736:55;827:2;814:16;853:2;845:6;842:14;839:34;;;869:1;866;859:12;839:34;914:7;909:2;900:6;896:2;892:15;888:24;885:37;882:57;;;935:1;932;925:12;882:57;192:808;;;;-1:-1:-1;192:808:1;;-1:-1:-1;966:2:1;958:11;;988:6;192:808;-1:-1:-1;;;192:808:1:o;1212:205::-;1296:6;1349:2;1337:9;1328:7;1324:23;1320:32;1317:52;;;1365:1;1362;1355:12;1317:52;-1:-1:-1;1388:23:1;;1212:205;-1:-1:-1;1212:205:1:o;1997:151::-;2053:5;2098:2;2089:6;2084:3;2080:16;2076:25;2073:45;;;2114:1;2111;2104:12;2073:45;-1:-1:-1;2136:6:1;1997:151;-1:-1:-1;1997:151:1:o;2153:227::-;2232:6;2285:2;2273:9;2264:7;2260:23;2256:32;2253:52;;;2301:1;2298;2291:12;2253:52;2324:50;2366:7;2355:9;2324:50;:::i;:::-;2314:60;2153:227;-1:-1:-1;;;2153:227:1:o;2385:160::-;2450:20;;2506:13;;2499:21;2489:32;;2479:60;;2535:1;2532;2525:12;2550:295;2635:6;2643;2696:2;2684:9;2675:7;2671:23;2667:32;2664:52;;;2712:1;2709;2702:12;2664:52;2735:50;2777:7;2766:9;2735:50;:::i;:::-;2725:60;;2804:35;2835:2;2824:9;2820:18;2804:35;:::i;:::-;2794:45;;2550:295;;;;;:::o;2850:370::-;2944:6;2952;2960;3013:3;3001:9;2992:7;2988:23;2984:33;2981:53;;;3030:1;3027;3020:12;2981:53;3053:50;3095:7;3084:9;3053:50;:::i;:::-;3043:60;;3122:38;3156:2;3145:9;3141:18;3122:38;:::i;:::-;3112:48;;3179:35;3210:2;3199:9;3195:18;3179:35;:::i;:::-;3169:45;;2850:370;;;;;:::o;3432:186::-;3491:6;3544:2;3532:9;3523:7;3519:23;3515:32;3512:52;;;3560:1;3557;3550:12;3512:52;3583:29;3602:9;3583:29;:::i;4413:600::-;4490:6;4543:2;4531:9;4522:7;4518:23;4514:32;4511:52;;;4559:1;4556;4549:12;4511:52;4592:2;4586:9;4634:2;4626:6;4622:15;4703:6;4691:10;4688:22;4667:18;4655:10;4652:34;4649:62;4646:185;;;4753:10;4748:3;4744:20;4741:1;4734:31;4788:4;4785:1;4778:15;4816:4;4813:1;4806:15;4646:185;4847:2;4840:22;4886:29;4905:9;4886:29;:::i;:::-;4878:6;4871:45;4977:2;4966:9;4962:18;4949:32;4944:2;4936:6;4932:15;4925:57;5001:6;4991:16;;;4413:600;;;;:::o;7301:222::-;7366:9;;;7387:10;;;7384:133;;;7439:10;7434:3;7430:20;7427:1;7420:31;7474:4;7471:1;7464:15;7502:4;7499:1;7492:15
Swarm Source
ipfs://fabb8a0887cabf100942bfead917030a10ececd4a85ad0f084602768f9299ab4
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
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.