Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
TokenTracker
Loading...
Loading
Contract Name:
GenerativeCollection
Compiler Version
v0.8.13+commit.abaa5c0e
Optimization Enabled:
Yes with 15000 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity >=0.8.13; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721URIStorage.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Burnable.sol"; import "@openzeppelin/contracts/security/Pausable.sol"; import "@openzeppelin/contracts/access/AccessControl.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/finance/PaymentSplitter.sol"; import "@openzeppelin/contracts/security/ReentrancyGuard.sol"; import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol"; error NotEnoughEther(); error ExceededMaxSupply(); error ExceededMaxPurchaseable(); error ExceededPresaleLimit(); error InvalidMerkleProof(); error PresaleActive(); error PresaleInactive(); /// @title Generative Collection contract with payment splitter, presale, reservation, and access control built in.abi /// @dev This contract inherits both AccessControl and Ownable. /// AccessControl is used for limiting access to the contract's functionalities. /// Ownable is used for setting the current owner of the contract making it easier to /// deal with secondary markets like OpenSea for claiming ownership and setting royalty info off-chain. contract GenerativeCollection is ERC721, ERC721URIStorage, ERC721Burnable, Pausable, AccessControl, PaymentSplitter, Ownable, ReentrancyGuard { uint256 private _tokenIdCounter = 1; uint256 private _burnCount = 0; string private _metadataBaseURI; uint256 public immutable maxSupply; uint256 public immutable maxNftPurchaseable; uint256 public immutable maxPresaleMinting; uint256 private _reserved = 100; uint256 private _mintPrice = 0.05 ether; uint256 private _numberOfPayees; bool private _isPresale = true; bytes32 public presaleMerkleRoot; mapping(address => uint256) public numClaimed; constructor( address[] memory payees, uint256[] memory shares, address owner_, string memory name, string memory symbol_, string memory baseUri, uint256 mintPrice, uint256 maxSupply_, uint256 reservedAmount, uint256 maxNftPurchaseable_, uint256 maxPresaleMinting_ ) ERC721(name, symbol_) PaymentSplitter(payees, shares) { _transferOwnership(owner_); _grantRole(DEFAULT_ADMIN_ROLE, owner_); _numberOfPayees = payees.length; _metadataBaseURI = baseUri; _mintPrice = mintPrice; maxSupply = maxSupply_; _reserved = reservedAmount; maxNftPurchaseable = maxNftPurchaseable_; maxPresaleMinting = maxPresaleMinting_; _pause(); } modifier whenPresaleActive() { if (!_isPresale) { revert PresaleInactive(); } _; } modifier whenAmountIsZero(uint256 numberOfTokens) { require(numberOfTokens != 0, "Mint amount cannot be zero"); _; } modifier whenNotExceedMaxPurchaseable(uint256 numberOfTokens) { if (numberOfTokens < 0 || numberOfTokens > maxNftPurchaseable) { revert ExceededMaxPurchaseable(); } _; } modifier whenNotExceedMaxSupply(uint256 numberOfTokens) { if ( totalSupply() + numberOfTokens > (maxSupplyWithBurnCount() - _reserved) ) { revert ExceededMaxSupply(); } _; } modifier hasEnoughEther(uint256 numberOfTokens) { if (msg.value < _mintPrice * numberOfTokens) { revert NotEnoughEther(); } _; } /// @dev Takes into account of the burnt tokens. /// This is used by etherscan to display the total supply of the NFT collection /// @return Total supply of the minted tokens function totalSupply() public view returns (uint256) { // token supply starts at 1 return _tokenIdCounter - _burnCount - 1; } function maxSupplyWithBurnCount() internal view returns (uint256) { return maxSupply - _burnCount; } /// @notice Presale mint the given number of NFTs to the msg.sender /// @param numberOfTokens The number of NFTs to be minted /// @param proof merkle proof showing that caller is on the whitelist function presaleMint(uint256 numberOfTokens, bytes32[] calldata proof) external payable { presaleMintTo(numberOfTokens, proof, msg.sender); } /// @notice Presale mint directly to another wallet address /// @dev This is used by third party service to presale mint directly to another address /// @param numberOfTokens The number of NFTs to be minted /// @param proof merkle proof showing that recipient is on the whitelist /// @param recipient Address of the target wallet to mint to function presaleMintTo( uint256 numberOfTokens, bytes32[] calldata proof, address recipient ) public payable whenPresaleActive whenNotPaused nonReentrant whenNotExceedMaxSupply(numberOfTokens) whenNotExceedMaxPurchaseable(numberOfTokens) hasEnoughEther(numberOfTokens) { numClaimed[recipient] += numberOfTokens; if (numClaimed[recipient] > maxPresaleMinting) { revert ExceededPresaleLimit(); } if ( !MerkleProof.verify( proof, presaleMerkleRoot, keccak256(abi.encodePacked(recipient)) ) ) { revert InvalidMerkleProof(); } for (uint256 i = 0; i < numberOfTokens; i++) { if (totalSupply() < maxSupplyWithBurnCount()) { _safeMint(recipient, _tokenIdCounter); // Safety: // token ID counter is never able to come close to an uint256 overflow unchecked { _tokenIdCounter++; } } } } /// @notice Mint the given number of NFTs to the msg.sender /// @param numberOfTokens The number of NFTs to be minted function mintNft(uint256 numberOfTokens) external payable { mintNftTo(numberOfTokens, msg.sender); } /// @notice Mint directly to another wallet address /// @dev This is used by third party service to mint directly to another address /// @param numberOfTokens The number of NFTs to be minted /// @param recipient Address of the target wallet to mint to function mintNftTo(uint256 numberOfTokens, address recipient) public payable nonReentrant whenNotPaused whenAmountIsZero(numberOfTokens) hasEnoughEther(numberOfTokens) whenNotExceedMaxPurchaseable(numberOfTokens) whenNotExceedMaxSupply(numberOfTokens) { if (_isPresale) { revert PresaleActive(); } for (uint256 i = 0; i < numberOfTokens; i++) { if (totalSupply() < maxSupplyWithBurnCount()) { _safeMint(recipient, _tokenIdCounter); // Safety: // token ID counter is never able to come close to an uint256 overflow unchecked { _tokenIdCounter++; } } } } /// @notice Pre-mint number of NFTs to an address. Admin only. /// @dev Mint reserved NFTs to a specified wallet. Decreases the number of available reserved amount. /// @param to Address of the target wallet to mint to /// @param numberOfTokens The number of NFTs to be minted function giveAwayNft(address to, uint256 numberOfTokens) external nonReentrant onlyRole(DEFAULT_ADMIN_ROLE) { require(numberOfTokens <= _reserved, "Exceeds reserved supply"); for (uint256 i = 0; i < numberOfTokens; i++) { if (totalSupply() < maxSupplyWithBurnCount()) { _safeMint(to, _tokenIdCounter); // Safety: // token ID counter is never able to come close to an uint256 overflow unchecked { _tokenIdCounter++; } } } _reserved -= numberOfTokens; } /// @notice Set presaleMerkleRoot. Admin only. /// @param _presaleMerkleRoot New presaleMerkleRoot function setPresaleMerkleRoot(bytes32 _presaleMerkleRoot) external onlyRole(DEFAULT_ADMIN_ROLE) { presaleMerkleRoot = _presaleMerkleRoot; } /// @notice Ends presale period to start main sale. Admin only. function endPresale() external onlyRole(DEFAULT_ADMIN_ROLE) { require(_isPresale, "Presale already ended"); _isPresale = false; } /// @return The boolean state of presale for the contract function isPresale() external view virtual returns (bool) { return _isPresale; } /// @notice Get the current mint price for minting an NFT /// @return Current mint price stored on-chain function getMintPrice() external view returns (uint256) { return _mintPrice; } /// @notice Set new mint price, override the current one. Admin only. /// @param newPrice New mint price function setMintPrice(uint256 newPrice) external onlyRole(DEFAULT_ADMIN_ROLE) { _mintPrice = newPrice; } function _baseURI() internal view override returns (string memory) { return _metadataBaseURI; } /// @notice Get the current token's base URI stored on-chain /// @return String of the current stored base URI function baseURI() external view virtual returns (string memory) { return _baseURI(); } /// @notice Set new base URI. Admin only. /// @param baseUri New string of the base URI for NFT function setBaseURI(string memory baseUri) external onlyRole(DEFAULT_ADMIN_ROLE) { _metadataBaseURI = baseUri; } /// @notice Get the current token's base URI stored on-chain /// @return String of the current stored base URI function tokenURI(uint256 tokenId) public view override(ERC721, ERC721URIStorage) returns (string memory) { return super.tokenURI(tokenId); } /// @notice Pause the contract disable minting. Admin only. function pause() external onlyRole(DEFAULT_ADMIN_ROLE) { _pause(); } /// @notice Unpause the contract to allow minting. Admin only. function unpause() external onlyRole(DEFAULT_ADMIN_ROLE) { _unpause(); } function _burn(uint256 tokenId) internal override(ERC721, ERC721URIStorage) { super._burn(tokenId); // Safety: // token ID counter is never able to come close to an uint256 overflow unchecked { _burnCount++; } } function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal override(ERC721) { super._beforeTokenTransfer(from, to, tokenId); } function supportsInterface(bytes4 interfaceId) public view override(ERC721, AccessControl) returns (bool) { return super.supportsInterface(interfaceId); } /// @notice Withdraw the contract's fund and split the payment amongst the list of payees. /// @dev Loops through all of the payees and release funding based on the payee's share function withdraw() external { for (uint256 i = 0; i < _numberOfPayees; i++) { release(payable(payee(i))); } } receive() external payable override(PaymentSplitter) { emit PaymentReceived(_msgSender(), msg.value); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (security/Pausable.sol) pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your contract. Note that they will not be pausable by * simply including this module, only once the modifiers are put in place. */ abstract contract Pausable is Context { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** * @dev Initializes the contract in unpaused state. */ constructor() { _paused = false; } /** * @dev Modifier to make a function callable only when the contract is not paused. * * Requirements: * * - The contract must not be paused. */ modifier whenNotPaused() { _requireNotPaused(); _; } /** * @dev Modifier to make a function callable only when the contract is paused. * * Requirements: * * - The contract must be paused. */ modifier whenPaused() { _requirePaused(); _; } /** * @dev Returns true if the contract is paused, and false otherwise. */ function paused() public view virtual returns (bool) { return _paused; } /** * @dev Throws if the contract is paused. */ function _requireNotPaused() internal view virtual { require(!paused(), "Pausable: paused"); } /** * @dev Throws if the contract is not paused. */ function _requirePaused() internal view virtual { require(paused(), "Pausable: not paused"); } /** * @dev Triggers stopped state. * * Requirements: * * - The contract must not be paused. */ function _pause() internal virtual whenNotPaused { _paused = true; emit Paused(_msgSender()); } /** * @dev Returns to normal state. * * Requirements: * * - The contract must be paused. */ function _unpause() internal virtual whenPaused { _paused = false; emit Unpaused(_msgSender()); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol) pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @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); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (access/AccessControl.sol) pragma solidity ^0.8.0; import "./IAccessControl.sol"; import "../utils/Context.sol"; import "../utils/Strings.sol"; import "../utils/introspection/ERC165.sol"; /** * @dev Contract module that allows children to implement role-based access * control mechanisms. This is a lightweight version that doesn't allow enumerating role * members except through off-chain means by accessing the contract event logs. Some * applications may benefit from on-chain enumerability, for those cases see * {AccessControlEnumerable}. * * Roles are referred to by their `bytes32` identifier. These should be exposed * in the external API and be unique. The best way to achieve this is by * using `public constant` hash digests: * * ``` * bytes32 public constant MY_ROLE = keccak256("MY_ROLE"); * ``` * * Roles can be used to represent a set of permissions. To restrict access to a * function call, use {hasRole}: * * ``` * function foo() public { * require(hasRole(MY_ROLE, msg.sender)); * ... * } * ``` * * Roles can be granted and revoked dynamically via the {grantRole} and * {revokeRole} functions. Each role has an associated admin role, and only * accounts that have a role's admin role can call {grantRole} and {revokeRole}. * * By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means * that only accounts with this role will be able to grant or revoke other * roles. More complex role relationships can be created by using * {_setRoleAdmin}. * * WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to * grant and revoke this role. Extra precautions should be taken to secure * accounts that have been granted it. */ abstract contract AccessControl is Context, IAccessControl, ERC165 { struct RoleData { mapping(address => bool) members; bytes32 adminRole; } mapping(bytes32 => RoleData) private _roles; bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00; /** * @dev Modifier that checks that an account has a specific role. Reverts * with a standardized message including the required role. * * The format of the revert reason is given by the following regular expression: * * /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/ * * _Available since v4.1._ */ modifier onlyRole(bytes32 role) { _checkRole(role); _; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IAccessControl).interfaceId || super.supportsInterface(interfaceId); } /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) public view virtual override returns (bool) { return _roles[role].members[account]; } /** * @dev Revert with a standard message if `_msgSender()` is missing `role`. * Overriding this function changes the behavior of the {onlyRole} modifier. * * Format of the revert message is described in {_checkRole}. * * _Available since v4.6._ */ function _checkRole(bytes32 role) internal view virtual { _checkRole(role, _msgSender()); } /** * @dev Revert with a standard message if `account` is missing `role`. * * The format of the revert reason is given by the following regular expression: * * /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/ */ function _checkRole(bytes32 role, address account) internal view virtual { if (!hasRole(role, account)) { revert( string( abi.encodePacked( "AccessControl: account ", Strings.toHexString(uint160(account), 20), " is missing role ", Strings.toHexString(uint256(role), 32) ) ) ); } } /** * @dev Returns the admin role that controls `role`. See {grantRole} and * {revokeRole}. * * To change a role's admin, use {_setRoleAdmin}. */ function getRoleAdmin(bytes32 role) public view virtual override returns (bytes32) { return _roles[role].adminRole; } /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. * * Requirements: * * - the caller must have ``role``'s admin role. * * May emit a {RoleGranted} event. */ function grantRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) { _grantRole(role, account); } /** * @dev Revokes `role` from `account`. * * If `account` had been granted `role`, emits a {RoleRevoked} event. * * Requirements: * * - the caller must have ``role``'s admin role. * * May emit a {RoleRevoked} event. */ function revokeRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) { _revokeRole(role, account); } /** * @dev Revokes `role` from the calling account. * * Roles are often managed via {grantRole} and {revokeRole}: this function's * purpose is to provide a mechanism for accounts to lose their privileges * if they are compromised (such as when a trusted device is misplaced). * * If the calling account had been revoked `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `account`. * * May emit a {RoleRevoked} event. */ function renounceRole(bytes32 role, address account) public virtual override { require(account == _msgSender(), "AccessControl: can only renounce roles for self"); _revokeRole(role, account); } /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. Note that unlike {grantRole}, this function doesn't perform any * checks on the calling account. * * May emit a {RoleGranted} event. * * [WARNING] * ==== * This function should only be called from the constructor when setting * up the initial roles for the system. * * Using this function in any other way is effectively circumventing the admin * system imposed by {AccessControl}. * ==== * * NOTE: This function is deprecated in favor of {_grantRole}. */ function _setupRole(bytes32 role, address account) internal virtual { _grantRole(role, account); } /** * @dev Sets `adminRole` as ``role``'s admin role. * * Emits a {RoleAdminChanged} event. */ function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual { bytes32 previousAdminRole = getRoleAdmin(role); _roles[role].adminRole = adminRole; emit RoleAdminChanged(role, previousAdminRole, adminRole); } /** * @dev Grants `role` to `account`. * * Internal function without access restriction. * * May emit a {RoleGranted} event. */ function _grantRole(bytes32 role, address account) internal virtual { if (!hasRole(role, account)) { _roles[role].members[account] = true; emit RoleGranted(role, account, _msgSender()); } } /** * @dev Revokes `role` from `account`. * * Internal function without access restriction. * * May emit a {RoleRevoked} event. */ function _revokeRole(bytes32 role, address account) internal virtual { if (hasRole(role, account)) { _roles[role].members[account] = false; emit RoleRevoked(role, account, _msgSender()); } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/ERC721.sol) pragma solidity ^0.8.0; import "./IERC721.sol"; import "./IERC721Receiver.sol"; import "./extensions/IERC721Metadata.sol"; import "../../utils/Address.sol"; import "../../utils/Context.sol"; import "../../utils/Strings.sol"; import "../../utils/introspection/ERC165.sol"; /** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */ contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _owners; // Mapping owner address to token count mapping(address => uint256) private _balances; // Mapping from token ID to approved address mapping(uint256 => address) private _tokenApprovals; // Mapping from owner to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; /** * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection. */ constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC721).interfaceId || interfaceId == type(IERC721Metadata).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC721-balanceOf}. */ function balanceOf(address owner) public view virtual override returns (uint256) { require(owner != address(0), "ERC721: address zero is not a valid owner"); return _balances[owner]; } /** * @dev See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view virtual override returns (address) { address owner = _owners[tokenId]; require(owner != address(0), "ERC721: invalid token ID"); return owner; } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { _requireMinted(tokenId); string memory baseURI = _baseURI(); return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : ""; } /** * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each * token will be the concatenation of the `baseURI` and the `tokenId`. Empty * by default, can be overridden in child contracts. */ function _baseURI() internal view virtual returns (string memory) { return ""; } /** * @dev See {IERC721-approve}. */ function approve(address to, uint256 tokenId) public virtual override { address owner = ERC721.ownerOf(tokenId); require(to != owner, "ERC721: approval to current owner"); require( _msgSender() == owner || isApprovedForAll(owner, _msgSender()), "ERC721: approve caller is not token owner nor approved for all" ); _approve(to, tokenId); } /** * @dev See {IERC721-getApproved}. */ function getApproved(uint256 tokenId) public view virtual override returns (address) { _requireMinted(tokenId); return _tokenApprovals[tokenId]; } /** * @dev See {IERC721-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { _setApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC721-isApprovedForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; } /** * @dev See {IERC721-transferFrom}. */ function transferFrom( address from, address to, uint256 tokenId ) public virtual override { //solhint-disable-next-line max-line-length require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: caller is not token owner nor approved"); _transfer(from, to, tokenId); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { safeTransferFrom(from, to, tokenId, ""); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory data ) public virtual override { require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: caller is not token owner nor approved"); _safeTransfer(from, to, tokenId, data); } /** * @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. * * `data` is additional data, it has no specified format and it is sent in call to `to`. * * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g. * implement alternative mechanisms to perform token transfer, such as signature-based. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeTransfer( address from, address to, uint256 tokenId, bytes memory data ) internal virtual { _transfer(from, to, tokenId); require(_checkOnERC721Received(from, to, tokenId, data), "ERC721: transfer to non ERC721Receiver implementer"); } /** * @dev Returns whether `tokenId` exists. * * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}. * * Tokens start existing when they are minted (`_mint`), * and stop existing when they are burned (`_burn`). */ function _exists(uint256 tokenId) internal view virtual returns (bool) { return _owners[tokenId] != address(0); } /** * @dev Returns whether `spender` is allowed to manage `tokenId`. * * Requirements: * * - `tokenId` must exist. */ function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { address owner = ERC721.ownerOf(tokenId); return (spender == owner || isApprovedForAll(owner, spender) || getApproved(tokenId) == spender); } /** * @dev Safely mints `tokenId` and transfers it to `to`. * * Requirements: * * - `tokenId` must not exist. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeMint(address to, uint256 tokenId) internal virtual { _safeMint(to, tokenId, ""); } /** * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is * forwarded in {IERC721Receiver-onERC721Received} to contract recipients. */ function _safeMint( address to, uint256 tokenId, bytes memory data ) internal virtual { _mint(to, tokenId); require( _checkOnERC721Received(address(0), to, tokenId, data), "ERC721: transfer to non ERC721Receiver implementer" ); } /** * @dev Mints `tokenId` and transfers it to `to`. * * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible * * Requirements: * * - `tokenId` must not exist. * - `to` cannot be the zero address. * * Emits a {Transfer} event. */ function _mint(address to, uint256 tokenId) internal virtual { require(to != address(0), "ERC721: mint to the zero address"); require(!_exists(tokenId), "ERC721: token already minted"); _beforeTokenTransfer(address(0), to, tokenId); _balances[to] += 1; _owners[tokenId] = to; emit Transfer(address(0), to, tokenId); _afterTokenTransfer(address(0), to, tokenId); } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ function _burn(uint256 tokenId) internal virtual { address owner = ERC721.ownerOf(tokenId); _beforeTokenTransfer(owner, address(0), tokenId); // Clear approvals _approve(address(0), tokenId); _balances[owner] -= 1; delete _owners[tokenId]; emit Transfer(owner, address(0), tokenId); _afterTokenTransfer(owner, address(0), tokenId); } /** * @dev Transfers `tokenId` from `from` to `to`. * As opposed to {transferFrom}, this imposes no restrictions on msg.sender. * * Requirements: * * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * * Emits a {Transfer} event. */ function _transfer( address from, address to, uint256 tokenId ) internal virtual { require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer from incorrect owner"); require(to != address(0), "ERC721: transfer to the zero address"); _beforeTokenTransfer(from, to, tokenId); // Clear approvals from the previous owner _approve(address(0), tokenId); _balances[from] -= 1; _balances[to] += 1; _owners[tokenId] = to; emit Transfer(from, to, tokenId); _afterTokenTransfer(from, to, tokenId); } /** * @dev Approve `to` to operate on `tokenId` * * Emits an {Approval} event. */ function _approve(address to, uint256 tokenId) internal virtual { _tokenApprovals[tokenId] = to; emit Approval(ERC721.ownerOf(tokenId), to, tokenId); } /** * @dev Approve `operator` to operate on all of `owner` tokens * * Emits an {ApprovalForAll} event. */ function _setApprovalForAll( address owner, address operator, bool approved ) internal virtual { require(owner != operator, "ERC721: approve to caller"); _operatorApprovals[owner][operator] = approved; emit ApprovalForAll(owner, operator, approved); } /** * @dev Reverts if the `tokenId` has not been minted yet. */ function _requireMinted(uint256 tokenId) internal view virtual { require(_exists(tokenId), "ERC721: invalid token ID"); } /** * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address. * The call is not executed if the target address is not a contract. * * @param from address representing the previous owner of the given token ID * @param to target address that will receive the tokens * @param tokenId uint256 ID of the token to be transferred * @param data bytes optional data to send along with the call * @return bool whether the call correctly returned the expected magic value */ function _checkOnERC721Received( address from, address to, uint256 tokenId, bytes memory data ) private returns (bool) { if (to.isContract()) { try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, data) returns (bytes4 retval) { return retval == IERC721Receiver.onERC721Received.selector; } catch (bytes memory reason) { if (reason.length == 0) { revert("ERC721: transfer to non ERC721Receiver implementer"); } else { /// @solidity memory-safe-assembly assembly { revert(add(32, reason), mload(reason)) } } } } else { return true; } } /** * @dev Hook that is called before any token transfer. This includes minting * and burning. * * Calling conditions: * * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be * transferred to `to`. * - When `from` is zero, `tokenId` will be minted for `to`. * - When `to` is zero, ``from``'s `tokenId` will be burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {} /** * @dev Hook that is called after any transfer of tokens. This includes * minting and burning. * * Calling conditions: * * - when `from` and `to` are both non-zero. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _afterTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {} }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/extensions/ERC721URIStorage.sol) pragma solidity ^0.8.0; import "../ERC721.sol"; /** * @dev ERC721 token with storage based token URI management. */ abstract contract ERC721URIStorage is ERC721 { using Strings for uint256; // Optional mapping for token URIs mapping(uint256 => string) private _tokenURIs; /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { _requireMinted(tokenId); string memory _tokenURI = _tokenURIs[tokenId]; string memory base = _baseURI(); // If there is no base URI, return the token URI. if (bytes(base).length == 0) { return _tokenURI; } // If both are set, concatenate the baseURI and tokenURI (via abi.encodePacked). if (bytes(_tokenURI).length > 0) { return string(abi.encodePacked(base, _tokenURI)); } return super.tokenURI(tokenId); } /** * @dev Sets `_tokenURI` as the tokenURI of `tokenId`. * * Requirements: * * - `tokenId` must exist. */ function _setTokenURI(uint256 tokenId, string memory _tokenURI) internal virtual { require(_exists(tokenId), "ERC721URIStorage: URI set of nonexistent token"); _tokenURIs[tokenId] = _tokenURI; } /** * @dev See {ERC721-_burn}. This override additionally checks to see if a * token-specific URI was set for the token, and if so, it deletes the token URI from * the storage mapping. */ function _burn(uint256 tokenId) internal virtual override { super._burn(tokenId); if (bytes(_tokenURIs[tokenId]).length != 0) { delete _tokenURIs[tokenId]; } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/extensions/ERC721Burnable.sol) pragma solidity ^0.8.0; import "../ERC721.sol"; import "../../../utils/Context.sol"; /** * @title ERC721 Burnable Token * @dev ERC721 Token that can be burned (destroyed). */ abstract contract ERC721Burnable is Context, ERC721 { /** * @dev Burns `tokenId`. See {ERC721-_burn}. * * Requirements: * * - The caller must own `tokenId` or be an approved operator. */ function burn(uint256 tokenId) public virtual { //solhint-disable-next-line max-line-length require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: caller is not token owner nor approved"); _burn(tokenId); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (security/ReentrancyGuard.sol) pragma solidity ^0.8.0; /** * @dev Contract module that helps prevent reentrant calls to a function. * * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier * available, which can be applied to functions to make sure there are no nested * (reentrant) calls to them. * * Note that because there is a single `nonReentrant` guard, functions marked as * `nonReentrant` may not call one another. This can be worked around by making * those functions `private`, and then adding `external` `nonReentrant` entry * points to them. * * TIP: If you would like to learn more about reentrancy and alternative ways * to protect against it, check out our blog post * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul]. */ abstract contract ReentrancyGuard { // Booleans are more expensive than uint256 or any type that takes up a full // word because each write operation emits an extra SLOAD to first read the // slot's contents, replace the bits taken up by the boolean, and then write // back. This is the compiler's defense against contract upgrades and // pointer aliasing, and it cannot be disabled. // The values being non-zero value makes deployment a bit more expensive, // but in exchange the refund on every call to nonReentrant will be lower in // amount. Since refunds are capped to a percentage of the total // transaction's gas, it is best to keep them low in cases like this one, to // increase the likelihood of the full refund coming into effect. uint256 private constant _NOT_ENTERED = 1; uint256 private constant _ENTERED = 2; uint256 private _status; constructor() { _status = _NOT_ENTERED; } /** * @dev Prevents a contract from calling itself, directly or indirectly. * Calling a `nonReentrant` function from another `nonReentrant` * function is not supported. It is possible to prevent this from happening * by making the `nonReentrant` function external, and making it call a * `private` function that does the actual work. */ modifier nonReentrant() { // On the first call to nonReentrant, _notEntered will be true require(_status != _ENTERED, "ReentrancyGuard: reentrant call"); // Any calls to nonReentrant after this point will fail _status = _ENTERED; _; // By storing the original value once again, a refund is triggered (see // https://eips.ethereum.org/EIPS/eip-2200) _status = _NOT_ENTERED; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (finance/PaymentSplitter.sol) pragma solidity ^0.8.0; import "../token/ERC20/utils/SafeERC20.sol"; import "../utils/Address.sol"; import "../utils/Context.sol"; /** * @title PaymentSplitter * @dev This contract allows to split Ether payments among a group of accounts. The sender does not need to be aware * that the Ether will be split in this way, since it is handled transparently by the contract. * * The split can be in equal parts or in any other arbitrary proportion. The way this is specified is by assigning each * account to a number of shares. Of all the Ether that this contract receives, each account will then be able to claim * an amount proportional to the percentage of total shares they were assigned. The distribution of shares is set at the * time of contract deployment and can't be updated thereafter. * * `PaymentSplitter` follows a _pull payment_ model. This means that payments are not automatically forwarded to the * accounts but kept in this contract, and the actual transfer is triggered as a separate step by calling the {release} * function. * * NOTE: This contract assumes that ERC20 tokens will behave similarly to native tokens (Ether). Rebasing tokens, and * tokens that apply fees during transfers, are likely to not be supported as expected. If in doubt, we encourage you * to run tests before sending real value to this contract. */ contract PaymentSplitter is Context { event PayeeAdded(address account, uint256 shares); event PaymentReleased(address to, uint256 amount); event ERC20PaymentReleased(IERC20 indexed token, address to, uint256 amount); event PaymentReceived(address from, uint256 amount); uint256 private _totalShares; uint256 private _totalReleased; mapping(address => uint256) private _shares; mapping(address => uint256) private _released; address[] private _payees; mapping(IERC20 => uint256) private _erc20TotalReleased; mapping(IERC20 => mapping(address => uint256)) private _erc20Released; /** * @dev Creates an instance of `PaymentSplitter` where each account in `payees` is assigned the number of shares at * the matching position in the `shares` array. * * All addresses in `payees` must be non-zero. Both arrays must have the same non-zero length, and there must be no * duplicates in `payees`. */ constructor(address[] memory payees, uint256[] memory shares_) payable { require(payees.length == shares_.length, "PaymentSplitter: payees and shares length mismatch"); require(payees.length > 0, "PaymentSplitter: no payees"); for (uint256 i = 0; i < payees.length; i++) { _addPayee(payees[i], shares_[i]); } } /** * @dev The Ether received will be logged with {PaymentReceived} events. Note that these events are not fully * reliable: it's possible for a contract to receive Ether without triggering this function. This only affects the * reliability of the events, and not the actual splitting of Ether. * * To learn more about this see the Solidity documentation for * https://solidity.readthedocs.io/en/latest/contracts.html#fallback-function[fallback * functions]. */ receive() external payable virtual { emit PaymentReceived(_msgSender(), msg.value); } /** * @dev Getter for the total shares held by payees. */ function totalShares() public view returns (uint256) { return _totalShares; } /** * @dev Getter for the total amount of Ether already released. */ function totalReleased() public view returns (uint256) { return _totalReleased; } /** * @dev Getter for the total amount of `token` already released. `token` should be the address of an IERC20 * contract. */ function totalReleased(IERC20 token) public view returns (uint256) { return _erc20TotalReleased[token]; } /** * @dev Getter for the amount of shares held by an account. */ function shares(address account) public view returns (uint256) { return _shares[account]; } /** * @dev Getter for the amount of Ether already released to a payee. */ function released(address account) public view returns (uint256) { return _released[account]; } /** * @dev Getter for the amount of `token` tokens already released to a payee. `token` should be the address of an * IERC20 contract. */ function released(IERC20 token, address account) public view returns (uint256) { return _erc20Released[token][account]; } /** * @dev Getter for the address of the payee number `index`. */ function payee(uint256 index) public view returns (address) { return _payees[index]; } /** * @dev Getter for the amount of payee's releasable Ether. */ function releasable(address account) public view returns (uint256) { uint256 totalReceived = address(this).balance + totalReleased(); return _pendingPayment(account, totalReceived, released(account)); } /** * @dev Getter for the amount of payee's releasable `token` tokens. `token` should be the address of an * IERC20 contract. */ function releasable(IERC20 token, address account) public view returns (uint256) { uint256 totalReceived = token.balanceOf(address(this)) + totalReleased(token); return _pendingPayment(account, totalReceived, released(token, account)); } /** * @dev Triggers a transfer to `account` of the amount of Ether they are owed, according to their percentage of the * total shares and their previous withdrawals. */ function release(address payable account) public virtual { require(_shares[account] > 0, "PaymentSplitter: account has no shares"); uint256 payment = releasable(account); require(payment != 0, "PaymentSplitter: account is not due payment"); _released[account] += payment; _totalReleased += payment; Address.sendValue(account, payment); emit PaymentReleased(account, payment); } /** * @dev Triggers a transfer to `account` of the amount of `token` tokens they are owed, according to their * percentage of the total shares and their previous withdrawals. `token` must be the address of an IERC20 * contract. */ function release(IERC20 token, address account) public virtual { require(_shares[account] > 0, "PaymentSplitter: account has no shares"); uint256 payment = releasable(token, account); require(payment != 0, "PaymentSplitter: account is not due payment"); _erc20Released[token][account] += payment; _erc20TotalReleased[token] += payment; SafeERC20.safeTransfer(token, account, payment); emit ERC20PaymentReleased(token, account, payment); } /** * @dev internal logic for computing the pending payment of an `account` given the token historical balances and * already released amounts. */ function _pendingPayment( address account, uint256 totalReceived, uint256 alreadyReleased ) private view returns (uint256) { return (totalReceived * _shares[account]) / _totalShares - alreadyReleased; } /** * @dev Add a new payee to the contract. * @param account The address of the payee to add. * @param shares_ The number of shares owned by the payee. */ function _addPayee(address account, uint256 shares_) private { require(account != address(0), "PaymentSplitter: account is the zero address"); require(shares_ > 0, "PaymentSplitter: shares are 0"); require(_shares[account] == 0, "PaymentSplitter: account already has shares"); _payees.push(account); _shares[account] = shares_; _totalShares = _totalShares + shares_; emit PayeeAdded(account, shares_); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (utils/cryptography/MerkleProof.sol) pragma solidity ^0.8.0; /** * @dev These functions deal with verification of Merkle Tree proofs. * * The proofs can be generated using the JavaScript library * https://github.com/miguelmota/merkletreejs[merkletreejs]. * Note: the hashing algorithm should be keccak256 and pair sorting should be enabled. * * See `test/utils/cryptography/MerkleProof.test.js` for some examples. * * 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. */ library MerkleProof { /** * @dev Returns true if a `leaf` can be proved to be a part of a Merkle tree * defined by `root`. For this, a `proof` must be provided, containing * sibling hashes on the branch from the leaf to the root of the tree. Each * pair of leaves and each pair of pre-images are assumed to be sorted. */ function verify( bytes32[] memory proof, bytes32 root, bytes32 leaf ) internal pure returns (bool) { return processProof(proof, leaf) == root; } /** * @dev Calldata version of {verify} * * _Available since v4.7._ */ 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. * * _Available since v4.4._ */ 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} * * _Available since v4.7._ */ 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 proved to be a part of a Merkle tree defined by * `root`, according to `proof` and `proofFlags` as described in {processMultiProof}. * * _Available since v4.7._ */ 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} * * _Available since v4.7._ */ 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 the sibling nodes in `proof`, * consuming from one or the other at each step according to the instructions given by * `proofFlags`. * * _Available since v4.7._ */ function processMultiProof( bytes32[] memory proof, bool[] memory proofFlags, bytes32[] memory leaves ) internal pure returns (bytes32 merkleRoot) { // This function rebuild 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 totalHashes = proofFlags.length; // Check proof validity. require(leavesLen + proof.length - 1 == totalHashes, "MerkleProof: invalid multiproof"); // 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 for 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) { return hashes[totalHashes - 1]; } else if (leavesLen > 0) { return leaves[0]; } else { return proof[0]; } } /** * @dev Calldata version of {processMultiProof} * * _Available since v4.7._ */ function processMultiProofCalldata( bytes32[] calldata proof, bool[] calldata proofFlags, bytes32[] memory leaves ) internal pure returns (bytes32 merkleRoot) { // This function rebuild 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 totalHashes = proofFlags.length; // Check proof validity. require(leavesLen + proof.length - 1 == totalHashes, "MerkleProof: invalid multiproof"); // 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 for 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) { return hashes[totalHashes - 1]; } else if (leavesLen > 0) { return leaves[0]; } else { return proof[0]; } } function _hashPair(bytes32 a, bytes32 b) private pure returns (bytes32) { return a < b ? _efficientHash(a, b) : _efficientHash(b, a); } 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 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; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (access/IAccessControl.sol) pragma solidity ^0.8.0; /** * @dev External interface of AccessControl declared to support ERC165 detection. */ interface IAccessControl { /** * @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole` * * `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite * {RoleAdminChanged} not being emitted signaling this. * * _Available since v3.1._ */ event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole); /** * @dev Emitted when `account` is granted `role`. * * `sender` is the account that originated the contract call, an admin role * bearer except when using {AccessControl-_setupRole}. */ event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender); /** * @dev Emitted when `account` is revoked `role`. * * `sender` is the account that originated the contract call: * - if using `revokeRole`, it is the admin role bearer * - if using `renounceRole`, it is the role bearer (i.e. `account`) */ event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender); /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) external view returns (bool); /** * @dev Returns the admin role that controls `role`. See {grantRole} and * {revokeRole}. * * To change a role's admin, use {AccessControl-_setRoleAdmin}. */ function getRoleAdmin(bytes32 role) external view returns (bytes32); /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function grantRole(bytes32 role, address account) external; /** * @dev Revokes `role` from `account`. * * If `account` had been granted `role`, emits a {RoleRevoked} event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function revokeRole(bytes32 role, address account) external; /** * @dev Revokes `role` from the calling account. * * Roles are often managed via {grantRole} and {revokeRole}: this function's * purpose is to provide a mechanism for accounts to lose their privileges * if they are compromised (such as when a trusted device is misplaced). * * If the calling account had been granted `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `account`. */ function renounceRole(bytes32 role, address account) external; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (utils/Strings.sol) pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; uint8 private constant _ADDRESS_LENGTH = 20; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } /** * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation. */ function toHexString(address addr) internal pure returns (string memory) { return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol) pragma solidity ^0.8.0; import "./IERC165.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` * * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation. */ abstract contract ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
// SPDX-License-Identifier: MIT // 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); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (utils/Address.sol) pragma solidity ^0.8.1; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== * * [IMPORTANT] * ==== * You shouldn't rely on `isContract` to protect against flash loan attacks! * * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract * constructor. * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize/address.code.length, which returns 0 // for contracts in construction, since the code is only stored at the end // of the constructor execution. return account.code.length > 0; } /** * @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://diligence.consensys.net/posts/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.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @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, it is bubbled up by this * function (like regular Solidity function calls). * * 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. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @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`. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { require(isContract(target), "Address: delegate call to non-contract"); (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason using the provided one. * * _Available since v4.3._ */ function verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) internal pure returns (bytes memory) { if (success) { return returndata; } else { // 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(errorMessage); } } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/IERC721.sol) pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.sol"; /** * @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); }
// SPDX-License-Identifier: MIT // 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); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Metadata.sol) pragma solidity ^0.8.0; import "../IERC721.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional metadata extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721Metadata is IERC721 { /** * @dev Returns the token collection name. */ function name() external view returns (string memory); /** * @dev Returns the token collection symbol. */ function symbol() external view returns (string memory); /** * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token. */ function tokenURI(uint256 tokenId) external view returns (string memory); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (token/ERC20/utils/SafeERC20.sol) pragma solidity ^0.8.0; import "../IERC20.sol"; import "../extensions/draft-IERC20Permit.sol"; import "../../../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; function safeTransfer( IERC20 token, address to, uint256 value ) internal { _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value)); } function safeTransferFrom( IERC20 token, address from, address to, uint256 value ) internal { _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value)); } /** * @dev Deprecated. This function has issues similar to the ones found in * {IERC20-approve}, and its usage is discouraged. * * Whenever possible, use {safeIncreaseAllowance} and * {safeDecreaseAllowance} instead. */ function safeApprove( IERC20 token, address spender, uint256 value ) internal { // safeApprove should only be called when setting an initial allowance, // or when resetting it to zero. To increase and decrease it, use // 'safeIncreaseAllowance' and 'safeDecreaseAllowance' require( (value == 0) || (token.allowance(address(this), spender) == 0), "SafeERC20: approve from non-zero to non-zero allowance" ); _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value)); } function safeIncreaseAllowance( IERC20 token, address spender, uint256 value ) internal { uint256 newAllowance = token.allowance(address(this), spender) + value; _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } function safeDecreaseAllowance( IERC20 token, address spender, uint256 value ) internal { unchecked { uint256 oldAllowance = token.allowance(address(this), spender); require(oldAllowance >= value, "SafeERC20: decreased allowance below zero"); uint256 newAllowance = oldAllowance - value; _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } } function safePermit( IERC20Permit token, address owner, address spender, uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s ) internal { uint256 nonceBefore = token.nonces(owner); token.permit(owner, spender, value, deadline, v, r, s); uint256 nonceAfter = token.nonces(owner); require(nonceAfter == nonceBefore + 1, "SafeERC20: permit did not succeed"); } /** * @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, "SafeERC20: low-level call failed"); if (returndata.length > 0) { // Return data is optional require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed"); } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol) pragma solidity ^0.8.0; /** * @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 amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `to`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address to, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an {Approval} event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `from` to `to` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 amount ) external returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/draft-IERC20Permit.sol) pragma solidity ^0.8.0; /** * @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. */ 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]. */ 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); }
{ "viaIR": true, "optimizer": { "enabled": true, "runs": 15000 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address[]","name":"payees","type":"address[]"},{"internalType":"uint256[]","name":"shares","type":"uint256[]"},{"internalType":"address","name":"owner_","type":"address"},{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"symbol_","type":"string"},{"internalType":"string","name":"baseUri","type":"string"},{"internalType":"uint256","name":"mintPrice","type":"uint256"},{"internalType":"uint256","name":"maxSupply_","type":"uint256"},{"internalType":"uint256","name":"reservedAmount","type":"uint256"},{"internalType":"uint256","name":"maxNftPurchaseable_","type":"uint256"},{"internalType":"uint256","name":"maxPresaleMinting_","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ExceededMaxPurchaseable","type":"error"},{"inputs":[],"name":"ExceededMaxSupply","type":"error"},{"inputs":[],"name":"ExceededPresaleLimit","type":"error"},{"inputs":[],"name":"InvalidMerkleProof","type":"error"},{"inputs":[],"name":"NotEnoughEther","type":"error"},{"inputs":[],"name":"PresaleActive","type":"error"},{"inputs":[],"name":"PresaleInactive","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"contract IERC20","name":"token","type":"address"},{"indexed":false,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ERC20PaymentReleased","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":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"shares","type":"uint256"}],"name":"PayeeAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"PaymentReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"PaymentReleased","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"baseURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"endPresale","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMintPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"numberOfTokens","type":"uint256"}],"name":"giveAwayNft","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isPresale","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxNftPurchaseable","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxPresaleMinting","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"numberOfTokens","type":"uint256"}],"name":"mintNft","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"numberOfTokens","type":"uint256"},{"internalType":"address","name":"recipient","type":"address"}],"name":"mintNftTo","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"numClaimed","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"payee","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"presaleMerkleRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"numberOfTokens","type":"uint256"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"presaleMint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"numberOfTokens","type":"uint256"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"},{"internalType":"address","name":"recipient","type":"address"}],"name":"presaleMintTo","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"releasable","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"token","type":"address"},{"internalType":"address","name":"account","type":"address"}],"name":"releasable","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address payable","name":"account","type":"address"}],"name":"release","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"token","type":"address"},{"internalType":"address","name":"account","type":"address"}],"name":"release","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"token","type":"address"},{"internalType":"address","name":"account","type":"address"}],"name":"released","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"released","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"baseUri","type":"string"}],"name":"setBaseURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"newPrice","type":"uint256"}],"name":"setMintPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_presaleMerkleRoot","type":"bytes32"}],"name":"setPresaleMerkleRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"shares","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"token","type":"address"}],"name":"totalReleased","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalReleased","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalShares","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}]
Contract Creation Code
60e06040523462000157576200532e803803806200001d8162000173565b92833981019061016081830312620001575780516001600160401b03919082811162000157578362000051918301620001e7565b9160208201518181116200015757846200006d91840162000254565b906200007c60408401620001d2565b90606084015181811162000157578662000098918601620002b1565b906080850151818111620001575787620000b4918701620002b1565b9060a08601519081116200015757620000fb97620000d4918701620002b1565b9060c08601519260e087015194610100880151966101406101208a01519901519962000695565b604051614549908162000de58239608051818181611fa701526140d3015260a0518181816109500152818161187d01528181611fe3015281816121240152612415015260c051818181611ea20152818161218901526124b00152f35b600080fd5b50634e487b7160e01b600052604160045260246000fd5b6040519190601f01601f191682016001600160401b038111838210176200019957604052565b620001a36200015c565b604052565b6020906001600160401b038111620001c2575b60051b0190565b620001cc6200015c565b620001bb565b51906001600160a01b03821682036200015757565b9080601f8301121562000157578151906200020c6200020683620001a8565b62000173565b9182938184526020808095019260051b82010192831162000157578301905b8282106200023a575050505090565b8380916200024884620001d2565b8152019101906200022b565b9080601f830112156200015757815190620002736200020683620001a8565b9182938184526020808095019260051b82010192831162000157578301905b828210620002a1575050505090565b8151815290830190830162000292565b81601f8201121562000157578051906001600160401b03821162000335575b602090620002e7601f8401601f1916830162000173565b93838552828483010111620001575782906000905b838383106200031c575050116200031257505090565b6000918301015290565b81935082819392010151828288010152018391620002fc565b6200033f6200015c565b620002d0565b90600182811c9216801562000377575b60208310146200036157565b634e487b7160e01b600052602260045260246000fd5b91607f169162000355565b601f81116200038f575050565b60009081805260208220906020601f850160051c83019410620003cf575b601f0160051c01915b828110620003c357505050565b818155600101620003b6565b9092508290620003ad565b90601f8211620003e8575050565b60019160009083825260208220906020601f850160051c830194106200042b575b601f0160051c01915b828110620004205750505050565b818155830162000412565b909250829062000409565b601f811162000443575050565b6000906014825260208220906020601f850160051c8301941062000484575b601f0160051c01915b8281106200047857505050565b8181556001016200046b565b909250829062000462565b80519091906001600160401b03811162000581575b600190620004be81620004b8845462000345565b620003da565b602080601f8311600114620004fc575081929394600092620004f0575b5050600019600383901b1c191690821b179055565b015190503880620004db565b6001600052601f198316959091907fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf6926000905b8882106200056957505083859697106200054f575b505050811b019055565b015160001960f88460031b161c1916905538808062000545565b80878596829496860151815501950193019062000530565b6200058b6200015c565b620004a4565b80519091906001600160401b03811162000685575b620005be81620005b860145462000345565b62000436565b602080601f8311600114620005fd5750819293600092620005f1575b50508160011b916000199060031b1c191617601455565b015190503880620005da565b6014600052601f198316949091907fce6d7b5282bd9a3661ae061feed1dbda4e52ab073b1f9285be6e155d9c38d4ec926000905b8782106200066c57505083600195961062000652575b505050811b01601455565b015160001960f88460031b161c1916905538808062000647565b8060018596829496860151815501950193019062000631565b6200068f6200015c565b620005a6565b9895929a979491999693909a80519160018060401b038311620008d9575b600092620006cd81620006c7865462000345565b62000382565b602080601f83116001146200084757508190620007069486926200083b575b50508160011b916000199060031b1c19161783556200048f565b6200071660ff1960075416600755565b6200072589518c5114620008e9565b620007338951151562000951565b8851811015620007855780620007798c62000771836200076a6200075d8f976200077f98620009eb565b516001600160a01b031690565b92620009eb565b519062000c50565b620009b5565b62000733565b5062000829969950620008166200081c92939598620008106200082196989b620007af3362000aba565b620007ba6001601155565b620007c56001601255565b620007d06000601355565b620007db6064601555565b620007ec66b1a2bc2ec50000601655565b620007ff600160ff196018541617601855565b6200080a8162000aba565b62000a11565b51601755565b62000591565b601655565b608052601555565b60a05260c0526200083962000d69565b565b015190503880620006ec565b600080529293919291601f1984167f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e5639387905b828210620008c05750509160019391856200070697969410620008a6575b505050811b0183556200048f565b015160001960f88460031b161c1916905538808062000898565b806001869782949787015181550196019401906200087a565b620008e36200015c565b620006b3565b15620008f157565b60405162461bcd60e51b815260206004820152603260248201527f5061796d656e7453706c69747465723a2070617965657320616e6420736861726044820152710cae640d8cadccee8d040dad2e6dac2e8c6d60731b6064820152608490fd5b156200095957565b60405162461bcd60e51b815260206004820152601a60248201527f5061796d656e7453706c69747465723a206e6f207061796565730000000000006044820152606490fd5b50634e487b7160e01b600052601160045260246000fd5b6001906000198114620009c6570190565b620009d06200099e565b0190565b50634e487b7160e01b600052603260045260246000fd5b602091815181101562000a01575b60051b010190565b62000a0b620009d4565b620009f9565b6001600160a01b03811660009081527f5eff886ea0ce6ca488a3d6e336d6c0f75f46d19b42c06ce5ee98e42c96d256c7602052604081205460ff161562000a56575050565b8080526008602090815260408083206001600160a01b038516600090815292529020805460ff1916600117905560405133926001600160a01b031691907f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d908290a4565b601080546001600160a01b039283166001600160a01b031982168117909255604051919216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3565b1562000b1057565b60405162461bcd60e51b815260206004820152601d60248201527f5061796d656e7453706c69747465723a207368617265732061726520300000006044820152606490fd5b1562000b5d57565b60405162461bcd60e51b815260206004820152602b60248201527f5061796d656e7453706c69747465723a206163636f756e7420616c726561647960448201526a206861732073686172657360a81b6064820152608490fd5b600d546801000000000000000081101562000c33575b6001810180600d5581101562000c23575b600d6000527fd7b6990105719101dabeb77144f2a3385c8033acd3af97e9423a695e81ad1eb50180546001600160a01b0319166001600160a01b03909216919091179055565b62000c2d620009d4565b62000bdd565b62000c3d6200015c565b62000bcc565b81198111620009c6570190565b906001600160a01b0382161562000d0f577f40c340f65e17194d14ddddb073d3c9f888e3cb52b5aae0c6c7706b4fbc905fac9162000c9082151562000b08565b6001600160a01b0381166000908152600b6020526040902062000cb590541562000b55565b62000cc08162000bb6565b6001600160a01b0381166000908152600b6020526040902082905562000cf262000ced8360095462000c43565b600955565b604080516001600160a01b039290921682526020820192909252a1565b60405162461bcd60e51b815260206004820152602c60248201527f5061796d656e7453706c69747465723a206163636f756e74206973207468652060448201526b7a65726f206164647265737360a01b6064820152608490fd5b60075460ff811662000dac5760019060ff1916176007557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586020604051338152a1565b60405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606490fdfe60806040526004361015610023575b361561001957600080fd5b6100216144db565b005b60003560e01c806301ffc9a71461048357806306fdde031461047a578063074cba6b14610471578063081812fc14610468578063095ea7b31461045f5780630d730acc1461045657806318160ddd1461044d578063191655871461044457806322212e2b1461043b57806323b872dd14610432578063248a9ca31461042957806328d7b276146104205780632f2ff15d1461041757806336568abe1461040e5780633a98ef39146104055780633ccfd60b146103fc5780633f4ba83a146103f3578063406072a9146103ea57806342842e0e146103e157806342966c68146103d857806348b75044146103cf5780634df6e322146103c657806355f804b3146103bd5780635c975abb146103b45780636352211e146103ab5780636c0360eb146103a257806370a0823114610399578063715018a6146103905780637aabccb1146103875780638456cb591461037e5780638b83209b146103755780638da5cb5b1461036c57806391d148541461036357806395364a841461035a57806395d89b41146103515780639852595c14610348578063a217fddf1461033f578063a22cb46514610336578063a3f8eace1461032d578063a43be57b14610324578063a7f93ebd1461031b578063b88d4fde14610312578063bfdf019d14610309578063c45ac05014610300578063c87b56dd146102f7578063ce7c2ac2146102ee578063d547741f146102e5578063d5abeb01146102dc578063d70170ee146102d3578063d79779b2146102ca578063e33b7de3146102c1578063e3e1e8ef146102b8578063e922d7ec146102af578063e985e9c5146102a6578063f2fde38b1461029d5763f4a0a5280361000e576102986127f5565b61000e565b506102986126ec565b50610298612673565b50610298612388565b506102986120a2565b50610298612052565b50610298612006565b50610298611fca565b50610298611f8e565b50610298611f4b565b50610298611eff565b50610298611edf565b50610298611ec5565b50610298611e89565b50610298611e20565b50610298611e01565b50610298611d8e565b50610298611d66565b50610298611c5a565b50610298611c33565b50610298611be7565b50610298611b41565b50610298611b1d565b50610298611ab8565b50610298611a83565b50610298611a64565b50610298611a09565b50610298611827565b506102986117a2565b506102986116dc565b506102986116ab565b5061029861168c565b50610298611668565b50610298611512565b506102986112e7565b5061029861109f565b50610298610f70565b50610298610f47565b50610298610ee2565b50610298610e20565b50610298610dcc565b50610298610dad565b50610298610cfc565b50610298610bfd565b50610298610bdb565b50610298610bab565b50610298610b81565b50610298610b36565b50610298610b10565b50610298610aec565b50610298610908565b506102986107cf565b50610298610792565b50610298610746565b5061029861064d565b506102986104bb565b7fffffffff000000000000000000000000000000000000000000000000000000008116036104b657565b600080fd5b50346104b65760206003193601126104b65760207fffffffff000000000000000000000000000000000000000000000000000000006004356104fc8161048c565b167f7965db0b000000000000000000000000000000000000000000000000000000008114908115610533575b506040519015158152f35b7f80ac58cd00000000000000000000000000000000000000000000000000000000811491508115610597575b811561056d575b5038610528565b7f01ffc9a70000000000000000000000000000000000000000000000000000000091501438610566565b7f5b5e139f000000000000000000000000000000000000000000000000000000008114915061055f565b918091926000905b8282106105e15750116105da575050565b6000910152565b915080602091830151818601520182916105c9565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f602093610632815180928187528780880191016105c1565b0116010190565b90602061064a9281815201906105f6565b90565b50346104b6576000806003193601126107255760405190808054610670816132ef565b8085529160019180831690811561070457506001146106aa575b6106a68561069a81870382611451565b60405191829182610639565b0390f35b80809450527f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e5635b8284106106ec57505050810160200161069a826106a661068a565b805460208587018101919091529093019281016106d1565b60ff19166020870152505060408401925061069a91508390506106a661068a565b80fd5b73ffffffffffffffffffffffffffffffffffffffff8116036104b657565b50346104b65760206003193601126104b65773ffffffffffffffffffffffffffffffffffffffff60043561077981610728565b16600052601a6020526020604060002054604051908152f35b50346104b65760206003193601126104b65760206107b160043561346d565b73ffffffffffffffffffffffffffffffffffffffff60405191168152f35b50346104b65760406003193601126104b6576004356107ed81610728565b6024356107f9816132c0565b9173ffffffffffffffffffffffffffffffffffffffff808416809183161461089e5761002193610833913314908115610838575b506133fc565b6138f6565b61089891506108919061086c339173ffffffffffffffffffffffffffffffffffffffff166000526005602052604060002090565b9073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b5460ff1690565b3861082d565b608460405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560448201527f72000000000000000000000000000000000000000000000000000000000000006064820152fd5b5060206003193601126104b657600480359061092960026011541415613df8565b6002601155610936613eb8565b8115610aa85761094882601654613135565b3410610a80577f00000000000000000000000000000000000000000000000000000000000000008211610a585761098682610981613dcc565b612d6e565b61098e6140ce565b60155490818110610a4b575b0310610a235760ff601854166109fb575060005b8181106109bf576100216001601155565b6109dd906109cb613dcc565b6109d36140ce565b116109e257613ea8565b6109ae565b60126109ef815433613f08565b60018154019055613ea8565b6040517f6e2e8798000000000000000000000000000000000000000000000000000000008152fd5b6040517ffb88d215000000000000000000000000000000000000000000000000000000008152fd5b610a53612ceb565b61099a565b6040517fb637d13b000000000000000000000000000000000000000000000000000000008152fd5b6040517f8a0d3779000000000000000000000000000000000000000000000000000000008152fd5b60649060206040519162461bcd60e51b8352820152601a60248201527f4d696e7420616d6f756e742063616e6e6f74206265207a65726f0000000000006044820152fd5b50346104b65760006003193601126104b6576020610b08613dcc565b604051908152f35b50346104b65760206003193601126104b657610021600435610b3181610728565b612fac565b50346104b65760006003193601126104b6576020601954604051908152f35b60031960609101126104b657600435610b6d81610728565b90602435610b7a81610728565b9060443590565b50346104b657610021610b9336610b55565b91610ba6610ba184336135d3565b6134c9565b6136de565b50346104b65760206003193601126104b65760043560005260086020526020600160406000200154604051908152f35b50346104b65760206003193601126104b657610bf5612817565b600435601955005b50346104b6576040806003193601126104b65760043590602435610c2081610728565b6000928084526008602052610c3a60018486200154612a4e565b808452600860205260ff610c70838587209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b541615610c7c57505051f35b8084526008602052610cb0828486209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b600160ff1982541617905573ffffffffffffffffffffffffffffffffffffffff339216907f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d858551a451f35b50346104b65760406003193601126104b657602435610d1a81610728565b3373ffffffffffffffffffffffffffffffffffffffff821603610d435761002190600435612b38565b608460405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201527f20726f6c657320666f722073656c6600000000000000000000000000000000006064820152fd5b50346104b65760006003193601126104b6576020600954604051908152f35b50346104b65760006003193601126104b65760005b6017548110156100215780610e1673ffffffffffffffffffffffffffffffffffffffff610e10610e1b94612c91565b16612fac565b613ea8565b610de1565b50346104b65760006003193601126104b657610e3a612984565b60075460ff811615610e795760ff19166007557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa6020604051338152a1005b606460405162461bcd60e51b815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152fd5b60031960409101126104b657600435610ed581610728565b9060243561064a81610728565b50346104b6576020610f3e73ffffffffffffffffffffffffffffffffffffffff610f0b36610ebd565b9116600052600f835260406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b50346104b657610021610f5936610b55565b9060405192610f678461140c565b6000845261353a565b50346104b65760206003193601126104b657600435610f92610ba182336135d3565b73ffffffffffffffffffffffffffffffffffffffff610fb0826132c0565b610fb983613879565b16908060008381948252600360205260408220600019815460018110611092575b0190558282526002602052604082207fffffffffffffffffffffffff000000000000000000000000000000000000000081541690557fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef82604051a461105161104c826000526006602052604060002090565b614485565b611070575b5061106b61106660135460010190565b601355565b604051f35b61108761108c916000526006602052604060002090565b61448f565b38611056565b61109a612ceb565b610fda565b50346104b6576110ae36610ebd565b9073ffffffffffffffffffffffffffffffffffffffff916000918382168352602093600b85526040926110e5848620541515612eca565b6111676110f28285612db6565b926110fe841515612f3b565b841693848752600f8852611134838789209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61113f858254612d6e565b905573ffffffffffffffffffffffffffffffffffffffff16600052600e602052604060002090565b611172838254612d6e565b905583517fa9059cbb0000000000000000000000000000000000000000000000000000000087820190815273ffffffffffffffffffffffffffffffffffffffff83166024830152604480830185905282529096906111d1606489611451565b8551976111dd89611435565b8289527f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564838a0152853b156112a45797878061124c937f3be5b7a71e84ed12875d241991c70855ac5817d847039e17a9d895c1ceb0f18a98999a9b5190828b5af1611246613a1e565b90613c09565b80519081611284575b5050855173ffffffffffffffffffffffffffffffffffffffff929092168252506020810191909152604090a251f35b8261129c936112979383010191016131ef565b613204565b388080611255565b60648388519062461bcd60e51b82526004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152fd5b50346104b65760406003193601126104b65760043561130581610728565b6024359061131860026011541415613df8565b6002601155611325612817565b60155482116113985760005b8281106113565761134c61134784601554613164565b601555565b6100216001601155565b61137490611362613dcc565b61136a6140ce565b1161137957613ea8565b611331565b610e16611393601261138c815487613f08565b5460010190565b601255565b606460405162461bcd60e51b815260206004820152601760248201527f4578636565647320726573657276656420737570706c790000000000000000006044820152fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6020810190811067ffffffffffffffff82111761142857604052565b6114306113dc565b604052565b6040810190811067ffffffffffffffff82111761142857604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761142857604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff81116114ce575b01160190565b6114d66113dc565b6114c8565b9291926114e782611492565b916114f56040519384611451565b8294818452818301116104b6578281602093846000960137010152565b50346104b6576020806003193601126104b65767ffffffffffffffff6004358181116104b657366023820112156104b6576115579036906024816004013591016114db565b91611560612817565b825191821161165b575b61157e826115796014546132ef565b614114565b80601f83116001146115b6575081926000926115ab575b50506000198260011b9260031b1c191617601455005b015190503880611595565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe083169361160760146000527fce6d7b5282bd9a3661ae061feed1dbda4e52ab073b1f9285be6e155d9c38d4ec90565b926000905b868210611643575050836001951061162a575b505050811b01601455005b015160001960f88460031b161c1916905538808061161f565b8060018596829496860151815501950193019061160c565b6116636113dc565b61156a565b50346104b65760006003193601126104b657602060ff600754166040519015158152f35b50346104b65760206003193601126104b65760206107b16004356132c0565b50346104b65760006003193601126104b6576106a66116c8613342565b6040519182916020835260208301906105f6565b50346104b65760206003193601126104b65773ffffffffffffffffffffffffffffffffffffffff60043561170f81610728565b1680156117385760005260036020526106a6604060002054604051918291829190602083019252565b608460405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f74206120766160448201527f6c6964206f776e657200000000000000000000000000000000000000000000006064820152fd5b50346104b657600080600319360112610725576117bd612bfc565b6010547fffffffffffffffffffffffff000000000000000000000000000000000000000081166010558173ffffffffffffffffffffffffffffffffffffffff60405192167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08284a3f35b506040806003193601126104b65760048035906024359061184782610728565b61185660026011541415613df8565b6002601155611863613eb8565b82156119c65761187583601654613135565b341061199f577f00000000000000000000000000000000000000000000000000000000000000008311611978576118ae83610981613dcc565b6118b66140ce565b6015549081811061196b575b03106119445760ff6018541661191d575060005b8281106118ed576000846118ea6001601155565b51f35b61190b906118f9613dcc565b6119016140ce565b1161191057613ea8565b6118d6565b60126109ef815485613f08565b83517f6e2e8798000000000000000000000000000000000000000000000000000000008152fd5b83517ffb88d215000000000000000000000000000000000000000000000000000000008152fd5b611973612ceb565b6118c2565b83517fb637d13b000000000000000000000000000000000000000000000000000000008152fd5b83517f8a0d3779000000000000000000000000000000000000000000000000000000008152fd5b606490602085519162461bcd60e51b8352820152601a60248201527f4d696e7420616d6f756e742063616e6e6f74206265207a65726f0000000000006044820152fd5b50346104b65760006003193601126104b657611a23612984565b611a2b613eb8565b600160ff1960075416176007557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586020604051338152a1005b50346104b65760206003193601126104b65760206107b1600435612c91565b50346104b65760006003193601126104b657602073ffffffffffffffffffffffffffffffffffffffff60105416604051908152f35b50346104b65760406003193601126104b657602060ff611b11602435611add81610728565b6004356000526008845260406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54166040519015158152f35b50346104b65760006003193601126104b657602060ff601854166040519015158152f35b50346104b6576000806003193601126107255760405190806001805491611b67836132ef565b808652928281169081156107045750600114611b8d576106a68561069a81870382611451565b92508083527fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf65b828410611bcf57505050810160200161069a826106a661068a565b80546020858701810191909152909301928101611bb4565b50346104b65760206003193601126104b65773ffffffffffffffffffffffffffffffffffffffff600435611c1a81610728565b16600052600c6020526020604060002054604051908152f35b50346104b65760006003193601126104b657602060405160008152f35b801515036104b657565b50346104b65760406003193601126104b657600435611c7881610728565b602435611c8481611c50565b73ffffffffffffffffffffffffffffffffffffffff821691823314611d225781611cde611cf09233600052600560205260406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b9060ff60ff1983541691151516179055565b604051901515815233907f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3190602090a3005b606460405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152fd5b50346104b65760206003193601126104b6576020610b08600435611d8981610728565b612d7a565b50346104b65760006003193601126104b657611da8612984565b60185460ff811615611dbd5760ff1916601855005b606460405162461bcd60e51b815260206004820152601560248201527f50726573616c6520616c726561647920656e64656400000000000000000000006044820152fd5b50346104b65760006003193601126104b6576020601654604051908152f35b50346104b65760806003193601126104b657600435611e3e81610728565b602435611e4a81610728565b6064359167ffffffffffffffff83116104b657366023840112156104b657611e7f6100219336906024816004013591016114db565b916044359161353a565b50346104b65760006003193601126104b65760206040517f00000000000000000000000000000000000000000000000000000000000000008152f35b50346104b6576020610b08611ed936610ebd565b90612db6565b50346104b65760206003193601126104b6576106a66116c8600435614175565b50346104b65760206003193601126104b65773ffffffffffffffffffffffffffffffffffffffff600435611f3281610728565b16600052600b6020526020604060002054604051908152f35b50346104b65760406003193601126104b657610021602435600435611f6f82610728565b806000526008602052611f89600160406000200154612a4e565b612b38565b50346104b65760006003193601126104b65760206040517f00000000000000000000000000000000000000000000000000000000000000008152f35b50346104b65760006003193601126104b65760206040517f00000000000000000000000000000000000000000000000000000000000000008152f35b50346104b65760206003193601126104b65773ffffffffffffffffffffffffffffffffffffffff60043561203981610728565b16600052600e6020526020604060002054604051908152f35b50346104b65760006003193601126104b6576020600a54604051908152f35b9181601f840112156104b65782359167ffffffffffffffff83116104b6576020808501948460051b0101116104b657565b506040806003193601126104b657600480359060243567ffffffffffffffff81116104b6576120d49036908301612071565b9060ff6018541615612360576120e8613eb8565b6120f760026011541415613df8565b600260115561210884610981613dcc565b6121106140ce565b60155490818110612353575b031061232b577f000000000000000000000000000000000000000000000000000000000000000084116123035761215584601654613135565b34106122db57336000908152601a60205260409020612175858254612d6e565b9055336000908152601a60205260409020547f0000000000000000000000000000000000000000000000000000000000000000106122b35761223a91612236916122316019549188516020810190612226816121fa33857fffffffffffffffffffffffffffffffffffffffff00000000000000000000000060149260601b1681520190565b037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08101835282611451565b519020933691613e43565b614074565b1590565b61228c575060005b818110612256576000836118ea6001601155565b61227490612262613dcc565b61226a6140ce565b1161227957613ea8565b612242565b610e16611393601261138c815433613f08565b82517fb05e92fa000000000000000000000000000000000000000000000000000000008152fd5b8285517f2d3e8402000000000000000000000000000000000000000000000000000000008152fd5b8285517f8a0d3779000000000000000000000000000000000000000000000000000000008152fd5b8285517fb637d13b000000000000000000000000000000000000000000000000000000008152fd5b8285517ffb88d215000000000000000000000000000000000000000000000000000000008152fd5b61235b612ceb565b61211c565b8285517f35c33e81000000000000000000000000000000000000000000000000000000008152fd5b5060606003193601126104b6576004803560243567ffffffffffffffff81116104b6576123b89036908401612071565b60443593916123c685610728565b60ff601854161561264a576123d9613eb8565b6123e860026011541415613df8565b60026011556123f984610981613dcc565b6124016140ce565b6015549081811061263d575b0310612614577f000000000000000000000000000000000000000000000000000000000000000084116125eb5761244684601654613135565b34106125c2576124768573ffffffffffffffffffffffffffffffffffffffff16600052601a602052604060002090565b612481858254612d6e565b90556124ad8573ffffffffffffffffffffffffffffffffffffffff16600052601a602052604060002090565b547f000000000000000000000000000000000000000000000000000000000000000010612599576125229161223691612231601954916040516020810190612226816121fa8d857fffffffffffffffffffffffffffffffffffffffff00000000000000000000000060149260601b1681520190565b612571575060005b81811061253b576100216001601155565b61255990612547613dcc565b61254f6140ce565b1161255e57613ea8565b61252a565b610e16611393601261138c815488613f08565b6040517fb05e92fa000000000000000000000000000000000000000000000000000000008152fd5b826040517f2d3e8402000000000000000000000000000000000000000000000000000000008152fd5b826040517f8a0d3779000000000000000000000000000000000000000000000000000000008152fd5b826040517fb637d13b000000000000000000000000000000000000000000000000000000008152fd5b826040517ffb88d215000000000000000000000000000000000000000000000000000000008152fd5b612645612ceb565b61240d565b826040517f35c33e81000000000000000000000000000000000000000000000000000000008152fd5b50346104b65760406003193601126104b657602060ff611b1160043561269881610728565b73ffffffffffffffffffffffffffffffffffffffff602435916126ba83610728565b166000526005845260406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b50346104b65760206003193601126104b65760043561270a81610728565b612712612bfc565b73ffffffffffffffffffffffffffffffffffffffff80911690811561278b5760009160105491817fffffffffffffffffffffffff000000000000000000000000000000000000000084161760105560405192167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08484a3f35b608460405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152fd5b50346104b65760206003193601126104b65761280f612817565b600435601655005b3360009081527f5eff886ea0ce6ca488a3d6e336d6c0f75f46d19b42c06ce5ee98e42c96d256c7602052604090205460ff161561285057565b61285933613d22565b6000612863613c49565b90603061286f83613c83565b53607861287b83613c99565b5360415b6001811161292957612925604861290d866121fa8761289e8815613cd7565b6040519485937f416363657373436f6e74726f6c3a206163636f756e742000000000000000000060208601526128de8151809260206037890191016105c1565b84017f206973206d697373696e6720726f6c652000000000000000000000000000000060378201520190612b21565b60405191829162461bcd60e51b835260048301610639565b0390fd5b90807f3031323334353637383961626364656600000000000000000000000000000000600f61297293166010811015612977575b1a6129688486613caa565b5360041c91613cc9565b61287f565b61297f612c61565b61295d565b3360009081527f5eff886ea0ce6ca488a3d6e336d6c0f75f46d19b42c06ce5ee98e42c96d256c7602052604090205460ff16156129bd57565b6129c633613d22565b60006129d0613c49565b9060306129dc83613c83565b5360786129e883613c99565b5360415b60018111612a0b57612925604861290d866121fa8761289e8815613cd7565b90807f3031323334353637383961626364656600000000000000000000000000000000600f612a4993166010811015612977571a6129688486613caa565b6129ec565b80600052600860205260ff612a873360406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b541615612a915750565b612a9a33613d22565b90612aa3613c49565b906030612aaf83613c83565b536078612abb83613c99565b5360415b60018111612ade57612925604861290d866121fa8761289e8815613cd7565b90807f3031323334353637383961626364656600000000000000000000000000000000600f612b1c93166010811015612977571a6129688486613caa565b612abf565b90612b34602092828151948592016105c1565b0190565b80600052600860205260ff612b718360406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b5416612b7b575050565b806000526008602052612bb28260406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b60ff19815416905573ffffffffffffffffffffffffffffffffffffffff339216907ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b6000604051a4565b73ffffffffffffffffffffffffffffffffffffffff601054163303612c1d57565b606460405162461bcd60e51b815260206004820152602060248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff90600d54811015612cde575b600d6000527fd7b6990105719101dabeb77144f2a3385c8033acd3af97e9423a695e81ad1eb501541690565b612ce6612c61565b612cb2565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6001907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe8111612d49570190565b612b34612ceb565b8019603011612d61575b60300190565b612d69612ceb565b612d5b565b81198111612d49570190565b61064a90612d8b47600a5490612d6e565b73ffffffffffffffffffffffffffffffffffffffff8216600052600c6020526040600020549161317b565b919073ffffffffffffffffffffffffffffffffffffffff83166040517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152602081602481855afa908115612ebe57600091612e8b575b50612e4d90612e4661064a959673ffffffffffffffffffffffffffffffffffffffff16600052600e602052604060002090565b5490612d6e565b90600052600f602052612e848260406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b549161317b565b906020823d8211612eb6575b81612ea460209383611451565b8101031261072557505161064a612e13565b3d9150612e97565b6040513d6000823e3d90fd5b15612ed157565b608460405162461bcd60e51b815260206004820152602660248201527f5061796d656e7453706c69747465723a206163636f756e7420686173206e6f2060448201527f73686172657300000000000000000000000000000000000000000000000000006064820152fd5b15612f4257565b608460405162461bcd60e51b815260206004820152602b60248201527f5061796d656e7453706c69747465723a206163636f756e74206973206e6f742060448201527f647565207061796d656e740000000000000000000000000000000000000000006064820152fd5b9073ffffffffffffffffffffffffffffffffffffffff8216600092818452600b602052604093612fe0858220541515612eca565b612fe983612d7a565b92612ff5841515612f3b565b808252600c60205285822061300b858254612d6e565b905561301984600a54612d6e565b600a558347106130f257818091858851915af1613034613a1e565b501561308957925173ffffffffffffffffffffffffffffffffffffffff90931683526020830152907fdf20fd1e76bc69d672e4814fafb2c449bba3a5369d8359adf9e05e6fde87b0569080604081015b0390a1565b6084845162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152fd5b6064865162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e63650000006044820152fd5b8060001904821181151516613148570290565b613150612ceb565b0290565b6000199060018110612d49570190565b81811061316f570390565b613177612ceb565b0390565b9073ffffffffffffffffffffffffffffffffffffffff6131aa9216600052600b60205260406000205490613135565b6009549081156131c0570481811061316f570390565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b908160209103126104b6575161064a81611c50565b1561320b57565b608460405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f742073756363656564000000000000000000000000000000000000000000006064820152fd5b1561327c57565b606460405162461bcd60e51b815260206004820152601860248201527f4552433732313a20696e76616c696420746f6b656e20494400000000000000006044820152fd5b600052600260205273ffffffffffffffffffffffffffffffffffffffff6040600020541661064a811515613275565b90600182811c92168015613338575b602083101461330957565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b91607f16916132fe565b6040519060008260145491613356836132ef565b808352926001908181169081156133de575060011461337f575b5061337d92500383611451565b565b6014600090815291507fce6d7b5282bd9a3661ae061feed1dbda4e52ab073b1f9285be6e155d9c38d4ec5b8483106133c3575061337d935050810160200138613370565b81935090816020925483858a010152019101909185926133aa565b935050505060ff19915016602083015261337d826040810138613370565b1561340357565b608460405162461bcd60e51b815260206004820152603e60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206e6f7220617070726f76656420666f7220616c6c00006064820152fd5b6134a261349d82600052600260205273ffffffffffffffffffffffffffffffffffffffff60406000205416151590565b613275565b600052600460205273ffffffffffffffffffffffffffffffffffffffff6040600020541690565b156134d057565b608460405162461bcd60e51b815260206004820152602e60248201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560448201527f72206e6f7220617070726f7665640000000000000000000000000000000000006064820152fd5b9161337d939161356193613551610ba184336135d3565b61355c8383836136de565b613b9f565b1561356857565b60405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608490fd5b73ffffffffffffffffffffffffffffffffffffffff806135f2846132c0565b169281831692848414948515613628575b50508315613612575b50505090565b61361e9192935061346d565b161438808061360c565b60ff9295509061366491600052600560205260406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b5416923880613603565b1561367557565b608460405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f2061646460448201527f72657373000000000000000000000000000000000000000000000000000000006064820152fd5b906136e8836132c0565b73ffffffffffffffffffffffffffffffffffffffff918291828516938491160361380f576137506137e69282169461372186151561366e565b61372a87613879565b73ffffffffffffffffffffffffffffffffffffffff166000526003602052604060002090565b61375a8154613154565b90556137868173ffffffffffffffffffffffffffffffffffffffff166000526003602052604060002090565b6137908154612d1b565b90556137a6856000526002602052604060002090565b9073ffffffffffffffffffffffffffffffffffffffff167fffffffffffffffffffffffff0000000000000000000000000000000000000000825416179055565b7fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef6000604051a4565b608460405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201527f6f776e65720000000000000000000000000000000000000000000000000000006064820152fd5b80600052600460205260406000207fffffffffffffffffffffffff00000000000000000000000000000000000000008154169055600073ffffffffffffffffffffffffffffffffffffffff6138cd836132c0565b167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92582604051a4565b8160005260046020526139488160406000209073ffffffffffffffffffffffffffffffffffffffff167fffffffffffffffffffffffff0000000000000000000000000000000000000000825416179055565b73ffffffffffffffffffffffffffffffffffffffff80613967846132c0565b169116907f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9256000604051a4565b908160209103126104b6575161064a8161048c565b61064a939273ffffffffffffffffffffffffffffffffffffffff60809316825260006020830152604082015281606082015201906105f6565b909261064a949360809373ffffffffffffffffffffffffffffffffffffffff8092168452166020830152604082015281606082015201906105f6565b3d15613a49573d90613a2f82611492565b91613a3d6040519384611451565b82523d6000602084013e565b606090565b909190803b15613b9757613aae60209173ffffffffffffffffffffffffffffffffffffffff9360006040519586809581947f150b7a02000000000000000000000000000000000000000000000000000000009a8b845233600485016139a9565b0393165af160009181613b67575b50613b4157613ac9613a1e565b80519081613b3c5760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608490fd5b602001fd5b7fffffffff00000000000000000000000000000000000000000000000000000000161490565b613b8991925060203d8111613b90575b613b818183611451565b810190613994565b9038613abc565b503d613b77565b505050600190565b92909190823b15613c0057613aae92602092600073ffffffffffffffffffffffffffffffffffffffff6040518097819682957f150b7a02000000000000000000000000000000000000000000000000000000009b8c855233600486016139e2565b50505050600190565b90919015613c15575090565b815115613c255750805190602001fd5b6129259060405191829162461bcd60e51b83526020600484015260248301906105f6565b604051906080820182811067ffffffffffffffff821117613c76575b604052604282526060366020840137565b613c7e6113dc565b613c65565b602090805115613c91570190565b612b34612c61565b602190805160011015613c91570190565b906020918051821015613cbc57010190565b613cc4612c61565b010190565b600019908015612d49570190565b15613cde57565b606460405162461bcd60e51b815260206004820152602060248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152fd5b604051906060820182811067ffffffffffffffff821117613dbf575b604052602a825260403660208401376030613d5883613c83565b536078613d6483613c99565b536029905b60018211613d7c5761064a915015613cd7565b807f3031323334353637383961626364656600000000000000000000000000000000600f613db993166010811015612977571a6129688486613caa565b90613d69565b613dc76113dc565b613d3e565b60001960125460135490818110613deb575b0360018110612d49570190565b613df3612ceb565b613dde565b15613dff57565b606460405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b90929167ffffffffffffffff8411613e9b575b8360051b6040519260208094613e6e82850182611451565b80978152019181019283116104b657905b828210613e8c5750505050565b81358152908301908301613e7f565b613ea36113dc565b613e56565b6001906000198114612d49570190565b60ff60075416613ec457565b606460405162461bcd60e51b815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152fd5b90604051613f158161140c565b6000815273ffffffffffffffffffffffffffffffffffffffff831691821561403057613f6481600052600260205273ffffffffffffffffffffffffffffffffffffffff60406000205416151590565b613fec57838161356194613f9b61337d9773ffffffffffffffffffffffffffffffffffffffff166000526003602052604060002090565b613fa58154612d1b565b9055613fbf836137a6846000526002602052604060002090565b60007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef81604051a4613a4e565b606460405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152fd5b606460405162461bcd60e51b815260206004820152602060248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152fd5b9091906000915b81518310156140c7576020808460051b840101519160008382106000146140b65750600052526140b060406000205b92613ea8565b9161407b565b906040926140b094835252206140aa565b9150501490565b6013547f000000000000000000000000000000000000000000000000000000000000000081811061316f570390565b818110614108575050565b600081556001016140fd565b90601f8211614121575050565b61337d9160146000527fce6d7b5282bd9a3661ae061feed1dbda4e52ab073b1f9285be6e155d9c38d4ec906020601f840160051c8301931061416b575b601f0160051c01906140fd565b909150819061415e565b6141a561349d82600052600260205273ffffffffffffffffffffffffffffffffffffffff60406000205416151590565b6000908082526020600681526040832060405193848183546141c6816132ef565b93848452868401956001928381169081600014614298575060011461425c575b5050506141f592500385611451565b6141fd613342565b90815194851561425357805161421b575050505061064a91506142b7565b61064a9450614247866142386040519889968880890191016105c1565b840191518093868401906105c1565b01038084520182611451565b94505050505090565b879350819291528282205b8583106142805750506141f593508201013880806141e6565b8054838b018501528994508793909201918101614267565b9550505050505060ff1991501681526141f584604081013880806141e6565b6142e761349d82600052600260205273ffffffffffffffffffffffffffffffffffffffff60406000205416151590565b6142ef613342565b8051909190600090156143385750602061430b61064a9261434d565b92604051938161432486935180928680870191016105c1565b8201614247825180938680850191016105c1565b915050604051906143488261140c565b815290565b801561442c57806000908282935b614418575061436983611492565b926143776040519485611451565b808452817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe06143a583611492565b013660208701375b6143b75750505090565b6143c090613154565b90600a906144036143db6143d5848406612d51565b60ff1690565b60f81b7fff000000000000000000000000000000000000000000000000000000000000001690565b841a61440f8487613caa565b530490816143ad565b92614424600a91613ea8565b93048061435b565b506040516040810181811067ffffffffffffffff821117614478575b604052600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b6144806113dc565b614448565b61064a90546132ef565b61449981546132ef565b90816144a3575050565b81601f600093116001146144b5575055565b818352602083206144d191601f0160051c8101906001016140fd565b8160208120915555565b604080513381523460208201527f6ef95f06320e7a25a04a175ca677b7052bdd97131872c2192525a629f51be770918190810161308456fea2646970667358221220a5f73e202c71b439bfcfc0a4274c0b4ff13cddfc20c8c64d07762692409763b264736f6c634300080d0033000000000000000000000000000000000000000000000000000000000000016000000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000414d93d7883e6755aa4e24cb2707c566c40886a60000000000000000000000000000000000000000000000000000000000000220000000000000000000000000000000000000000000000000000000000000026000000000000000000000000000000000000000000000000000000000000002a000000000000000000000000000000000000000000000000000f5232269808000000000000000000000000000000000000000000000000000000000000000270f0000000000000000000000000000000000000000000000000000000000000064000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000c0c2101d911a718a23e80951ee6cc26411308000000000000000000000000414d93d7883e6755aa4e24cb2707c566c40886a60000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000005a000000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000b5761636b6f20576f726d730000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002575700000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000012f00000000000000000000000000000000000000000000000000000000000000
Deployed Bytecode
0x60806040526004361015610023575b361561001957600080fd5b6100216144db565b005b60003560e01c806301ffc9a71461048357806306fdde031461047a578063074cba6b14610471578063081812fc14610468578063095ea7b31461045f5780630d730acc1461045657806318160ddd1461044d578063191655871461044457806322212e2b1461043b57806323b872dd14610432578063248a9ca31461042957806328d7b276146104205780632f2ff15d1461041757806336568abe1461040e5780633a98ef39146104055780633ccfd60b146103fc5780633f4ba83a146103f3578063406072a9146103ea57806342842e0e146103e157806342966c68146103d857806348b75044146103cf5780634df6e322146103c657806355f804b3146103bd5780635c975abb146103b45780636352211e146103ab5780636c0360eb146103a257806370a0823114610399578063715018a6146103905780637aabccb1146103875780638456cb591461037e5780638b83209b146103755780638da5cb5b1461036c57806391d148541461036357806395364a841461035a57806395d89b41146103515780639852595c14610348578063a217fddf1461033f578063a22cb46514610336578063a3f8eace1461032d578063a43be57b14610324578063a7f93ebd1461031b578063b88d4fde14610312578063bfdf019d14610309578063c45ac05014610300578063c87b56dd146102f7578063ce7c2ac2146102ee578063d547741f146102e5578063d5abeb01146102dc578063d70170ee146102d3578063d79779b2146102ca578063e33b7de3146102c1578063e3e1e8ef146102b8578063e922d7ec146102af578063e985e9c5146102a6578063f2fde38b1461029d5763f4a0a5280361000e576102986127f5565b61000e565b506102986126ec565b50610298612673565b50610298612388565b506102986120a2565b50610298612052565b50610298612006565b50610298611fca565b50610298611f8e565b50610298611f4b565b50610298611eff565b50610298611edf565b50610298611ec5565b50610298611e89565b50610298611e20565b50610298611e01565b50610298611d8e565b50610298611d66565b50610298611c5a565b50610298611c33565b50610298611be7565b50610298611b41565b50610298611b1d565b50610298611ab8565b50610298611a83565b50610298611a64565b50610298611a09565b50610298611827565b506102986117a2565b506102986116dc565b506102986116ab565b5061029861168c565b50610298611668565b50610298611512565b506102986112e7565b5061029861109f565b50610298610f70565b50610298610f47565b50610298610ee2565b50610298610e20565b50610298610dcc565b50610298610dad565b50610298610cfc565b50610298610bfd565b50610298610bdb565b50610298610bab565b50610298610b81565b50610298610b36565b50610298610b10565b50610298610aec565b50610298610908565b506102986107cf565b50610298610792565b50610298610746565b5061029861064d565b506102986104bb565b7fffffffff000000000000000000000000000000000000000000000000000000008116036104b657565b600080fd5b50346104b65760206003193601126104b65760207fffffffff000000000000000000000000000000000000000000000000000000006004356104fc8161048c565b167f7965db0b000000000000000000000000000000000000000000000000000000008114908115610533575b506040519015158152f35b7f80ac58cd00000000000000000000000000000000000000000000000000000000811491508115610597575b811561056d575b5038610528565b7f01ffc9a70000000000000000000000000000000000000000000000000000000091501438610566565b7f5b5e139f000000000000000000000000000000000000000000000000000000008114915061055f565b918091926000905b8282106105e15750116105da575050565b6000910152565b915080602091830151818601520182916105c9565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f602093610632815180928187528780880191016105c1565b0116010190565b90602061064a9281815201906105f6565b90565b50346104b6576000806003193601126107255760405190808054610670816132ef565b8085529160019180831690811561070457506001146106aa575b6106a68561069a81870382611451565b60405191829182610639565b0390f35b80809450527f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e5635b8284106106ec57505050810160200161069a826106a661068a565b805460208587018101919091529093019281016106d1565b60ff19166020870152505060408401925061069a91508390506106a661068a565b80fd5b73ffffffffffffffffffffffffffffffffffffffff8116036104b657565b50346104b65760206003193601126104b65773ffffffffffffffffffffffffffffffffffffffff60043561077981610728565b16600052601a6020526020604060002054604051908152f35b50346104b65760206003193601126104b65760206107b160043561346d565b73ffffffffffffffffffffffffffffffffffffffff60405191168152f35b50346104b65760406003193601126104b6576004356107ed81610728565b6024356107f9816132c0565b9173ffffffffffffffffffffffffffffffffffffffff808416809183161461089e5761002193610833913314908115610838575b506133fc565b6138f6565b61089891506108919061086c339173ffffffffffffffffffffffffffffffffffffffff166000526005602052604060002090565b9073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b5460ff1690565b3861082d565b608460405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560448201527f72000000000000000000000000000000000000000000000000000000000000006064820152fd5b5060206003193601126104b657600480359061092960026011541415613df8565b6002601155610936613eb8565b8115610aa85761094882601654613135565b3410610a80577f00000000000000000000000000000000000000000000000000000000000000148211610a585761098682610981613dcc565b612d6e565b61098e6140ce565b60155490818110610a4b575b0310610a235760ff601854166109fb575060005b8181106109bf576100216001601155565b6109dd906109cb613dcc565b6109d36140ce565b116109e257613ea8565b6109ae565b60126109ef815433613f08565b60018154019055613ea8565b6040517f6e2e8798000000000000000000000000000000000000000000000000000000008152fd5b6040517ffb88d215000000000000000000000000000000000000000000000000000000008152fd5b610a53612ceb565b61099a565b6040517fb637d13b000000000000000000000000000000000000000000000000000000008152fd5b6040517f8a0d3779000000000000000000000000000000000000000000000000000000008152fd5b60649060206040519162461bcd60e51b8352820152601a60248201527f4d696e7420616d6f756e742063616e6e6f74206265207a65726f0000000000006044820152fd5b50346104b65760006003193601126104b6576020610b08613dcc565b604051908152f35b50346104b65760206003193601126104b657610021600435610b3181610728565b612fac565b50346104b65760006003193601126104b6576020601954604051908152f35b60031960609101126104b657600435610b6d81610728565b90602435610b7a81610728565b9060443590565b50346104b657610021610b9336610b55565b91610ba6610ba184336135d3565b6134c9565b6136de565b50346104b65760206003193601126104b65760043560005260086020526020600160406000200154604051908152f35b50346104b65760206003193601126104b657610bf5612817565b600435601955005b50346104b6576040806003193601126104b65760043590602435610c2081610728565b6000928084526008602052610c3a60018486200154612a4e565b808452600860205260ff610c70838587209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b541615610c7c57505051f35b8084526008602052610cb0828486209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b600160ff1982541617905573ffffffffffffffffffffffffffffffffffffffff339216907f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d858551a451f35b50346104b65760406003193601126104b657602435610d1a81610728565b3373ffffffffffffffffffffffffffffffffffffffff821603610d435761002190600435612b38565b608460405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201527f20726f6c657320666f722073656c6600000000000000000000000000000000006064820152fd5b50346104b65760006003193601126104b6576020600954604051908152f35b50346104b65760006003193601126104b65760005b6017548110156100215780610e1673ffffffffffffffffffffffffffffffffffffffff610e10610e1b94612c91565b16612fac565b613ea8565b610de1565b50346104b65760006003193601126104b657610e3a612984565b60075460ff811615610e795760ff19166007557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa6020604051338152a1005b606460405162461bcd60e51b815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152fd5b60031960409101126104b657600435610ed581610728565b9060243561064a81610728565b50346104b6576020610f3e73ffffffffffffffffffffffffffffffffffffffff610f0b36610ebd565b9116600052600f835260406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b50346104b657610021610f5936610b55565b9060405192610f678461140c565b6000845261353a565b50346104b65760206003193601126104b657600435610f92610ba182336135d3565b73ffffffffffffffffffffffffffffffffffffffff610fb0826132c0565b610fb983613879565b16908060008381948252600360205260408220600019815460018110611092575b0190558282526002602052604082207fffffffffffffffffffffffff000000000000000000000000000000000000000081541690557fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef82604051a461105161104c826000526006602052604060002090565b614485565b611070575b5061106b61106660135460010190565b601355565b604051f35b61108761108c916000526006602052604060002090565b61448f565b38611056565b61109a612ceb565b610fda565b50346104b6576110ae36610ebd565b9073ffffffffffffffffffffffffffffffffffffffff916000918382168352602093600b85526040926110e5848620541515612eca565b6111676110f28285612db6565b926110fe841515612f3b565b841693848752600f8852611134838789209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61113f858254612d6e565b905573ffffffffffffffffffffffffffffffffffffffff16600052600e602052604060002090565b611172838254612d6e565b905583517fa9059cbb0000000000000000000000000000000000000000000000000000000087820190815273ffffffffffffffffffffffffffffffffffffffff83166024830152604480830185905282529096906111d1606489611451565b8551976111dd89611435565b8289527f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564838a0152853b156112a45797878061124c937f3be5b7a71e84ed12875d241991c70855ac5817d847039e17a9d895c1ceb0f18a98999a9b5190828b5af1611246613a1e565b90613c09565b80519081611284575b5050855173ffffffffffffffffffffffffffffffffffffffff929092168252506020810191909152604090a251f35b8261129c936112979383010191016131ef565b613204565b388080611255565b60648388519062461bcd60e51b82526004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152fd5b50346104b65760406003193601126104b65760043561130581610728565b6024359061131860026011541415613df8565b6002601155611325612817565b60155482116113985760005b8281106113565761134c61134784601554613164565b601555565b6100216001601155565b61137490611362613dcc565b61136a6140ce565b1161137957613ea8565b611331565b610e16611393601261138c815487613f08565b5460010190565b601255565b606460405162461bcd60e51b815260206004820152601760248201527f4578636565647320726573657276656420737570706c790000000000000000006044820152fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6020810190811067ffffffffffffffff82111761142857604052565b6114306113dc565b604052565b6040810190811067ffffffffffffffff82111761142857604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761142857604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff81116114ce575b01160190565b6114d66113dc565b6114c8565b9291926114e782611492565b916114f56040519384611451565b8294818452818301116104b6578281602093846000960137010152565b50346104b6576020806003193601126104b65767ffffffffffffffff6004358181116104b657366023820112156104b6576115579036906024816004013591016114db565b91611560612817565b825191821161165b575b61157e826115796014546132ef565b614114565b80601f83116001146115b6575081926000926115ab575b50506000198260011b9260031b1c191617601455005b015190503880611595565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe083169361160760146000527fce6d7b5282bd9a3661ae061feed1dbda4e52ab073b1f9285be6e155d9c38d4ec90565b926000905b868210611643575050836001951061162a575b505050811b01601455005b015160001960f88460031b161c1916905538808061161f565b8060018596829496860151815501950193019061160c565b6116636113dc565b61156a565b50346104b65760006003193601126104b657602060ff600754166040519015158152f35b50346104b65760206003193601126104b65760206107b16004356132c0565b50346104b65760006003193601126104b6576106a66116c8613342565b6040519182916020835260208301906105f6565b50346104b65760206003193601126104b65773ffffffffffffffffffffffffffffffffffffffff60043561170f81610728565b1680156117385760005260036020526106a6604060002054604051918291829190602083019252565b608460405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f74206120766160448201527f6c6964206f776e657200000000000000000000000000000000000000000000006064820152fd5b50346104b657600080600319360112610725576117bd612bfc565b6010547fffffffffffffffffffffffff000000000000000000000000000000000000000081166010558173ffffffffffffffffffffffffffffffffffffffff60405192167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08284a3f35b506040806003193601126104b65760048035906024359061184782610728565b61185660026011541415613df8565b6002601155611863613eb8565b82156119c65761187583601654613135565b341061199f577f00000000000000000000000000000000000000000000000000000000000000148311611978576118ae83610981613dcc565b6118b66140ce565b6015549081811061196b575b03106119445760ff6018541661191d575060005b8281106118ed576000846118ea6001601155565b51f35b61190b906118f9613dcc565b6119016140ce565b1161191057613ea8565b6118d6565b60126109ef815485613f08565b83517f6e2e8798000000000000000000000000000000000000000000000000000000008152fd5b83517ffb88d215000000000000000000000000000000000000000000000000000000008152fd5b611973612ceb565b6118c2565b83517fb637d13b000000000000000000000000000000000000000000000000000000008152fd5b83517f8a0d3779000000000000000000000000000000000000000000000000000000008152fd5b606490602085519162461bcd60e51b8352820152601a60248201527f4d696e7420616d6f756e742063616e6e6f74206265207a65726f0000000000006044820152fd5b50346104b65760006003193601126104b657611a23612984565b611a2b613eb8565b600160ff1960075416176007557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586020604051338152a1005b50346104b65760206003193601126104b65760206107b1600435612c91565b50346104b65760006003193601126104b657602073ffffffffffffffffffffffffffffffffffffffff60105416604051908152f35b50346104b65760406003193601126104b657602060ff611b11602435611add81610728565b6004356000526008845260406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54166040519015158152f35b50346104b65760006003193601126104b657602060ff601854166040519015158152f35b50346104b6576000806003193601126107255760405190806001805491611b67836132ef565b808652928281169081156107045750600114611b8d576106a68561069a81870382611451565b92508083527fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf65b828410611bcf57505050810160200161069a826106a661068a565b80546020858701810191909152909301928101611bb4565b50346104b65760206003193601126104b65773ffffffffffffffffffffffffffffffffffffffff600435611c1a81610728565b16600052600c6020526020604060002054604051908152f35b50346104b65760006003193601126104b657602060405160008152f35b801515036104b657565b50346104b65760406003193601126104b657600435611c7881610728565b602435611c8481611c50565b73ffffffffffffffffffffffffffffffffffffffff821691823314611d225781611cde611cf09233600052600560205260406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b9060ff60ff1983541691151516179055565b604051901515815233907f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3190602090a3005b606460405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152fd5b50346104b65760206003193601126104b6576020610b08600435611d8981610728565b612d7a565b50346104b65760006003193601126104b657611da8612984565b60185460ff811615611dbd5760ff1916601855005b606460405162461bcd60e51b815260206004820152601560248201527f50726573616c6520616c726561647920656e64656400000000000000000000006044820152fd5b50346104b65760006003193601126104b6576020601654604051908152f35b50346104b65760806003193601126104b657600435611e3e81610728565b602435611e4a81610728565b6064359167ffffffffffffffff83116104b657366023840112156104b657611e7f6100219336906024816004013591016114db565b916044359161353a565b50346104b65760006003193601126104b65760206040517f00000000000000000000000000000000000000000000000000000000000000148152f35b50346104b6576020610b08611ed936610ebd565b90612db6565b50346104b65760206003193601126104b6576106a66116c8600435614175565b50346104b65760206003193601126104b65773ffffffffffffffffffffffffffffffffffffffff600435611f3281610728565b16600052600b6020526020604060002054604051908152f35b50346104b65760406003193601126104b657610021602435600435611f6f82610728565b806000526008602052611f89600160406000200154612a4e565b612b38565b50346104b65760006003193601126104b65760206040517f000000000000000000000000000000000000000000000000000000000000270f8152f35b50346104b65760006003193601126104b65760206040517f00000000000000000000000000000000000000000000000000000000000000148152f35b50346104b65760206003193601126104b65773ffffffffffffffffffffffffffffffffffffffff60043561203981610728565b16600052600e6020526020604060002054604051908152f35b50346104b65760006003193601126104b6576020600a54604051908152f35b9181601f840112156104b65782359167ffffffffffffffff83116104b6576020808501948460051b0101116104b657565b506040806003193601126104b657600480359060243567ffffffffffffffff81116104b6576120d49036908301612071565b9060ff6018541615612360576120e8613eb8565b6120f760026011541415613df8565b600260115561210884610981613dcc565b6121106140ce565b60155490818110612353575b031061232b577f000000000000000000000000000000000000000000000000000000000000001484116123035761215584601654613135565b34106122db57336000908152601a60205260409020612175858254612d6e565b9055336000908152601a60205260409020547f0000000000000000000000000000000000000000000000000000000000000014106122b35761223a91612236916122316019549188516020810190612226816121fa33857fffffffffffffffffffffffffffffffffffffffff00000000000000000000000060149260601b1681520190565b037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08101835282611451565b519020933691613e43565b614074565b1590565b61228c575060005b818110612256576000836118ea6001601155565b61227490612262613dcc565b61226a6140ce565b1161227957613ea8565b612242565b610e16611393601261138c815433613f08565b82517fb05e92fa000000000000000000000000000000000000000000000000000000008152fd5b8285517f2d3e8402000000000000000000000000000000000000000000000000000000008152fd5b8285517f8a0d3779000000000000000000000000000000000000000000000000000000008152fd5b8285517fb637d13b000000000000000000000000000000000000000000000000000000008152fd5b8285517ffb88d215000000000000000000000000000000000000000000000000000000008152fd5b61235b612ceb565b61211c565b8285517f35c33e81000000000000000000000000000000000000000000000000000000008152fd5b5060606003193601126104b6576004803560243567ffffffffffffffff81116104b6576123b89036908401612071565b60443593916123c685610728565b60ff601854161561264a576123d9613eb8565b6123e860026011541415613df8565b60026011556123f984610981613dcc565b6124016140ce565b6015549081811061263d575b0310612614577f000000000000000000000000000000000000000000000000000000000000001484116125eb5761244684601654613135565b34106125c2576124768573ffffffffffffffffffffffffffffffffffffffff16600052601a602052604060002090565b612481858254612d6e565b90556124ad8573ffffffffffffffffffffffffffffffffffffffff16600052601a602052604060002090565b547f000000000000000000000000000000000000000000000000000000000000001410612599576125229161223691612231601954916040516020810190612226816121fa8d857fffffffffffffffffffffffffffffffffffffffff00000000000000000000000060149260601b1681520190565b612571575060005b81811061253b576100216001601155565b61255990612547613dcc565b61254f6140ce565b1161255e57613ea8565b61252a565b610e16611393601261138c815488613f08565b6040517fb05e92fa000000000000000000000000000000000000000000000000000000008152fd5b826040517f2d3e8402000000000000000000000000000000000000000000000000000000008152fd5b826040517f8a0d3779000000000000000000000000000000000000000000000000000000008152fd5b826040517fb637d13b000000000000000000000000000000000000000000000000000000008152fd5b826040517ffb88d215000000000000000000000000000000000000000000000000000000008152fd5b612645612ceb565b61240d565b826040517f35c33e81000000000000000000000000000000000000000000000000000000008152fd5b50346104b65760406003193601126104b657602060ff611b1160043561269881610728565b73ffffffffffffffffffffffffffffffffffffffff602435916126ba83610728565b166000526005845260406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b50346104b65760206003193601126104b65760043561270a81610728565b612712612bfc565b73ffffffffffffffffffffffffffffffffffffffff80911690811561278b5760009160105491817fffffffffffffffffffffffff000000000000000000000000000000000000000084161760105560405192167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08484a3f35b608460405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152fd5b50346104b65760206003193601126104b65761280f612817565b600435601655005b3360009081527f5eff886ea0ce6ca488a3d6e336d6c0f75f46d19b42c06ce5ee98e42c96d256c7602052604090205460ff161561285057565b61285933613d22565b6000612863613c49565b90603061286f83613c83565b53607861287b83613c99565b5360415b6001811161292957612925604861290d866121fa8761289e8815613cd7565b6040519485937f416363657373436f6e74726f6c3a206163636f756e742000000000000000000060208601526128de8151809260206037890191016105c1565b84017f206973206d697373696e6720726f6c652000000000000000000000000000000060378201520190612b21565b60405191829162461bcd60e51b835260048301610639565b0390fd5b90807f3031323334353637383961626364656600000000000000000000000000000000600f61297293166010811015612977575b1a6129688486613caa565b5360041c91613cc9565b61287f565b61297f612c61565b61295d565b3360009081527f5eff886ea0ce6ca488a3d6e336d6c0f75f46d19b42c06ce5ee98e42c96d256c7602052604090205460ff16156129bd57565b6129c633613d22565b60006129d0613c49565b9060306129dc83613c83565b5360786129e883613c99565b5360415b60018111612a0b57612925604861290d866121fa8761289e8815613cd7565b90807f3031323334353637383961626364656600000000000000000000000000000000600f612a4993166010811015612977571a6129688486613caa565b6129ec565b80600052600860205260ff612a873360406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b541615612a915750565b612a9a33613d22565b90612aa3613c49565b906030612aaf83613c83565b536078612abb83613c99565b5360415b60018111612ade57612925604861290d866121fa8761289e8815613cd7565b90807f3031323334353637383961626364656600000000000000000000000000000000600f612b1c93166010811015612977571a6129688486613caa565b612abf565b90612b34602092828151948592016105c1565b0190565b80600052600860205260ff612b718360406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b5416612b7b575050565b806000526008602052612bb28260406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b60ff19815416905573ffffffffffffffffffffffffffffffffffffffff339216907ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b6000604051a4565b73ffffffffffffffffffffffffffffffffffffffff601054163303612c1d57565b606460405162461bcd60e51b815260206004820152602060248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff90600d54811015612cde575b600d6000527fd7b6990105719101dabeb77144f2a3385c8033acd3af97e9423a695e81ad1eb501541690565b612ce6612c61565b612cb2565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6001907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe8111612d49570190565b612b34612ceb565b8019603011612d61575b60300190565b612d69612ceb565b612d5b565b81198111612d49570190565b61064a90612d8b47600a5490612d6e565b73ffffffffffffffffffffffffffffffffffffffff8216600052600c6020526040600020549161317b565b919073ffffffffffffffffffffffffffffffffffffffff83166040517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152602081602481855afa908115612ebe57600091612e8b575b50612e4d90612e4661064a959673ffffffffffffffffffffffffffffffffffffffff16600052600e602052604060002090565b5490612d6e565b90600052600f602052612e848260406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b549161317b565b906020823d8211612eb6575b81612ea460209383611451565b8101031261072557505161064a612e13565b3d9150612e97565b6040513d6000823e3d90fd5b15612ed157565b608460405162461bcd60e51b815260206004820152602660248201527f5061796d656e7453706c69747465723a206163636f756e7420686173206e6f2060448201527f73686172657300000000000000000000000000000000000000000000000000006064820152fd5b15612f4257565b608460405162461bcd60e51b815260206004820152602b60248201527f5061796d656e7453706c69747465723a206163636f756e74206973206e6f742060448201527f647565207061796d656e740000000000000000000000000000000000000000006064820152fd5b9073ffffffffffffffffffffffffffffffffffffffff8216600092818452600b602052604093612fe0858220541515612eca565b612fe983612d7a565b92612ff5841515612f3b565b808252600c60205285822061300b858254612d6e565b905561301984600a54612d6e565b600a558347106130f257818091858851915af1613034613a1e565b501561308957925173ffffffffffffffffffffffffffffffffffffffff90931683526020830152907fdf20fd1e76bc69d672e4814fafb2c449bba3a5369d8359adf9e05e6fde87b0569080604081015b0390a1565b6084845162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152fd5b6064865162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e63650000006044820152fd5b8060001904821181151516613148570290565b613150612ceb565b0290565b6000199060018110612d49570190565b81811061316f570390565b613177612ceb565b0390565b9073ffffffffffffffffffffffffffffffffffffffff6131aa9216600052600b60205260406000205490613135565b6009549081156131c0570481811061316f570390565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b908160209103126104b6575161064a81611c50565b1561320b57565b608460405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f742073756363656564000000000000000000000000000000000000000000006064820152fd5b1561327c57565b606460405162461bcd60e51b815260206004820152601860248201527f4552433732313a20696e76616c696420746f6b656e20494400000000000000006044820152fd5b600052600260205273ffffffffffffffffffffffffffffffffffffffff6040600020541661064a811515613275565b90600182811c92168015613338575b602083101461330957565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b91607f16916132fe565b6040519060008260145491613356836132ef565b808352926001908181169081156133de575060011461337f575b5061337d92500383611451565b565b6014600090815291507fce6d7b5282bd9a3661ae061feed1dbda4e52ab073b1f9285be6e155d9c38d4ec5b8483106133c3575061337d935050810160200138613370565b81935090816020925483858a010152019101909185926133aa565b935050505060ff19915016602083015261337d826040810138613370565b1561340357565b608460405162461bcd60e51b815260206004820152603e60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206e6f7220617070726f76656420666f7220616c6c00006064820152fd5b6134a261349d82600052600260205273ffffffffffffffffffffffffffffffffffffffff60406000205416151590565b613275565b600052600460205273ffffffffffffffffffffffffffffffffffffffff6040600020541690565b156134d057565b608460405162461bcd60e51b815260206004820152602e60248201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560448201527f72206e6f7220617070726f7665640000000000000000000000000000000000006064820152fd5b9161337d939161356193613551610ba184336135d3565b61355c8383836136de565b613b9f565b1561356857565b60405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608490fd5b73ffffffffffffffffffffffffffffffffffffffff806135f2846132c0565b169281831692848414948515613628575b50508315613612575b50505090565b61361e9192935061346d565b161438808061360c565b60ff9295509061366491600052600560205260406000209073ffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b5416923880613603565b1561367557565b608460405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f2061646460448201527f72657373000000000000000000000000000000000000000000000000000000006064820152fd5b906136e8836132c0565b73ffffffffffffffffffffffffffffffffffffffff918291828516938491160361380f576137506137e69282169461372186151561366e565b61372a87613879565b73ffffffffffffffffffffffffffffffffffffffff166000526003602052604060002090565b61375a8154613154565b90556137868173ffffffffffffffffffffffffffffffffffffffff166000526003602052604060002090565b6137908154612d1b565b90556137a6856000526002602052604060002090565b9073ffffffffffffffffffffffffffffffffffffffff167fffffffffffffffffffffffff0000000000000000000000000000000000000000825416179055565b7fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef6000604051a4565b608460405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201527f6f776e65720000000000000000000000000000000000000000000000000000006064820152fd5b80600052600460205260406000207fffffffffffffffffffffffff00000000000000000000000000000000000000008154169055600073ffffffffffffffffffffffffffffffffffffffff6138cd836132c0565b167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92582604051a4565b8160005260046020526139488160406000209073ffffffffffffffffffffffffffffffffffffffff167fffffffffffffffffffffffff0000000000000000000000000000000000000000825416179055565b73ffffffffffffffffffffffffffffffffffffffff80613967846132c0565b169116907f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9256000604051a4565b908160209103126104b6575161064a8161048c565b61064a939273ffffffffffffffffffffffffffffffffffffffff60809316825260006020830152604082015281606082015201906105f6565b909261064a949360809373ffffffffffffffffffffffffffffffffffffffff8092168452166020830152604082015281606082015201906105f6565b3d15613a49573d90613a2f82611492565b91613a3d6040519384611451565b82523d6000602084013e565b606090565b909190803b15613b9757613aae60209173ffffffffffffffffffffffffffffffffffffffff9360006040519586809581947f150b7a02000000000000000000000000000000000000000000000000000000009a8b845233600485016139a9565b0393165af160009181613b67575b50613b4157613ac9613a1e565b80519081613b3c5760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608490fd5b602001fd5b7fffffffff00000000000000000000000000000000000000000000000000000000161490565b613b8991925060203d8111613b90575b613b818183611451565b810190613994565b9038613abc565b503d613b77565b505050600190565b92909190823b15613c0057613aae92602092600073ffffffffffffffffffffffffffffffffffffffff6040518097819682957f150b7a02000000000000000000000000000000000000000000000000000000009b8c855233600486016139e2565b50505050600190565b90919015613c15575090565b815115613c255750805190602001fd5b6129259060405191829162461bcd60e51b83526020600484015260248301906105f6565b604051906080820182811067ffffffffffffffff821117613c76575b604052604282526060366020840137565b613c7e6113dc565b613c65565b602090805115613c91570190565b612b34612c61565b602190805160011015613c91570190565b906020918051821015613cbc57010190565b613cc4612c61565b010190565b600019908015612d49570190565b15613cde57565b606460405162461bcd60e51b815260206004820152602060248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152fd5b604051906060820182811067ffffffffffffffff821117613dbf575b604052602a825260403660208401376030613d5883613c83565b536078613d6483613c99565b536029905b60018211613d7c5761064a915015613cd7565b807f3031323334353637383961626364656600000000000000000000000000000000600f613db993166010811015612977571a6129688486613caa565b90613d69565b613dc76113dc565b613d3e565b60001960125460135490818110613deb575b0360018110612d49570190565b613df3612ceb565b613dde565b15613dff57565b606460405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b90929167ffffffffffffffff8411613e9b575b8360051b6040519260208094613e6e82850182611451565b80978152019181019283116104b657905b828210613e8c5750505050565b81358152908301908301613e7f565b613ea36113dc565b613e56565b6001906000198114612d49570190565b60ff60075416613ec457565b606460405162461bcd60e51b815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152fd5b90604051613f158161140c565b6000815273ffffffffffffffffffffffffffffffffffffffff831691821561403057613f6481600052600260205273ffffffffffffffffffffffffffffffffffffffff60406000205416151590565b613fec57838161356194613f9b61337d9773ffffffffffffffffffffffffffffffffffffffff166000526003602052604060002090565b613fa58154612d1b565b9055613fbf836137a6846000526002602052604060002090565b60007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef81604051a4613a4e565b606460405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152fd5b606460405162461bcd60e51b815260206004820152602060248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152fd5b9091906000915b81518310156140c7576020808460051b840101519160008382106000146140b65750600052526140b060406000205b92613ea8565b9161407b565b906040926140b094835252206140aa565b9150501490565b6013547f000000000000000000000000000000000000000000000000000000000000270f81811061316f570390565b818110614108575050565b600081556001016140fd565b90601f8211614121575050565b61337d9160146000527fce6d7b5282bd9a3661ae061feed1dbda4e52ab073b1f9285be6e155d9c38d4ec906020601f840160051c8301931061416b575b601f0160051c01906140fd565b909150819061415e565b6141a561349d82600052600260205273ffffffffffffffffffffffffffffffffffffffff60406000205416151590565b6000908082526020600681526040832060405193848183546141c6816132ef565b93848452868401956001928381169081600014614298575060011461425c575b5050506141f592500385611451565b6141fd613342565b90815194851561425357805161421b575050505061064a91506142b7565b61064a9450614247866142386040519889968880890191016105c1565b840191518093868401906105c1565b01038084520182611451565b94505050505090565b879350819291528282205b8583106142805750506141f593508201013880806141e6565b8054838b018501528994508793909201918101614267565b9550505050505060ff1991501681526141f584604081013880806141e6565b6142e761349d82600052600260205273ffffffffffffffffffffffffffffffffffffffff60406000205416151590565b6142ef613342565b8051909190600090156143385750602061430b61064a9261434d565b92604051938161432486935180928680870191016105c1565b8201614247825180938680850191016105c1565b915050604051906143488261140c565b815290565b801561442c57806000908282935b614418575061436983611492565b926143776040519485611451565b808452817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe06143a583611492565b013660208701375b6143b75750505090565b6143c090613154565b90600a906144036143db6143d5848406612d51565b60ff1690565b60f81b7fff000000000000000000000000000000000000000000000000000000000000001690565b841a61440f8487613caa565b530490816143ad565b92614424600a91613ea8565b93048061435b565b506040516040810181811067ffffffffffffffff821117614478575b604052600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b6144806113dc565b614448565b61064a90546132ef565b61449981546132ef565b90816144a3575050565b81601f600093116001146144b5575055565b818352602083206144d191601f0160051c8101906001016140fd565b8160208120915555565b604080513381523460208201527f6ef95f06320e7a25a04a175ca677b7052bdd97131872c2192525a629f51be770918190810161308456fea2646970667358221220a5f73e202c71b439bfcfc0a4274c0b4ff13cddfc20c8c64d07762692409763b264736f6c634300080d0033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000000000000000000000000000000000000000016000000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000414d93d7883e6755aa4e24cb2707c566c40886a60000000000000000000000000000000000000000000000000000000000000220000000000000000000000000000000000000000000000000000000000000026000000000000000000000000000000000000000000000000000000000000002a000000000000000000000000000000000000000000000000000f5232269808000000000000000000000000000000000000000000000000000000000000000270f0000000000000000000000000000000000000000000000000000000000000064000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000c0c2101d911a718a23e80951ee6cc26411308000000000000000000000000414d93d7883e6755aa4e24cb2707c566c40886a60000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000005a000000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000b5761636b6f20576f726d730000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002575700000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000012f00000000000000000000000000000000000000000000000000000000000000
-----Decoded View---------------
Arg [0] : payees (address[]): 0x000C0C2101d911a718a23e80951EE6CC26411308,0x414d93D7883e6755aA4e24Cb2707c566c40886A6
Arg [1] : shares (uint256[]): 90,10
Arg [2] : owner_ (address): 0x414d93D7883e6755aA4e24Cb2707c566c40886A6
Arg [3] : name (string): Wacko Worms
Arg [4] : symbol_ (string): WW
Arg [5] : baseUri (string): /
Arg [6] : mintPrice (uint256): 69000000000000000
Arg [7] : maxSupply_ (uint256): 9999
Arg [8] : reservedAmount (uint256): 100
Arg [9] : maxNftPurchaseable_ (uint256): 20
Arg [10] : maxPresaleMinting_ (uint256): 20
-----Encoded View---------------
23 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000160
Arg [1] : 00000000000000000000000000000000000000000000000000000000000001c0
Arg [2] : 000000000000000000000000414d93d7883e6755aa4e24cb2707c566c40886a6
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000220
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000260
Arg [5] : 00000000000000000000000000000000000000000000000000000000000002a0
Arg [6] : 00000000000000000000000000000000000000000000000000f5232269808000
Arg [7] : 000000000000000000000000000000000000000000000000000000000000270f
Arg [8] : 0000000000000000000000000000000000000000000000000000000000000064
Arg [9] : 0000000000000000000000000000000000000000000000000000000000000014
Arg [10] : 0000000000000000000000000000000000000000000000000000000000000014
Arg [11] : 0000000000000000000000000000000000000000000000000000000000000002
Arg [12] : 000000000000000000000000000c0c2101d911a718a23e80951ee6cc26411308
Arg [13] : 000000000000000000000000414d93d7883e6755aa4e24cb2707c566c40886a6
Arg [14] : 0000000000000000000000000000000000000000000000000000000000000002
Arg [15] : 000000000000000000000000000000000000000000000000000000000000005a
Arg [16] : 000000000000000000000000000000000000000000000000000000000000000a
Arg [17] : 000000000000000000000000000000000000000000000000000000000000000b
Arg [18] : 5761636b6f20576f726d73000000000000000000000000000000000000000000
Arg [19] : 0000000000000000000000000000000000000000000000000000000000000002
Arg [20] : 5757000000000000000000000000000000000000000000000000000000000000
Arg [21] : 0000000000000000000000000000000000000000000000000000000000000001
Arg [22] : 2f00000000000000000000000000000000000000000000000000000000000000
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 27 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.