Feature Tip: Add private address tag to any address under My Name Tag !
More Info
Private Name Tags
ContractCreator
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Name:
SqushyLabsMint
Compiler Version
v0.8.4+commit.c7e474f2
Optimization Enabled:
Yes with 10000 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity ^0.8.4; import './ERC721a/ERC721AUpgradeable.sol'; import '@openzeppelin/contracts/utils/cryptography/ECDSA.sol'; import '@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol'; struct Config { string name; string symbol; uint256 maxSupply; address signer; string baseURI; uint256 publicMintLimit; uint256 publicMintPrice; bool publicMintEnabled; bool approveListMintingEnabled; address squshyLabsAddress; uint256 commission; address implementationAddress; address withdrawalAddress; } contract SqushyLabsMintUpgradeable is ERC721AUpgradeable, OwnableUpgradeable { using ECDSA for bytes32; // public vars uint256 public maxSupply; string public baseURI; bool public approveListMintingEnabled; bool public publicMintEnabled; uint256 public publicMintPrice; uint256 public publicMintLimit; address public squshyLabsAddress; address public withdrawalAddress; uint256 public commission; // private vars address private signer; function _initialize(Config memory _config) initializerERC721A initializer public { __ERC721A_init(_config.name, _config.symbol); __Ownable_init(); setURI(_config.baseURI); signer = _config.signer; maxSupply = _config.maxSupply; commission = _config.commission; squshyLabsAddress = _config.squshyLabsAddress; withdrawalAddress = _config.withdrawalAddress; setMintConfig(_config.publicMintLimit, _config.publicMintPrice, _config.publicMintEnabled, _config.approveListMintingEnabled); } function setMintConfig(uint256 _publicMintLimit, uint256 _publicMintPrice, bool _publicMintEnabled, bool _approveListMintingEnabled) public onlyOwner { publicMintLimit = _publicMintLimit; publicMintPrice = _publicMintPrice; publicMintEnabled = _publicMintEnabled; approveListMintingEnabled = _approveListMintingEnabled; } // read metadata function _baseURI() internal view virtual override returns (string memory) { return baseURI; } // set metadata function setURI(string memory _newBaseURI) public onlyOwner { baseURI = _newBaseURI; } // using signer technique for managing approved minters function updateSigner(address _signer) external onlyOwner { signer = _signer; } function _hash(address _address, uint amount, uint allowedAmount, uint cost) internal view returns (bytes32){ return keccak256(abi.encode(address(this), _address, amount, allowedAmount, cost)); } function _verify(bytes32 hash, uint8 v, bytes32 r, bytes32 s) internal view returns (bool){ return (ecrecover(hash, v, r, s) == signer); } // standard minting function function mint(uint256 amount, address mintAddress) external payable { require(publicMintEnabled, "CONTRACT ERROR: minting has not been enabled"); require(_numberMinted(mintAddress) + amount <= publicMintLimit, "CONTRACT ERROR: Address has already claimed max amount"); require(totalSupply() + amount <= maxSupply, "CONTRACT ERROR: not enough remaining in supply to support desired mint amount"); require(msg.value == amount * publicMintPrice, "CONTRACT ERROR: not enough ether sent"); _safeMint(mintAddress, amount); } // allow list minting function function allowListMint(uint8 v, bytes32 r, bytes32 s, uint256 amount, uint256 allowedAmount, address mintAddress) external payable { require(approveListMintingEnabled, "CONTRACT ERROR: allow list minting has not been enabled"); require(_numberMinted(mintAddress) + amount <= allowedAmount, "CONTRACT ERROR: Address has already claimed max amount"); require(totalSupply() + amount <= maxSupply, "CONTRACT ERROR: not enough remaining in supply to support desired mint amount"); require(_verify(_hash(mintAddress, amount, allowedAmount, msg.value), v, r, s), 'CONTRACT ERROR: Invalid signature'); _safeMint(mintAddress, amount); } // withdraw function function withdraw() external payable { AddressUpgradeable.sendValue(payable(squshyLabsAddress), ((commission * address(this).balance) / 1000)); AddressUpgradeable.sendValue(payable(withdrawalAddress), address(this).balance); } } contract SqushyLabsMint is SqushyLabsMintUpgradeable { function initialize(Config memory _config ) public initializer { _initialize(_config); } }
// SPDX-License-Identifier: MIT // ERC721A Contracts v4.0.0 // Creator: Chiru Labs pragma solidity ^0.8.4; import './IERC721AUpgradeable.sol'; import {ERC721AStorage} from './ERC721AStorage.sol'; import './ERC721A__Initializable.sol'; /** * @dev ERC721 token receiver interface. */ interface ERC721A__IERC721ReceiverUpgradeable { function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); } /** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension. Built to optimize for lower gas during batch mints. * * Assumes serials are sequentially minted starting at _startTokenId() (defaults to 0, e.g. 0, 1, 2, 3..). * * Assumes that an owner cannot have more than 2**64 - 1 (max value of uint64) of supply. * * Assumes that the maximum token id cannot exceed 2**256 - 1 (max value of uint256). */ contract ERC721AUpgradeable is ERC721A__Initializable, IERC721AUpgradeable { using ERC721AStorage for ERC721AStorage.Layout; // Mask of an entry in packed address data. uint256 private constant BITMASK_ADDRESS_DATA_ENTRY = (1 << 64) - 1; // The bit position of `numberMinted` in packed address data. uint256 private constant BITPOS_NUMBER_MINTED = 64; // The bit position of `numberBurned` in packed address data. uint256 private constant BITPOS_NUMBER_BURNED = 128; // The bit position of `aux` in packed address data. uint256 private constant BITPOS_AUX = 192; // Mask of all 256 bits in packed address data except the 64 bits for `aux`. uint256 private constant BITMASK_AUX_COMPLEMENT = (1 << 192) - 1; // The bit position of `startTimestamp` in packed ownership. uint256 private constant BITPOS_START_TIMESTAMP = 160; // The bit mask of the `burned` bit in packed ownership. uint256 private constant BITMASK_BURNED = 1 << 224; // The bit position of the `nextInitialized` bit in packed ownership. uint256 private constant BITPOS_NEXT_INITIALIZED = 225; // The bit mask of the `nextInitialized` bit in packed ownership. uint256 private constant BITMASK_NEXT_INITIALIZED = 1 << 225; function __ERC721A_init(string memory name_, string memory symbol_) internal onlyInitializingERC721A { __ERC721A_init_unchained(name_, symbol_); } function __ERC721A_init_unchained(string memory name_, string memory symbol_) internal onlyInitializingERC721A { ERC721AStorage.layout()._name = name_; ERC721AStorage.layout()._symbol = symbol_; ERC721AStorage.layout()._currentIndex = _startTokenId(); } /** * @dev Returns the starting token ID. * To change the starting token ID, please override this function. */ function _startTokenId() internal view virtual returns (uint256) { return 0; } /** * @dev Returns the next token ID to be minted. */ function _nextTokenId() internal view returns (uint256) { return ERC721AStorage.layout()._currentIndex; } /** * @dev Returns the total number of tokens in existence. * Burned tokens will reduce the count. * To get the total number of tokens minted, please see `_totalMinted`. */ function totalSupply() public view override returns (uint256) { // Counter underflow is impossible as _burnCounter cannot be incremented // more than `_currentIndex - _startTokenId()` times. unchecked { return ERC721AStorage.layout()._currentIndex - ERC721AStorage.layout()._burnCounter - _startTokenId(); } } /** * @dev Returns the total amount of tokens minted in the contract. */ function _totalMinted() internal view returns (uint256) { // Counter underflow is impossible as _currentIndex does not decrement, // and it is initialized to `_startTokenId()` unchecked { return ERC721AStorage.layout()._currentIndex - _startTokenId(); } } /** * @dev Returns the total number of tokens burned. */ function _totalBurned() internal view returns (uint256) { return ERC721AStorage.layout()._burnCounter; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { // The interface IDs are constants representing the first 4 bytes of the XOR of // all function selectors in the interface. See: https://eips.ethereum.org/EIPS/eip-165 // e.g. `bytes4(i.functionA.selector ^ i.functionB.selector ^ ...)` return interfaceId == 0x01ffc9a7 || // ERC165 interface ID for ERC165. interfaceId == 0x80ac58cd || // ERC165 interface ID for ERC721. interfaceId == 0x5b5e139f; // ERC165 interface ID for ERC721Metadata. } /** * @dev See {IERC721-balanceOf}. */ function balanceOf(address owner) public view override returns (uint256) { if (_addressToUint256(owner) == 0) revert BalanceQueryForZeroAddress(); return ERC721AStorage.layout()._packedAddressData[owner] & BITMASK_ADDRESS_DATA_ENTRY; } /** * Returns the number of tokens minted by `owner`. */ function _numberMinted(address owner) internal view returns (uint256) { return (ERC721AStorage.layout()._packedAddressData[owner] >> BITPOS_NUMBER_MINTED) & BITMASK_ADDRESS_DATA_ENTRY; } /** * Returns the number of tokens burned by or on behalf of `owner`. */ function _numberBurned(address owner) internal view returns (uint256) { return (ERC721AStorage.layout()._packedAddressData[owner] >> BITPOS_NUMBER_BURNED) & BITMASK_ADDRESS_DATA_ENTRY; } /** * Returns the auxillary data for `owner`. (e.g. number of whitelist mint slots used). */ function _getAux(address owner) internal view returns (uint64) { return uint64(ERC721AStorage.layout()._packedAddressData[owner] >> BITPOS_AUX); } /** * Sets the auxillary data for `owner`. (e.g. number of whitelist mint slots used). * If there are multiple variables, please pack them into a uint64. */ function _setAux(address owner, uint64 aux) internal { uint256 packed = ERC721AStorage.layout()._packedAddressData[owner]; uint256 auxCasted; assembly { // Cast aux without masking. auxCasted := aux } packed = (packed & BITMASK_AUX_COMPLEMENT) | (auxCasted << BITPOS_AUX); ERC721AStorage.layout()._packedAddressData[owner] = packed; } /** * Returns the packed ownership data of `tokenId`. */ function _packedOwnershipOf(uint256 tokenId) private view returns (uint256) { uint256 curr = tokenId; unchecked { if (_startTokenId() <= curr) if (curr < ERC721AStorage.layout()._currentIndex) { uint256 packed = ERC721AStorage.layout()._packedOwnerships[curr]; // If not burned. if (packed & BITMASK_BURNED == 0) { // Invariant: // There will always be an ownership that has an address and is not burned // before an ownership that does not have an address and is not burned. // Hence, curr will not underflow. // // We can directly compare the packed value. // If the address is zero, packed is zero. while (packed == 0) { packed = ERC721AStorage.layout()._packedOwnerships[--curr]; } return packed; } } } revert OwnerQueryForNonexistentToken(); } /** * Returns the unpacked `TokenOwnership` struct from `packed`. */ function _unpackedOwnership(uint256 packed) private pure returns (TokenOwnership memory ownership) { ownership.addr = address(uint160(packed)); ownership.startTimestamp = uint64(packed >> BITPOS_START_TIMESTAMP); ownership.burned = packed & BITMASK_BURNED != 0; } /** * Returns the unpacked `TokenOwnership` struct at `index`. */ function _ownershipAt(uint256 index) internal view returns (TokenOwnership memory) { return _unpackedOwnership(ERC721AStorage.layout()._packedOwnerships[index]); } /** * @dev Initializes the ownership slot minted at `index` for efficiency purposes. */ function _initializeOwnershipAt(uint256 index) internal { if (ERC721AStorage.layout()._packedOwnerships[index] == 0) { ERC721AStorage.layout()._packedOwnerships[index] = _packedOwnershipOf(index); } } /** * Gas spent here starts off proportional to the maximum mint batch size. * It gradually moves to O(1) as tokens get transferred around in the collection over time. */ function _ownershipOf(uint256 tokenId) internal view returns (TokenOwnership memory) { return _unpackedOwnership(_packedOwnershipOf(tokenId)); } /** * @dev See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view override returns (address) { return address(uint160(_packedOwnershipOf(tokenId))); } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual override returns (string memory) { return ERC721AStorage.layout()._name; } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual override returns (string memory) { return ERC721AStorage.layout()._symbol; } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { if (!_exists(tokenId)) revert URIQueryForNonexistentToken(); string memory baseURI = _baseURI(); return bytes(baseURI).length != 0 ? string(abi.encodePacked(baseURI, _toString(tokenId))) : ''; } /** * @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 overriden in child contracts. */ function _baseURI() internal view virtual returns (string memory) { return ''; } /** * @dev Casts the address to uint256 without masking. */ function _addressToUint256(address value) private pure returns (uint256 result) { assembly { result := value } } /** * @dev Casts the boolean to uint256 without branching. */ function _boolToUint256(bool value) private pure returns (uint256 result) { assembly { result := value } } /** * @dev See {IERC721-approve}. */ function approve(address to, uint256 tokenId) public override { address owner = address(uint160(_packedOwnershipOf(tokenId))); if (to == owner) revert ApprovalToCurrentOwner(); if (_msgSenderERC721A() != owner) if (!isApprovedForAll(owner, _msgSenderERC721A())) { revert ApprovalCallerNotOwnerNorApproved(); } ERC721AStorage.layout()._tokenApprovals[tokenId] = to; emit Approval(owner, to, tokenId); } /** * @dev See {IERC721-getApproved}. */ function getApproved(uint256 tokenId) public view override returns (address) { if (!_exists(tokenId)) revert ApprovalQueryForNonexistentToken(); return ERC721AStorage.layout()._tokenApprovals[tokenId]; } /** * @dev See {IERC721-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { if (operator == _msgSenderERC721A()) revert ApproveToCaller(); ERC721AStorage.layout()._operatorApprovals[_msgSenderERC721A()][operator] = approved; emit ApprovalForAll(_msgSenderERC721A(), operator, approved); } /** * @dev See {IERC721-isApprovedForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return ERC721AStorage.layout()._operatorApprovals[owner][operator]; } /** * @dev See {IERC721-transferFrom}. */ function transferFrom( address from, address to, uint256 tokenId ) public virtual override { _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 { _transfer(from, to, tokenId); if (to.code.length != 0) if (!_checkContractOnERC721Received(from, to, tokenId, _data)) { revert TransferToNonERC721ReceiverImplementer(); } } /** * @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`), */ function _exists(uint256 tokenId) internal view returns (bool) { return _startTokenId() <= tokenId && tokenId < ERC721AStorage.layout()._currentIndex && // If within bounds, ERC721AStorage.layout()._packedOwnerships[tokenId] & BITMASK_BURNED == 0; // and not burned. } /** * @dev Equivalent to `_safeMint(to, quantity, '')`. */ function _safeMint(address to, uint256 quantity) internal { _safeMint(to, quantity, ''); } /** * @dev Safely mints `quantity` tokens and transfers them to `to`. * * Requirements: * * - If `to` refers to a smart contract, it must implement * {IERC721Receiver-onERC721Received}, which is called for each safe transfer. * - `quantity` must be greater than 0. * * Emits a {Transfer} event. */ function _safeMint( address to, uint256 quantity, bytes memory _data ) internal { uint256 startTokenId = ERC721AStorage.layout()._currentIndex; if (_addressToUint256(to) == 0) revert MintToZeroAddress(); if (quantity == 0) revert MintZeroQuantity(); _beforeTokenTransfers(address(0), to, startTokenId, quantity); // Overflows are incredibly unrealistic. // balance or numberMinted overflow if current value of either + quantity > 1.8e19 (2**64) - 1 // updatedIndex overflows if _currentIndex + quantity > 1.2e77 (2**256) - 1 unchecked { // Updates: // - `balance += quantity`. // - `numberMinted += quantity`. // // We can directly add to the balance and number minted. ERC721AStorage.layout()._packedAddressData[to] += quantity * ((1 << BITPOS_NUMBER_MINTED) | 1); // Updates: // - `address` to the owner. // - `startTimestamp` to the timestamp of minting. // - `burned` to `false`. // - `nextInitialized` to `quantity == 1`. ERC721AStorage.layout()._packedOwnerships[startTokenId] = _addressToUint256(to) | (block.timestamp << BITPOS_START_TIMESTAMP) | (_boolToUint256(quantity == 1) << BITPOS_NEXT_INITIALIZED); uint256 updatedIndex = startTokenId; uint256 end = updatedIndex + quantity; if (to.code.length != 0) { do { emit Transfer(address(0), to, updatedIndex); if (!_checkContractOnERC721Received(address(0), to, updatedIndex++, _data)) { revert TransferToNonERC721ReceiverImplementer(); } } while (updatedIndex < end); // Reentrancy protection if (ERC721AStorage.layout()._currentIndex != startTokenId) revert(); } else { do { emit Transfer(address(0), to, updatedIndex++); } while (updatedIndex < end); } ERC721AStorage.layout()._currentIndex = updatedIndex; } _afterTokenTransfers(address(0), to, startTokenId, quantity); } /** * @dev Mints `quantity` tokens and transfers them to `to`. * * Requirements: * * - `to` cannot be the zero address. * - `quantity` must be greater than 0. * * Emits a {Transfer} event. */ function _mint(address to, uint256 quantity) internal { uint256 startTokenId = ERC721AStorage.layout()._currentIndex; if (_addressToUint256(to) == 0) revert MintToZeroAddress(); if (quantity == 0) revert MintZeroQuantity(); _beforeTokenTransfers(address(0), to, startTokenId, quantity); // Overflows are incredibly unrealistic. // balance or numberMinted overflow if current value of either + quantity > 1.8e19 (2**64) - 1 // updatedIndex overflows if _currentIndex + quantity > 1.2e77 (2**256) - 1 unchecked { // Updates: // - `balance += quantity`. // - `numberMinted += quantity`. // // We can directly add to the balance and number minted. ERC721AStorage.layout()._packedAddressData[to] += quantity * ((1 << BITPOS_NUMBER_MINTED) | 1); // Updates: // - `address` to the owner. // - `startTimestamp` to the timestamp of minting. // - `burned` to `false`. // - `nextInitialized` to `quantity == 1`. ERC721AStorage.layout()._packedOwnerships[startTokenId] = _addressToUint256(to) | (block.timestamp << BITPOS_START_TIMESTAMP) | (_boolToUint256(quantity == 1) << BITPOS_NEXT_INITIALIZED); uint256 updatedIndex = startTokenId; uint256 end = updatedIndex + quantity; do { emit Transfer(address(0), to, updatedIndex++); } while (updatedIndex < end); ERC721AStorage.layout()._currentIndex = updatedIndex; } _afterTokenTransfers(address(0), to, startTokenId, quantity); } /** * @dev Transfers `tokenId` from `from` to `to`. * * 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 ) private { uint256 prevOwnershipPacked = _packedOwnershipOf(tokenId); if (address(uint160(prevOwnershipPacked)) != from) revert TransferFromIncorrectOwner(); address approvedAddress = ERC721AStorage.layout()._tokenApprovals[tokenId]; bool isApprovedOrOwner = (_msgSenderERC721A() == from || isApprovedForAll(from, _msgSenderERC721A()) || approvedAddress == _msgSenderERC721A()); if (!isApprovedOrOwner) revert TransferCallerNotOwnerNorApproved(); if (_addressToUint256(to) == 0) revert TransferToZeroAddress(); _beforeTokenTransfers(from, to, tokenId, 1); // Clear approvals from the previous owner. if (_addressToUint256(approvedAddress) != 0) { delete ERC721AStorage.layout()._tokenApprovals[tokenId]; } // Underflow of the sender's balance is impossible because we check for // ownership above and the recipient's balance can't realistically overflow. // Counter overflow is incredibly unrealistic as tokenId would have to be 2**256. unchecked { // We can directly increment and decrement the balances. --ERC721AStorage.layout()._packedAddressData[from]; // Updates: `balance -= 1`. ++ERC721AStorage.layout()._packedAddressData[to]; // Updates: `balance += 1`. // Updates: // - `address` to the next owner. // - `startTimestamp` to the timestamp of transfering. // - `burned` to `false`. // - `nextInitialized` to `true`. ERC721AStorage.layout()._packedOwnerships[tokenId] = _addressToUint256(to) | (block.timestamp << BITPOS_START_TIMESTAMP) | BITMASK_NEXT_INITIALIZED; // If the next slot may not have been initialized (i.e. `nextInitialized == false`) . if (prevOwnershipPacked & BITMASK_NEXT_INITIALIZED == 0) { uint256 nextTokenId = tokenId + 1; // If the next slot's address is zero and not burned (i.e. packed value is zero). if (ERC721AStorage.layout()._packedOwnerships[nextTokenId] == 0) { // If the next slot is within bounds. if (nextTokenId != ERC721AStorage.layout()._currentIndex) { // Initialize the next slot to maintain correctness for `ownerOf(tokenId + 1)`. ERC721AStorage.layout()._packedOwnerships[nextTokenId] = prevOwnershipPacked; } } } } emit Transfer(from, to, tokenId); _afterTokenTransfers(from, to, tokenId, 1); } /** * @dev Equivalent to `_burn(tokenId, false)`. */ function _burn(uint256 tokenId) internal virtual { _burn(tokenId, false); } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ function _burn(uint256 tokenId, bool approvalCheck) internal virtual { uint256 prevOwnershipPacked = _packedOwnershipOf(tokenId); address from = address(uint160(prevOwnershipPacked)); address approvedAddress = ERC721AStorage.layout()._tokenApprovals[tokenId]; if (approvalCheck) { bool isApprovedOrOwner = (_msgSenderERC721A() == from || isApprovedForAll(from, _msgSenderERC721A()) || approvedAddress == _msgSenderERC721A()); if (!isApprovedOrOwner) revert TransferCallerNotOwnerNorApproved(); } _beforeTokenTransfers(from, address(0), tokenId, 1); // Clear approvals from the previous owner. if (_addressToUint256(approvedAddress) != 0) { delete ERC721AStorage.layout()._tokenApprovals[tokenId]; } // Underflow of the sender's balance is impossible because we check for // ownership above and the recipient's balance can't realistically overflow. // Counter overflow is incredibly unrealistic as tokenId would have to be 2**256. unchecked { // Updates: // - `balance -= 1`. // - `numberBurned += 1`. // // We can directly decrement the balance, and increment the number burned. // This is equivalent to `packed -= 1; packed += 1 << BITPOS_NUMBER_BURNED;`. ERC721AStorage.layout()._packedAddressData[from] += (1 << BITPOS_NUMBER_BURNED) - 1; // Updates: // - `address` to the last owner. // - `startTimestamp` to the timestamp of burning. // - `burned` to `true`. // - `nextInitialized` to `true`. ERC721AStorage.layout()._packedOwnerships[tokenId] = _addressToUint256(from) | (block.timestamp << BITPOS_START_TIMESTAMP) | BITMASK_BURNED | BITMASK_NEXT_INITIALIZED; // If the next slot may not have been initialized (i.e. `nextInitialized == false`) . if (prevOwnershipPacked & BITMASK_NEXT_INITIALIZED == 0) { uint256 nextTokenId = tokenId + 1; // If the next slot's address is zero and not burned (i.e. packed value is zero). if (ERC721AStorage.layout()._packedOwnerships[nextTokenId] == 0) { // If the next slot is within bounds. if (nextTokenId != ERC721AStorage.layout()._currentIndex) { // Initialize the next slot to maintain correctness for `ownerOf(tokenId + 1)`. ERC721AStorage.layout()._packedOwnerships[nextTokenId] = prevOwnershipPacked; } } } } emit Transfer(from, address(0), tokenId); _afterTokenTransfers(from, address(0), tokenId, 1); // Overflow not possible, as _burnCounter cannot be exceed _currentIndex times. unchecked { ERC721AStorage.layout()._burnCounter++; } } /** * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target 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 _checkContractOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { try ERC721A__IERC721ReceiverUpgradeable(to).onERC721Received(_msgSenderERC721A(), from, tokenId, _data) returns (bytes4 retval) { return retval == ERC721A__IERC721ReceiverUpgradeable(to).onERC721Received.selector; } catch (bytes memory reason) { if (reason.length == 0) { revert TransferToNonERC721ReceiverImplementer(); } else { assembly { revert(add(32, reason), mload(reason)) } } } } /** * @dev Hook that is called before a set of serially-ordered token ids are about to be transferred. This includes minting. * And also called before burning one token. * * startTokenId - the first token id to be transferred * quantity - the amount to be transferred * * 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, `tokenId` will be burned by `from`. * - `from` and `to` are never both zero. */ function _beforeTokenTransfers( address from, address to, uint256 startTokenId, uint256 quantity ) internal virtual {} /** * @dev Hook that is called after a set of serially-ordered token ids have been transferred. This includes * minting. * And also called after one token has been burned. * * startTokenId - the first token id to be transferred * quantity - the amount to be transferred * * Calling conditions: * * - When `from` and `to` are both non-zero, `from`'s `tokenId` has been * transferred to `to`. * - When `from` is zero, `tokenId` has been minted for `to`. * - When `to` is zero, `tokenId` has been burned by `from`. * - `from` and `to` are never both zero. */ function _afterTokenTransfers( address from, address to, uint256 startTokenId, uint256 quantity ) internal virtual {} /** * @dev Returns the message sender (defaults to `msg.sender`). * * If you are writing GSN compatible contracts, you need to override this function. */ function _msgSenderERC721A() internal view virtual returns (address) { return msg.sender; } /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function _toString(uint256 value) internal pure returns (string memory ptr) { assembly { // The maximum value of a uint256 contains 78 digits (1 byte per digit), // but we allocate 128 bytes to keep the free memory pointer 32-byte word aliged. // We will need 1 32-byte word to store the length, // and 3 32-byte words to store a maximum of 78 digits. Total: 32 + 3 * 32 = 128. ptr := add(mload(0x40), 128) // Update the free memory pointer to allocate. mstore(0x40, ptr) // Cache the end of the memory to calculate the length later. let end := ptr // We write the string from the rightmost digit to the leftmost digit. // The following is essentially a do-while loop that also handles the zero case. // Costs a bit more than early returning for the zero case, // but cheaper in terms of deployment and overall runtime costs. for { // Initialize and perform the first pass without check. let temp := value // Move the pointer 1 byte leftwards to point to an empty character slot. ptr := sub(ptr, 1) // Write the character to the pointer. 48 is the ASCII index of '0'. mstore8(ptr, add(48, mod(temp, 10))) temp := div(temp, 10) } temp { // Keep dividing `temp` until zero. temp := div(temp, 10) } { // Body of the for loop. ptr := sub(ptr, 1) mstore8(ptr, add(48, mod(temp, 10))) } let length := sub(end, ptr) // Move the pointer 32 bytes leftwards to make room for the length. ptr := sub(ptr, 32) // Store the length. mstore(ptr, length) } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/cryptography/ECDSA.sol) pragma solidity ^0.8.0; import "../Strings.sol"; /** * @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations. * * These functions can be used to verify that a message was signed by the holder * of the private keys of a given address. */ library ECDSA { enum RecoverError { NoError, InvalidSignature, InvalidSignatureLength, InvalidSignatureS, InvalidSignatureV } function _throwError(RecoverError error) private pure { if (error == RecoverError.NoError) { return; // no error: do nothing } else if (error == RecoverError.InvalidSignature) { revert("ECDSA: invalid signature"); } else if (error == RecoverError.InvalidSignatureLength) { revert("ECDSA: invalid signature length"); } else if (error == RecoverError.InvalidSignatureS) { revert("ECDSA: invalid signature 's' value"); } else if (error == RecoverError.InvalidSignatureV) { revert("ECDSA: invalid signature 'v' value"); } } /** * @dev Returns the address that signed a hashed message (`hash`) with * `signature` or error string. This address can then be used for verification purposes. * * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures: * this function rejects them by requiring the `s` value to be in the lower * half order, and the `v` value to be either 27 or 28. * * IMPORTANT: `hash` _must_ be the result of a hash operation for the * verification to be secure: it is possible to craft signatures that * recover to arbitrary addresses for non-hashed data. A safe way to ensure * this is by receiving a hash of the original message (which may otherwise * be too long), and then calling {toEthSignedMessageHash} on it. * * Documentation for signature generation: * - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js] * - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers] * * _Available since v4.3._ */ function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError) { // Check the signature length // - case 65: r,s,v signature (standard) // - case 64: r,vs signature (cf https://eips.ethereum.org/EIPS/eip-2098) _Available since v4.1._ if (signature.length == 65) { bytes32 r; bytes32 s; uint8 v; // ecrecover takes the signature parameters, and the only way to get them // currently is to use assembly. assembly { r := mload(add(signature, 0x20)) s := mload(add(signature, 0x40)) v := byte(0, mload(add(signature, 0x60))) } return tryRecover(hash, v, r, s); } else if (signature.length == 64) { bytes32 r; bytes32 vs; // ecrecover takes the signature parameters, and the only way to get them // currently is to use assembly. assembly { r := mload(add(signature, 0x20)) vs := mload(add(signature, 0x40)) } return tryRecover(hash, r, vs); } else { return (address(0), RecoverError.InvalidSignatureLength); } } /** * @dev Returns the address that signed a hashed message (`hash`) with * `signature`. This address can then be used for verification purposes. * * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures: * this function rejects them by requiring the `s` value to be in the lower * half order, and the `v` value to be either 27 or 28. * * IMPORTANT: `hash` _must_ be the result of a hash operation for the * verification to be secure: it is possible to craft signatures that * recover to arbitrary addresses for non-hashed data. A safe way to ensure * this is by receiving a hash of the original message (which may otherwise * be too long), and then calling {toEthSignedMessageHash} on it. */ function recover(bytes32 hash, bytes memory signature) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, signature); _throwError(error); return recovered; } /** * @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately. * * See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures] * * _Available since v4.3._ */ function tryRecover( bytes32 hash, bytes32 r, bytes32 vs ) internal pure returns (address, RecoverError) { bytes32 s; uint8 v; assembly { s := and(vs, 0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff) v := add(shr(255, vs), 27) } return tryRecover(hash, v, r, s); } /** * @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately. * * _Available since v4.2._ */ function recover( bytes32 hash, bytes32 r, bytes32 vs ) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, r, vs); _throwError(error); return recovered; } /** * @dev Overload of {ECDSA-tryRecover} that receives the `v`, * `r` and `s` signature fields separately. * * _Available since v4.3._ */ function tryRecover( bytes32 hash, uint8 v, bytes32 r, bytes32 s ) internal pure returns (address, RecoverError) { // EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature // unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines // the valid range for s in (301): 0 < s < secp256k1n ÷ 2 + 1, and for v in (302): v ∈ {27, 28}. Most // signatures from current libraries generate a unique signature with an s-value in the lower half order. // // If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value // with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or // vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept // these malleable signatures as well. if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) { return (address(0), RecoverError.InvalidSignatureS); } if (v != 27 && v != 28) { return (address(0), RecoverError.InvalidSignatureV); } // If the signature is valid (and not malleable), return the signer address address signer = ecrecover(hash, v, r, s); if (signer == address(0)) { return (address(0), RecoverError.InvalidSignature); } return (signer, RecoverError.NoError); } /** * @dev Overload of {ECDSA-recover} that receives the `v`, * `r` and `s` signature fields separately. */ function recover( bytes32 hash, uint8 v, bytes32 r, bytes32 s ) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, v, r, s); _throwError(error); return recovered; } /** * @dev Returns an Ethereum Signed Message, created from a `hash`. This * produces hash corresponding to the one signed with the * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] * JSON-RPC method as part of EIP-191. * * See {recover}. */ function toEthSignedMessageHash(bytes32 hash) internal pure returns (bytes32) { // 32 is the length in bytes of hash, // enforced by the type signature above return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", hash)); } /** * @dev Returns an Ethereum Signed Message, created from `s`. This * produces hash corresponding to the one signed with the * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] * JSON-RPC method as part of EIP-191. * * See {recover}. */ function toEthSignedMessageHash(bytes memory s) internal pure returns (bytes32) { return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n", Strings.toString(s.length), s)); } /** * @dev Returns an Ethereum Signed Typed Data, created from a * `domainSeparator` and a `structHash`. This produces hash corresponding * to the one signed with the * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`] * JSON-RPC method as part of EIP-712. * * See {recover}. */ function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32) { return keccak256(abi.encodePacked("\x19\x01", domainSeparator, structHash)); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (access/Ownable.sol) pragma solidity ^0.8.0; import "../utils/ContextUpgradeable.sol"; import "../proxy/utils/Initializable.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 OwnableUpgradeable is Initializable, ContextUpgradeable { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ function __Ownable_init() internal onlyInitializing { __Ownable_init_unchained(); } function __Ownable_init_unchained() internal onlyInitializing { _transferOwnership(_msgSender()); } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { 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); } /** * @dev This empty reserved space is put in place to allow future versions to add new * variables without shifting down storage in the inheritance chain. * See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps */ uint256[49] private __gap; }
// SPDX-License-Identifier: MIT // ERC721A Contracts v4.0.0 // Creator: Chiru Labs pragma solidity ^0.8.4; /** * @dev Interface of an ERC721A compliant contract. */ interface IERC721AUpgradeable { /** * The caller must own the token or be an approved operator. */ error ApprovalCallerNotOwnerNorApproved(); /** * The token does not exist. */ error ApprovalQueryForNonexistentToken(); /** * The caller cannot approve to their own address. */ error ApproveToCaller(); /** * The caller cannot approve to the current owner. */ error ApprovalToCurrentOwner(); /** * Cannot query the balance for the zero address. */ error BalanceQueryForZeroAddress(); /** * Cannot mint to the zero address. */ error MintToZeroAddress(); /** * The quantity of tokens minted must be more than zero. */ error MintZeroQuantity(); /** * The token does not exist. */ error OwnerQueryForNonexistentToken(); /** * The caller must own the token or be an approved operator. */ error TransferCallerNotOwnerNorApproved(); /** * The token must be owned by `from`. */ error TransferFromIncorrectOwner(); /** * Cannot safely transfer to a contract that does not implement the ERC721Receiver interface. */ error TransferToNonERC721ReceiverImplementer(); /** * Cannot transfer to the zero address. */ error TransferToZeroAddress(); /** * The token does not exist. */ error URIQueryForNonexistentToken(); struct TokenOwnership { // The address of the owner. address addr; // Keeps track of the start time of ownership with minimal overhead for tokenomics. uint64 startTimestamp; // Whether the token has been burned. bool burned; } /** * @dev Returns the total amount of tokens stored by the contract. * * Burned tokens are calculated here, use `_totalMinted()` if you want to count just minted tokens. */ function totalSupply() external view returns (uint256); // ============================== // 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); // ============================== // IERC721 // ============================== /** * @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 be 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); // ============================== // IERC721Metadata // ============================== /** * @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 pragma solidity ^0.8.0; import {ERC721AUpgradeable} from './ERC721AUpgradeable.sol'; library ERC721AStorage { struct Layout { // The tokenId of the next token to be minted. uint256 _currentIndex; // The number of tokens burned. uint256 _burnCounter; // Token name string _name; // Token symbol string _symbol; // Mapping from token ID to ownership details // An empty struct value does not necessarily mean the token is unowned. // See `_packedOwnershipOf` implementation for details. // // Bits Layout: // - [0..159] `addr` // - [160..223] `startTimestamp` // - [224] `burned` // - [225] `nextInitialized` mapping(uint256 => uint256) _packedOwnerships; // Mapping owner address to address data. // // Bits Layout: // - [0..63] `balance` // - [64..127] `numberMinted` // - [128..191] `numberBurned` // - [192..255] `aux` mapping(address => uint256) _packedAddressData; // Mapping from token ID to approved address. mapping(uint256 => address) _tokenApprovals; // Mapping from owner to operator approvals mapping(address => mapping(address => bool)) _operatorApprovals; } bytes32 internal constant STORAGE_SLOT = keccak256('ERC721A.contracts.storage.ERC721A'); function layout() internal pure returns (Layout storage l) { bytes32 slot = STORAGE_SLOT; assembly { l.slot := slot } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev This is a base contract to aid in writing upgradeable diamond facet contracts, or any kind of contract that will be deployed * behind a proxy. Since proxied contracts do not make use of a constructor, it's common to move constructor logic to an * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect. * * TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as * possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}. * * CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure * that all initializers are idempotent. This is not verified automatically as constructors are by Solidity. */ import {ERC721A__InitializableStorage} from './ERC721A__InitializableStorage.sol'; abstract contract ERC721A__Initializable { using ERC721A__InitializableStorage for ERC721A__InitializableStorage.Layout; /** * @dev Modifier to protect an initializer function from being invoked twice. */ modifier initializerERC721A() { // If the contract is initializing we ignore whether _initialized is set in order to support multiple // inheritance patterns, but we only do this in the context of a constructor, because in other contexts the // contract may have been reentered. require( ERC721A__InitializableStorage.layout()._initializing ? _isConstructor() : !ERC721A__InitializableStorage.layout()._initialized, 'ERC721A__Initializable: contract is already initialized' ); bool isTopLevelCall = !ERC721A__InitializableStorage.layout()._initializing; if (isTopLevelCall) { ERC721A__InitializableStorage.layout()._initializing = true; ERC721A__InitializableStorage.layout()._initialized = true; } _; if (isTopLevelCall) { ERC721A__InitializableStorage.layout()._initializing = false; } } /** * @dev Modifier to protect an initialization function so that it can only be invoked by functions with the * {initializer} modifier, directly or indirectly. */ modifier onlyInitializingERC721A() { require( ERC721A__InitializableStorage.layout()._initializing, 'ERC721A__Initializable: contract is not initializing' ); _; } /// @dev Returns true if and only if the function is running in the constructor function _isConstructor() private view returns (bool) { // extcodesize checks the size of the code stored in an address, and // address returns the current address. Since the code is still not // deployed when running a constructor, any checks on its code size will // yield zero, making it an effective way to detect if a contract is // under construction or not. address self = address(this); uint256 cs; assembly { cs := extcodesize(self) } return cs == 0; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev This is a base storage for the initialization function for upgradeable diamond facet contracts **/ library ERC721A__InitializableStorage { struct Layout { /* * Indicates that the contract has been initialized. */ bool _initialized; /* * Indicates that the contract is in the process of being initialized. */ bool _initializing; } bytes32 internal constant STORAGE_SLOT = keccak256('ERC721A.contracts.storage.initializable.facet'); function layout() internal pure returns (Layout storage l) { bytes32 slot = STORAGE_SLOT; assembly { l.slot := slot } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Strings.sol) pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @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); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) pragma solidity ^0.8.0; import "../proxy/utils/Initializable.sol"; /** * @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 ContextUpgradeable is Initializable { function __Context_init() internal onlyInitializing { } function __Context_init_unchained() internal onlyInitializing { } function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } /** * @dev This empty reserved space is put in place to allow future versions to add new * variables without shifting down storage in the inheritance chain. * See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps */ uint256[50] private __gap; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (proxy/utils/Initializable.sol) pragma solidity ^0.8.2; import "../../utils/AddressUpgradeable.sol"; /** * @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed * behind a proxy. Since proxied contracts do not make use of a constructor, it's common to move constructor logic to an * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect. * * The initialization functions use a version number. Once a version number is used, it is consumed and cannot be * reused. This mechanism prevents re-execution of each "step" but allows the creation of new initialization steps in * case an upgrade adds a module that needs to be initialized. * * For example: * * [.hljs-theme-light.nopadding] * ``` * contract MyToken is ERC20Upgradeable { * function initialize() initializer public { * __ERC20_init("MyToken", "MTK"); * } * } * contract MyTokenV2 is MyToken, ERC20PermitUpgradeable { * function initializeV2() reinitializer(2) public { * __ERC20Permit_init("MyToken"); * } * } * ``` * * TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as * possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}. * * CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure * that all initializers are idempotent. This is not verified automatically as constructors are by Solidity. * * [CAUTION] * ==== * Avoid leaving a contract uninitialized. * * An uninitialized contract can be taken over by an attacker. This applies to both a proxy and its implementation * contract, which may impact the proxy. To prevent the implementation contract from being used, you should invoke * the {_disableInitializers} function in the constructor to automatically lock it when it is deployed: * * [.hljs-theme-light.nopadding] * ``` * /// @custom:oz-upgrades-unsafe-allow constructor * constructor() { * _disableInitializers(); * } * ``` * ==== */ abstract contract Initializable { /** * @dev Indicates that the contract has been initialized. * @custom:oz-retyped-from bool */ uint8 private _initialized; /** * @dev Indicates that the contract is in the process of being initialized. */ bool private _initializing; /** * @dev Triggered when the contract has been initialized or reinitialized. */ event Initialized(uint8 version); /** * @dev A modifier that defines a protected initializer function that can be invoked at most once. In its scope, * `onlyInitializing` functions can be used to initialize parent contracts. Equivalent to `reinitializer(1)`. */ modifier initializer() { bool isTopLevelCall = _setInitializedVersion(1); if (isTopLevelCall) { _initializing = true; } _; if (isTopLevelCall) { _initializing = false; emit Initialized(1); } } /** * @dev A modifier that defines a protected reinitializer function that can be invoked at most once, and only if the * contract hasn't been initialized to a greater version before. In its scope, `onlyInitializing` functions can be * used to initialize parent contracts. * * `initializer` is equivalent to `reinitializer(1)`, so a reinitializer may be used after the original * initialization step. This is essential to configure modules that are added through upgrades and that require * initialization. * * Note that versions can jump in increments greater than 1; this implies that if multiple reinitializers coexist in * a contract, executing them in the right order is up to the developer or operator. */ modifier reinitializer(uint8 version) { bool isTopLevelCall = _setInitializedVersion(version); if (isTopLevelCall) { _initializing = true; } _; if (isTopLevelCall) { _initializing = false; emit Initialized(version); } } /** * @dev Modifier to protect an initialization function so that it can only be invoked by functions with the * {initializer} and {reinitializer} modifiers, directly or indirectly. */ modifier onlyInitializing() { require(_initializing, "Initializable: contract is not initializing"); _; } /** * @dev Locks the contract, preventing any future reinitialization. This cannot be part of an initializer call. * Calling this in the constructor of a contract will prevent that contract from being initialized or reinitialized * to any version. It is recommended to use this to lock implementation contracts that are designed to be called * through proxies. */ function _disableInitializers() internal virtual { _setInitializedVersion(type(uint8).max); } function _setInitializedVersion(uint8 version) private returns (bool) { // If the contract is initializing we ignore whether _initialized is set in order to support multiple // inheritance patterns, but we only do this in the context of a constructor, and for the lowest level // of initializers, because in other contexts the contract may have been reentered. if (_initializing) { require( version == 1 && !AddressUpgradeable.isContract(address(this)), "Initializable: contract is already initialized" ); return false; } else { require(_initialized < version, "Initializable: contract is already initialized"); _initialized = version; return true; } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.5.0) (utils/Address.sol) pragma solidity ^0.8.1; /** * @dev Collection of functions related to the address type */ library AddressUpgradeable { /** * @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 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 assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
{ "optimizer": { "enabled": true, "runs": 10000 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[],"name":"ApprovalCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"ApprovalQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"ApprovalToCurrentOwner","type":"error"},{"inputs":[],"name":"ApproveToCaller","type":"error"},{"inputs":[],"name":"BalanceQueryForZeroAddress","type":"error"},{"inputs":[],"name":"MintToZeroAddress","type":"error"},{"inputs":[],"name":"MintZeroQuantity","type":"error"},{"inputs":[],"name":"OwnerQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"TransferCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"TransferFromIncorrectOwner","type":"error"},{"inputs":[],"name":"TransferToNonERC721ReceiverImplementer","type":"error"},{"inputs":[],"name":"TransferToZeroAddress","type":"error"},{"inputs":[],"name":"URIQueryForNonexistentToken","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":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","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":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"},{"inputs":[{"components":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"symbol","type":"string"},{"internalType":"uint256","name":"maxSupply","type":"uint256"},{"internalType":"address","name":"signer","type":"address"},{"internalType":"string","name":"baseURI","type":"string"},{"internalType":"uint256","name":"publicMintLimit","type":"uint256"},{"internalType":"uint256","name":"publicMintPrice","type":"uint256"},{"internalType":"bool","name":"publicMintEnabled","type":"bool"},{"internalType":"bool","name":"approveListMintingEnabled","type":"bool"},{"internalType":"address","name":"squshyLabsAddress","type":"address"},{"internalType":"uint256","name":"commission","type":"uint256"},{"internalType":"address","name":"implementationAddress","type":"address"},{"internalType":"address","name":"withdrawalAddress","type":"address"}],"internalType":"struct Config","name":"_config","type":"tuple"}],"name":"_initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"allowedAmount","type":"uint256"},{"internalType":"address","name":"mintAddress","type":"address"}],"name":"allowListMint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"approveListMintingEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","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":[],"name":"commission","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"symbol","type":"string"},{"internalType":"uint256","name":"maxSupply","type":"uint256"},{"internalType":"address","name":"signer","type":"address"},{"internalType":"string","name":"baseURI","type":"string"},{"internalType":"uint256","name":"publicMintLimit","type":"uint256"},{"internalType":"uint256","name":"publicMintPrice","type":"uint256"},{"internalType":"bool","name":"publicMintEnabled","type":"bool"},{"internalType":"bool","name":"approveListMintingEnabled","type":"bool"},{"internalType":"address","name":"squshyLabsAddress","type":"address"},{"internalType":"uint256","name":"commission","type":"uint256"},{"internalType":"address","name":"implementationAddress","type":"address"},{"internalType":"address","name":"withdrawalAddress","type":"address"}],"internalType":"struct Config","name":"_config","type":"tuple"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","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":"maxSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"address","name":"mintAddress","type":"address"}],"name":"mint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"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":"publicMintEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"publicMintLimit","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"publicMintPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","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":"uint256","name":"_publicMintLimit","type":"uint256"},{"internalType":"uint256","name":"_publicMintPrice","type":"uint256"},{"internalType":"bool","name":"_publicMintEnabled","type":"bool"},{"internalType":"bool","name":"_approveListMintingEnabled","type":"bool"}],"name":"setMintConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_newBaseURI","type":"string"}],"name":"setURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"squshyLabsAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"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":[],"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":[{"internalType":"address","name":"_signer","type":"address"}],"name":"updateSigner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"withdrawalAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
608060405234801561001057600080fd5b50613225806100206000396000f3fe6080604052600436106102195760003560e01c806394bf804d1161011d578063d5abeb01116100b0578063edb387d11161007f578063f2fde38b11610064578063f2fde38b14610634578063f329cc2414610654578063fd0a10c01461067457600080fd5b8063edb387d1146105f4578063f2bcd0221461061457600080fd5b8063d5abeb011461054a578063dc53fd9214610560578063e148919114610576578063e985e9c51461058c57600080fd5b8063abcfa886116100ec578063abcfa886146104da578063b88d4fde146104f4578063bb485b8814610514578063c87b56dd1461052a57600080fd5b806394bf804d1461047257806395d89b4114610485578063a22cb4651461049a578063a7ecd37e146104ba57600080fd5b806323b872dd116101b05780636352211e1161017f57806370a082311161016457806370a082311461041f578063715018a61461043f5780638da5cb5b1461045457600080fd5b80636352211e146103ea5780636c0360eb1461040a57600080fd5b806323b872dd146103825780633ccfd60b146103a257806341744674146103aa57806342842e0e146103ca57600080fd5b8063095ea7b3116101ec578063095ea7b3146102cf5780630f4161aa146102ef57806318160ddd1461030e5780631df9eb371461036f57600080fd5b806301ffc9a71461021e57806302fe53051461025357806306fdde0314610275578063081812fc14610297575b600080fd5b34801561022a57600080fd5b5061023e610239366004612ccc565b610694565b60405190151581526020015b60405180910390f35b34801561025f57600080fd5b5061027361026e366004612d04565b610779565b005b34801561028157600080fd5b5061028a6107ef565b60405161024a9190613018565b3480156102a357600080fd5b506102b76102b2366004612e86565b6108a3565b6040516001600160a01b03909116815260200161024a565b3480156102db57600080fd5b506102736102ea366004612ca3565b61091f565b3480156102fb57600080fd5b5060675461023e90610100900460ff1681565b34801561031a57600080fd5b507f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c41547f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4054035b60405190815260200161024a565b61027361037d366004612f05565b610a97565b34801561038e57600080fd5b5061027361039d366004612bc6565b610d69565b610273610d79565b3480156103b657600080fd5b506102736103c5366004612d37565b610dc3565b3480156103d657600080fd5b506102736103e5366004612bc6565b6110c3565b3480156103f657600080fd5b506102b7610405366004612e86565b6110de565b34801561041657600080fd5b5061028a6110e9565b34801561042b57600080fd5b5061036161043a366004612b7a565b611177565b34801561044b57600080fd5b506102736111f5565b34801561046057600080fd5b506033546001600160a01b03166102b7565b610273610480366004612e9e565b611259565b34801561049157600080fd5b5061028a611522565b3480156104a657600080fd5b506102736104b5366004612c7a565b611553565b3480156104c657600080fd5b506102736104d5366004612b7a565b61163f565b3480156104e657600080fd5b5060675461023e9060ff1681565b34801561050057600080fd5b5061027361050f366004612c01565b6116d3565b34801561052057600080fd5b5061036160695481565b34801561053657600080fd5b5061028a610545366004612e86565b611736565b34801561055657600080fd5b5061036160655481565b34801561056c57600080fd5b5061036160685481565b34801561058257600080fd5b50610361606c5481565b34801561059857600080fd5b5061023e6105a7366004612b94565b6001600160a01b0391821660009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c476020908152604080832093909416825291909152205460ff1690565b34801561060057600080fd5b50606a546102b7906001600160a01b031681565b34801561062057600080fd5b50606b546102b7906001600160a01b031681565b34801561064057600080fd5b5061027361064f366004612b7a565b6117d4565b34801561066057600080fd5b5061027361066f366004612d37565b6118b6565b34801561068057600080fd5b5061027361068f366004612ec0565b611966565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316148061072757507f80ac58cd000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b8061077357507f5b5e139f000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b92915050565b6033546001600160a01b031633146107d85760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064015b60405180910390fd5b80516107eb906066906020840190612a07565b5050565b60607f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4060020180546108209061310f565b80601f016020809104026020016040519081016040528092919081815260200182805461084c9061310f565b80156108995780601f1061086e57610100808354040283529160200191610899565b820191906000526020600020905b81548152906001019060200180831161087c57829003601f168201915b5050505050905090565b60006108ae82611a2c565b6108e4576040517fcf4700e400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5060009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4660205260409020546001600160a01b031690565b600061092a82611aab565b9050806001600160a01b0316836001600160a01b03161415610978576040517f943f7b8c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336001600160a01b03821614610a04576001600160a01b03811660009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c476020908152604080832033845290915290205460ff16610a04576040517fcfb3b94200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c46602052604080822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0387811691821790925591518593918516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591a4505050565b60675460ff16610b0f5760405162461bcd60e51b815260206004820152603760248201527f434f4e5452414354204552524f523a20616c6c6f77206c697374206d696e746960448201527f6e6720686173206e6f74206265656e20656e61626c656400000000000000000060648201526084016107cf565b8183610b5d836001600160a01b031660009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4560205260409081902054901c67ffffffffffffffff1690565b610b679190613055565b1115610bdb5760405162461bcd60e51b815260206004820152603660248201527f434f4e5452414354204552524f523a20416464726573732068617320616c726560448201527f61647920636c61696d6564206d617820616d6f756e740000000000000000000060648201526084016107cf565b60655483610c2a7f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c41547f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c40540390565b610c349190613055565b1115610cce5760405162461bcd60e51b815260206004820152604d60248201527f434f4e5452414354204552524f523a206e6f7420656e6f7567682072656d616960448201527f6e696e6720696e20737570706c7920746f20737570706f72742064657369726560648201527f64206d696e7420616d6f756e7400000000000000000000000000000000000000608482015260a4016107cf565b610ce5610cdd82858534611bb9565b878787611c10565b610d575760405162461bcd60e51b815260206004820152602160248201527f434f4e5452414354204552524f523a20496e76616c6964207369676e6174757260448201527f650000000000000000000000000000000000000000000000000000000000000060648201526084016107cf565b610d618184611c91565b505050505050565b610d74838383611cab565b505050565b606a54606c54610dab916001600160a01b0316906103e890610d9c9047906130a6565b610da6919061306d565b612009565b606b54610dc1906001600160a01b031647612009565b565b7fee151c8401928dc223602bb187aff91b9a56c7cae5476ef1b3287b085a16c85f54610100900460ff16610e1c577fee151c8401928dc223602bb187aff91b9a56c7cae5476ef1b3287b085a16c85f5460ff1615610e20565b303b155b610e925760405162461bcd60e51b815260206004820152603760248201527f455243373231415f5f496e697469616c697a61626c653a20636f6e747261637460448201527f20697320616c726561647920696e697469616c697a656400000000000000000060648201526084016107cf565b7fee151c8401928dc223602bb187aff91b9a56c7cae5476ef1b3287b085a16c85f54610100900460ff16158015610f0f577fee151c8401928dc223602bb187aff91b9a56c7cae5476ef1b3287b085a16c85f80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000166101011790555b6000610f1b6001612122565b90508015610f5057600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555b610f6283600001518460200151612279565b610f6a61231f565b610f778360800151610779565b6060830151606d80546001600160a01b039283167fffffffffffffffffffffffff0000000000000000000000000000000000000000918216179091556040850151606555610140850151606c55610120850151606a8054918416918316919091179055610180850151606b805491909316911617905560a083015160c084015160e085015161010086015161100e93929190611966565b801561107157600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5080156107eb5750507fee151c8401928dc223602bb187aff91b9a56c7cae5476ef1b3287b085a16c85f80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055565b610d74838383604051806020016040528060008152506116d3565b600061077382611aab565b606680546110f69061310f565b80601f01602080910402602001604051908101604052809291908181526020018280546111229061310f565b801561116f5780601f106111445761010080835404028352916020019161116f565b820191906000526020600020905b81548152906001019060200180831161115257829003601f168201915b505050505081565b6000816111b0576040517f8f4eb60400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b506001600160a01b031660009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c45602052604090205467ffffffffffffffff1690565b6033546001600160a01b0316331461124f5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107cf565b610dc160006123a4565b606754610100900460ff166112d65760405162461bcd60e51b815260206004820152602c60248201527f434f4e5452414354204552524f523a206d696e74696e6720686173206e6f742060448201527f6265656e20656e61626c6564000000000000000000000000000000000000000060648201526084016107cf565b60695482611326836001600160a01b031660009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4560205260409081902054901c67ffffffffffffffff1690565b6113309190613055565b11156113a45760405162461bcd60e51b815260206004820152603660248201527f434f4e5452414354204552524f523a20416464726573732068617320616c726560448201527f61647920636c61696d6564206d617820616d6f756e740000000000000000000060648201526084016107cf565b606554826113f37f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c41547f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c40540390565b6113fd9190613055565b11156114975760405162461bcd60e51b815260206004820152604d60248201527f434f4e5452414354204552524f523a206e6f7420656e6f7567682072656d616960448201527f6e696e6720696e20737570706c7920746f20737570706f72742064657369726560648201527f64206d696e7420616d6f756e7400000000000000000000000000000000000000608482015260a4016107cf565b6068546114a490836130a6565b34146115185760405162461bcd60e51b815260206004820152602560248201527f434f4e5452414354204552524f523a206e6f7420656e6f75676820657468657260448201527f2073656e7400000000000000000000000000000000000000000000000000000060648201526084016107cf565b6107eb8183611c91565b60607f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4060030180546108209061310f565b6001600160a01b038216331415611596576040517fb06307db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3360008181527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c47602090815260408083206001600160a01b0387168085529083529281902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b6033546001600160a01b031633146116995760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107cf565b606d80547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0392909216919091179055565b6116de848484611cab565b6001600160a01b0383163b15611730576116fa8484848461240e565b611730576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50505050565b606061174182611a2c565b611777576040517fa14c4b5000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611781612583565b90508051600014156117a257604051806020016040528060008152506117cd565b806117ac84612592565b6040516020016117bd929190612fad565b6040516020818303038152906040525b9392505050565b6033546001600160a01b0316331461182e5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107cf565b6001600160a01b0381166118aa5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084016107cf565b6118b3816123a4565b50565b60006118c26001612122565b905080156118f757600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555b61190082610dc3565b80156107eb57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b6033546001600160a01b031633146119c05760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107cf565b606993909355606891909155606780549215157fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0092151561010002929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090931692909217179055565b60007f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c40548210801561077357505060009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4460205260409020547c0100000000000000000000000000000000000000000000000000000000161590565b6000817f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4054811015611b875760008181527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4460205260409020547c01000000000000000000000000000000000000000000000000000000008116611b85575b806117cd57507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0160008181527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c446020526040902054611b2a565b505b6040517fdf2d9b4200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604080513060208201526001600160a01b03861691810191909152606081018490526080810183905260a0810182905260009060c0016040516020818303038152906040528051906020012090505b949350505050565b606d546040805160008082526020820180845288905260ff871692820192909252606081018590526080810184905290916001600160a01b03169060019060a0016020604051602081039080840390855afa158015611c73573d6000803e3d6000fd5b505050602060405103516001600160a01b0316149050949350505050565b6107eb8282604051806020016040528060008152506125ff565b6000611cb682611aab565b9050836001600160a01b0316816001600160a01b031614611d03576040517fa114810000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4660205260408120546001600160a01b0390811691908616331480611d8f57506001600160a01b03861660009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c476020908152604080832033845290915290205460ff165b80611da257506001600160a01b03821633145b905080611ddb576040517f59c896be00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b84611e12576040517fea553b3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8115611e6c5760008481527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c466020526040902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001690555b6001600160a01b0386811660009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c456020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190559288168252828220805460010190558682527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c449052207c02000000000000000000000000000000000000000000000000000000004260a01b871781179091558316611fc3576001840160008181527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c446020526040902054611fc1577f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c40548114611fc15760008181527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c44602052604090208490555b505b83856001600160a01b0316876001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4610d61565b804710156120595760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e636500000060448201526064016107cf565b6000826001600160a01b03168260405160006040518083038185875af1925050503d80600081146120a6576040519150601f19603f3d011682016040523d82523d6000602084013e6120ab565b606091505b5050905080610d745760405162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d6179206861766520726576657274656400000000000060648201526084016107cf565b60008054610100900460ff16156121bf578160ff1660011480156121455750303b155b6121b75760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016107cf565b506000919050565b60005460ff80841691161061223c5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016107cf565b50600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff92909216919091179055600190565b919050565b7fee151c8401928dc223602bb187aff91b9a56c7cae5476ef1b3287b085a16c85f54610100900460ff166123155760405162461bcd60e51b815260206004820152603460248201527f455243373231415f5f496e697469616c697a61626c653a20636f6e747261637460448201527f206973206e6f7420696e697469616c697a696e6700000000000000000000000060648201526084016107cf565b6107eb8282612857565b600054610100900460ff1661239c5760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016107cf565b610dc1612981565b603380546001600160a01b038381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6040517f150b7a020000000000000000000000000000000000000000000000000000000081526000906001600160a01b0385169063150b7a029061245c903390899088908890600401612fdc565b602060405180830381600087803b15801561247657600080fd5b505af19250505080156124c4575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682019092526124c191810190612ce8565b60015b612538573d8080156124f2576040519150601f19603f3d011682016040523d82523d6000602084013e6124f7565b606091505b508051612530576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805181602001fd5b7fffffffff00000000000000000000000000000000000000000000000000000000167f150b7a0200000000000000000000000000000000000000000000000000000000149050611c08565b6060606680546108209061310f565b604080516080810191829052607f0190826030600a8206018353600a90045b80156125cf57600183039250600a81066030018353600a90046125b1565b508190037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0909101908152919050565b7f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c405483612658576040517f2e07630000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8261268f576040517fb562e8dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b03841660009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4560205260409020805468010000000000000001850201905560e16001841460008381527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4460205260409020911b4260a01b8617179055808381016001600160a01b0386163b156127e4575b60405182906001600160a01b038816906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a4612775600087848060010195508761240e565b6127ab576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80821061272a57827f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4054146127df57600080fd5b612829565b5b6040516001830192906001600160a01b038816906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a48082106127e5575b507f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4055611730600085838684565b7fee151c8401928dc223602bb187aff91b9a56c7cae5476ef1b3287b085a16c85f54610100900460ff166128f35760405162461bcd60e51b815260206004820152603460248201527f455243373231415f5f496e697469616c697a61626c653a20636f6e747261637460448201527f206973206e6f7420696e697469616c697a696e6700000000000000000000000060648201526084016107cf565b8151612925907f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c42906020850190612a07565b508051612958907f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c43906020840190612a07565b5060007f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c40555050565b600054610100900460ff166129fe5760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016107cf565b610dc1336123a4565b828054612a139061310f565b90600052602060002090601f016020900481019282612a355760008555612a7b565b82601f10612a4e57805160ff1916838001178555612a7b565b82800160010185558215612a7b579182015b82811115612a7b578251825591602001919060010190612a60565b50612a87929150612a8b565b5090565b5b80821115612a875760008155600101612a8c565b600067ffffffffffffffff80841115612abb57612abb613192565b604051601f85017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908282118183101715612b0157612b01613192565b81604052809350858152868686011115612b1a57600080fd5b858560208301376000602087830101525050509392505050565b80356001600160a01b038116811461227457600080fd5b8035801515811461227457600080fd5b600082601f830112612b6b578081fd5b6117cd83833560208501612aa0565b600060208284031215612b8b578081fd5b6117cd82612b34565b60008060408385031215612ba6578081fd5b612baf83612b34565b9150612bbd60208401612b34565b90509250929050565b600080600060608486031215612bda578081fd5b612be384612b34565b9250612bf160208501612b34565b9150604084013590509250925092565b60008060008060808587031215612c16578081fd5b612c1f85612b34565b9350612c2d60208601612b34565b925060408501359150606085013567ffffffffffffffff811115612c4f578182fd5b8501601f81018713612c5f578182fd5b612c6e87823560208401612aa0565b91505092959194509250565b60008060408385031215612c8c578182fd5b612c9583612b34565b9150612bbd60208401612b4b565b60008060408385031215612cb5578182fd5b612cbe83612b34565b946020939093013593505050565b600060208284031215612cdd578081fd5b81356117cd816131c1565b600060208284031215612cf9578081fd5b81516117cd816131c1565b600060208284031215612d15578081fd5b813567ffffffffffffffff811115612d2b578182fd5b611c0884828501612b5b565b600060208284031215612d48578081fd5b813567ffffffffffffffff80821115612d5f578283fd5b908301906101a08286031215612d73578283fd5b612d7b61302b565b823582811115612d89578485fd5b612d9587828601612b5b565b825250602083013582811115612da9578485fd5b612db587828601612b5b565b60208301525060408301356040820152612dd160608401612b34565b6060820152608083013582811115612de7578485fd5b612df387828601612b5b565b60808301525060a083013560a082015260c083013560c0820152612e1960e08401612b4b565b60e08201526101009150612e2e828401612b4b565b828201526101209150612e42828401612b34565b82820152610140915081830135828201526101609150612e63828401612b34565b828201526101809150612e77828401612b34565b91810191909152949350505050565b600060208284031215612e97578081fd5b5035919050565b60008060408385031215612eb0578182fd5b82359150612bbd60208401612b34565b60008060008060808587031215612ed5578182fd5b8435935060208501359250612eec60408601612b4b565b9150612efa60608601612b4b565b905092959194509250565b60008060008060008060c08789031215612f1d578384fd5b863560ff81168114612f2d578485fd5b955060208701359450604087013593506060870135925060808701359150612f5760a08801612b34565b90509295509295509295565b60008151808452612f7b8160208601602086016130e3565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60008351612fbf8184602088016130e3565b835190830190612fd38183602088016130e3565b01949350505050565b60006001600160a01b0380871683528086166020840152508360408301526080606083015261300e6080830184612f63565b9695505050505050565b6020815260006117cd6020830184612f63565b6040516101a0810167ffffffffffffffff8111828210171561304f5761304f613192565b60405290565b6000821982111561306857613068613163565b500190565b6000826130a1577f4e487b710000000000000000000000000000000000000000000000000000000081526012600452602481fd5b500490565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156130de576130de613163565b500290565b60005b838110156130fe5781810151838201526020016130e6565b838111156117305750506000910152565b600181811c9082168061312357607f821691505b6020821081141561315d577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7fffffffff00000000000000000000000000000000000000000000000000000000811681146118b357600080fdfea26469706673582212207db246e58074412286ce96d0f63a4d2b1f0927de8d477ab8de6bb8a4551e05b964736f6c63430008040033
Deployed Bytecode
0x6080604052600436106102195760003560e01c806394bf804d1161011d578063d5abeb01116100b0578063edb387d11161007f578063f2fde38b11610064578063f2fde38b14610634578063f329cc2414610654578063fd0a10c01461067457600080fd5b8063edb387d1146105f4578063f2bcd0221461061457600080fd5b8063d5abeb011461054a578063dc53fd9214610560578063e148919114610576578063e985e9c51461058c57600080fd5b8063abcfa886116100ec578063abcfa886146104da578063b88d4fde146104f4578063bb485b8814610514578063c87b56dd1461052a57600080fd5b806394bf804d1461047257806395d89b4114610485578063a22cb4651461049a578063a7ecd37e146104ba57600080fd5b806323b872dd116101b05780636352211e1161017f57806370a082311161016457806370a082311461041f578063715018a61461043f5780638da5cb5b1461045457600080fd5b80636352211e146103ea5780636c0360eb1461040a57600080fd5b806323b872dd146103825780633ccfd60b146103a257806341744674146103aa57806342842e0e146103ca57600080fd5b8063095ea7b3116101ec578063095ea7b3146102cf5780630f4161aa146102ef57806318160ddd1461030e5780631df9eb371461036f57600080fd5b806301ffc9a71461021e57806302fe53051461025357806306fdde0314610275578063081812fc14610297575b600080fd5b34801561022a57600080fd5b5061023e610239366004612ccc565b610694565b60405190151581526020015b60405180910390f35b34801561025f57600080fd5b5061027361026e366004612d04565b610779565b005b34801561028157600080fd5b5061028a6107ef565b60405161024a9190613018565b3480156102a357600080fd5b506102b76102b2366004612e86565b6108a3565b6040516001600160a01b03909116815260200161024a565b3480156102db57600080fd5b506102736102ea366004612ca3565b61091f565b3480156102fb57600080fd5b5060675461023e90610100900460ff1681565b34801561031a57600080fd5b507f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c41547f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4054035b60405190815260200161024a565b61027361037d366004612f05565b610a97565b34801561038e57600080fd5b5061027361039d366004612bc6565b610d69565b610273610d79565b3480156103b657600080fd5b506102736103c5366004612d37565b610dc3565b3480156103d657600080fd5b506102736103e5366004612bc6565b6110c3565b3480156103f657600080fd5b506102b7610405366004612e86565b6110de565b34801561041657600080fd5b5061028a6110e9565b34801561042b57600080fd5b5061036161043a366004612b7a565b611177565b34801561044b57600080fd5b506102736111f5565b34801561046057600080fd5b506033546001600160a01b03166102b7565b610273610480366004612e9e565b611259565b34801561049157600080fd5b5061028a611522565b3480156104a657600080fd5b506102736104b5366004612c7a565b611553565b3480156104c657600080fd5b506102736104d5366004612b7a565b61163f565b3480156104e657600080fd5b5060675461023e9060ff1681565b34801561050057600080fd5b5061027361050f366004612c01565b6116d3565b34801561052057600080fd5b5061036160695481565b34801561053657600080fd5b5061028a610545366004612e86565b611736565b34801561055657600080fd5b5061036160655481565b34801561056c57600080fd5b5061036160685481565b34801561058257600080fd5b50610361606c5481565b34801561059857600080fd5b5061023e6105a7366004612b94565b6001600160a01b0391821660009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c476020908152604080832093909416825291909152205460ff1690565b34801561060057600080fd5b50606a546102b7906001600160a01b031681565b34801561062057600080fd5b50606b546102b7906001600160a01b031681565b34801561064057600080fd5b5061027361064f366004612b7a565b6117d4565b34801561066057600080fd5b5061027361066f366004612d37565b6118b6565b34801561068057600080fd5b5061027361068f366004612ec0565b611966565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316148061072757507f80ac58cd000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b8061077357507f5b5e139f000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b92915050565b6033546001600160a01b031633146107d85760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064015b60405180910390fd5b80516107eb906066906020840190612a07565b5050565b60607f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4060020180546108209061310f565b80601f016020809104026020016040519081016040528092919081815260200182805461084c9061310f565b80156108995780601f1061086e57610100808354040283529160200191610899565b820191906000526020600020905b81548152906001019060200180831161087c57829003601f168201915b5050505050905090565b60006108ae82611a2c565b6108e4576040517fcf4700e400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5060009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4660205260409020546001600160a01b031690565b600061092a82611aab565b9050806001600160a01b0316836001600160a01b03161415610978576040517f943f7b8c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336001600160a01b03821614610a04576001600160a01b03811660009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c476020908152604080832033845290915290205460ff16610a04576040517fcfb3b94200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c46602052604080822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0387811691821790925591518593918516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591a4505050565b60675460ff16610b0f5760405162461bcd60e51b815260206004820152603760248201527f434f4e5452414354204552524f523a20616c6c6f77206c697374206d696e746960448201527f6e6720686173206e6f74206265656e20656e61626c656400000000000000000060648201526084016107cf565b8183610b5d836001600160a01b031660009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4560205260409081902054901c67ffffffffffffffff1690565b610b679190613055565b1115610bdb5760405162461bcd60e51b815260206004820152603660248201527f434f4e5452414354204552524f523a20416464726573732068617320616c726560448201527f61647920636c61696d6564206d617820616d6f756e740000000000000000000060648201526084016107cf565b60655483610c2a7f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c41547f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c40540390565b610c349190613055565b1115610cce5760405162461bcd60e51b815260206004820152604d60248201527f434f4e5452414354204552524f523a206e6f7420656e6f7567682072656d616960448201527f6e696e6720696e20737570706c7920746f20737570706f72742064657369726560648201527f64206d696e7420616d6f756e7400000000000000000000000000000000000000608482015260a4016107cf565b610ce5610cdd82858534611bb9565b878787611c10565b610d575760405162461bcd60e51b815260206004820152602160248201527f434f4e5452414354204552524f523a20496e76616c6964207369676e6174757260448201527f650000000000000000000000000000000000000000000000000000000000000060648201526084016107cf565b610d618184611c91565b505050505050565b610d74838383611cab565b505050565b606a54606c54610dab916001600160a01b0316906103e890610d9c9047906130a6565b610da6919061306d565b612009565b606b54610dc1906001600160a01b031647612009565b565b7fee151c8401928dc223602bb187aff91b9a56c7cae5476ef1b3287b085a16c85f54610100900460ff16610e1c577fee151c8401928dc223602bb187aff91b9a56c7cae5476ef1b3287b085a16c85f5460ff1615610e20565b303b155b610e925760405162461bcd60e51b815260206004820152603760248201527f455243373231415f5f496e697469616c697a61626c653a20636f6e747261637460448201527f20697320616c726561647920696e697469616c697a656400000000000000000060648201526084016107cf565b7fee151c8401928dc223602bb187aff91b9a56c7cae5476ef1b3287b085a16c85f54610100900460ff16158015610f0f577fee151c8401928dc223602bb187aff91b9a56c7cae5476ef1b3287b085a16c85f80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000166101011790555b6000610f1b6001612122565b90508015610f5057600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555b610f6283600001518460200151612279565b610f6a61231f565b610f778360800151610779565b6060830151606d80546001600160a01b039283167fffffffffffffffffffffffff0000000000000000000000000000000000000000918216179091556040850151606555610140850151606c55610120850151606a8054918416918316919091179055610180850151606b805491909316911617905560a083015160c084015160e085015161010086015161100e93929190611966565b801561107157600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5080156107eb5750507fee151c8401928dc223602bb187aff91b9a56c7cae5476ef1b3287b085a16c85f80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055565b610d74838383604051806020016040528060008152506116d3565b600061077382611aab565b606680546110f69061310f565b80601f01602080910402602001604051908101604052809291908181526020018280546111229061310f565b801561116f5780601f106111445761010080835404028352916020019161116f565b820191906000526020600020905b81548152906001019060200180831161115257829003601f168201915b505050505081565b6000816111b0576040517f8f4eb60400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b506001600160a01b031660009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c45602052604090205467ffffffffffffffff1690565b6033546001600160a01b0316331461124f5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107cf565b610dc160006123a4565b606754610100900460ff166112d65760405162461bcd60e51b815260206004820152602c60248201527f434f4e5452414354204552524f523a206d696e74696e6720686173206e6f742060448201527f6265656e20656e61626c6564000000000000000000000000000000000000000060648201526084016107cf565b60695482611326836001600160a01b031660009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4560205260409081902054901c67ffffffffffffffff1690565b6113309190613055565b11156113a45760405162461bcd60e51b815260206004820152603660248201527f434f4e5452414354204552524f523a20416464726573732068617320616c726560448201527f61647920636c61696d6564206d617820616d6f756e740000000000000000000060648201526084016107cf565b606554826113f37f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c41547f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c40540390565b6113fd9190613055565b11156114975760405162461bcd60e51b815260206004820152604d60248201527f434f4e5452414354204552524f523a206e6f7420656e6f7567682072656d616960448201527f6e696e6720696e20737570706c7920746f20737570706f72742064657369726560648201527f64206d696e7420616d6f756e7400000000000000000000000000000000000000608482015260a4016107cf565b6068546114a490836130a6565b34146115185760405162461bcd60e51b815260206004820152602560248201527f434f4e5452414354204552524f523a206e6f7420656e6f75676820657468657260448201527f2073656e7400000000000000000000000000000000000000000000000000000060648201526084016107cf565b6107eb8183611c91565b60607f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4060030180546108209061310f565b6001600160a01b038216331415611596576040517fb06307db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3360008181527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c47602090815260408083206001600160a01b0387168085529083529281902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b6033546001600160a01b031633146116995760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107cf565b606d80547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0392909216919091179055565b6116de848484611cab565b6001600160a01b0383163b15611730576116fa8484848461240e565b611730576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50505050565b606061174182611a2c565b611777576040517fa14c4b5000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611781612583565b90508051600014156117a257604051806020016040528060008152506117cd565b806117ac84612592565b6040516020016117bd929190612fad565b6040516020818303038152906040525b9392505050565b6033546001600160a01b0316331461182e5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107cf565b6001600160a01b0381166118aa5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084016107cf565b6118b3816123a4565b50565b60006118c26001612122565b905080156118f757600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555b61190082610dc3565b80156107eb57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b6033546001600160a01b031633146119c05760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107cf565b606993909355606891909155606780549215157fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0092151561010002929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090931692909217179055565b60007f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c40548210801561077357505060009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4460205260409020547c0100000000000000000000000000000000000000000000000000000000161590565b6000817f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4054811015611b875760008181527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4460205260409020547c01000000000000000000000000000000000000000000000000000000008116611b85575b806117cd57507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0160008181527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c446020526040902054611b2a565b505b6040517fdf2d9b4200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604080513060208201526001600160a01b03861691810191909152606081018490526080810183905260a0810182905260009060c0016040516020818303038152906040528051906020012090505b949350505050565b606d546040805160008082526020820180845288905260ff871692820192909252606081018590526080810184905290916001600160a01b03169060019060a0016020604051602081039080840390855afa158015611c73573d6000803e3d6000fd5b505050602060405103516001600160a01b0316149050949350505050565b6107eb8282604051806020016040528060008152506125ff565b6000611cb682611aab565b9050836001600160a01b0316816001600160a01b031614611d03576040517fa114810000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4660205260408120546001600160a01b0390811691908616331480611d8f57506001600160a01b03861660009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c476020908152604080832033845290915290205460ff165b80611da257506001600160a01b03821633145b905080611ddb576040517f59c896be00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b84611e12576040517fea553b3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8115611e6c5760008481527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c466020526040902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001690555b6001600160a01b0386811660009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c456020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190559288168252828220805460010190558682527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c449052207c02000000000000000000000000000000000000000000000000000000004260a01b871781179091558316611fc3576001840160008181527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c446020526040902054611fc1577f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c40548114611fc15760008181527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c44602052604090208490555b505b83856001600160a01b0316876001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4610d61565b804710156120595760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e636500000060448201526064016107cf565b6000826001600160a01b03168260405160006040518083038185875af1925050503d80600081146120a6576040519150601f19603f3d011682016040523d82523d6000602084013e6120ab565b606091505b5050905080610d745760405162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d6179206861766520726576657274656400000000000060648201526084016107cf565b60008054610100900460ff16156121bf578160ff1660011480156121455750303b155b6121b75760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016107cf565b506000919050565b60005460ff80841691161061223c5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016107cf565b50600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff92909216919091179055600190565b919050565b7fee151c8401928dc223602bb187aff91b9a56c7cae5476ef1b3287b085a16c85f54610100900460ff166123155760405162461bcd60e51b815260206004820152603460248201527f455243373231415f5f496e697469616c697a61626c653a20636f6e747261637460448201527f206973206e6f7420696e697469616c697a696e6700000000000000000000000060648201526084016107cf565b6107eb8282612857565b600054610100900460ff1661239c5760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016107cf565b610dc1612981565b603380546001600160a01b038381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6040517f150b7a020000000000000000000000000000000000000000000000000000000081526000906001600160a01b0385169063150b7a029061245c903390899088908890600401612fdc565b602060405180830381600087803b15801561247657600080fd5b505af19250505080156124c4575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682019092526124c191810190612ce8565b60015b612538573d8080156124f2576040519150601f19603f3d011682016040523d82523d6000602084013e6124f7565b606091505b508051612530576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805181602001fd5b7fffffffff00000000000000000000000000000000000000000000000000000000167f150b7a0200000000000000000000000000000000000000000000000000000000149050611c08565b6060606680546108209061310f565b604080516080810191829052607f0190826030600a8206018353600a90045b80156125cf57600183039250600a81066030018353600a90046125b1565b508190037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0909101908152919050565b7f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c405483612658576040517f2e07630000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8261268f576040517fb562e8dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b03841660009081527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4560205260409020805468010000000000000001850201905560e16001841460008381527f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4460205260409020911b4260a01b8617179055808381016001600160a01b0386163b156127e4575b60405182906001600160a01b038816906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a4612775600087848060010195508761240e565b6127ab576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80821061272a57827f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4054146127df57600080fd5b612829565b5b6040516001830192906001600160a01b038816906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a48082106127e5575b507f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c4055611730600085838684565b7fee151c8401928dc223602bb187aff91b9a56c7cae5476ef1b3287b085a16c85f54610100900460ff166128f35760405162461bcd60e51b815260206004820152603460248201527f455243373231415f5f496e697469616c697a61626c653a20636f6e747261637460448201527f206973206e6f7420696e697469616c697a696e6700000000000000000000000060648201526084016107cf565b8151612925907f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c42906020850190612a07565b508051612958907f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c43906020840190612a07565b5060007f2569078dfb4b0305704d3008e7403993ae9601b85f7ae5e742de3de8f8011c40555050565b600054610100900460ff166129fe5760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016107cf565b610dc1336123a4565b828054612a139061310f565b90600052602060002090601f016020900481019282612a355760008555612a7b565b82601f10612a4e57805160ff1916838001178555612a7b565b82800160010185558215612a7b579182015b82811115612a7b578251825591602001919060010190612a60565b50612a87929150612a8b565b5090565b5b80821115612a875760008155600101612a8c565b600067ffffffffffffffff80841115612abb57612abb613192565b604051601f85017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908282118183101715612b0157612b01613192565b81604052809350858152868686011115612b1a57600080fd5b858560208301376000602087830101525050509392505050565b80356001600160a01b038116811461227457600080fd5b8035801515811461227457600080fd5b600082601f830112612b6b578081fd5b6117cd83833560208501612aa0565b600060208284031215612b8b578081fd5b6117cd82612b34565b60008060408385031215612ba6578081fd5b612baf83612b34565b9150612bbd60208401612b34565b90509250929050565b600080600060608486031215612bda578081fd5b612be384612b34565b9250612bf160208501612b34565b9150604084013590509250925092565b60008060008060808587031215612c16578081fd5b612c1f85612b34565b9350612c2d60208601612b34565b925060408501359150606085013567ffffffffffffffff811115612c4f578182fd5b8501601f81018713612c5f578182fd5b612c6e87823560208401612aa0565b91505092959194509250565b60008060408385031215612c8c578182fd5b612c9583612b34565b9150612bbd60208401612b4b565b60008060408385031215612cb5578182fd5b612cbe83612b34565b946020939093013593505050565b600060208284031215612cdd578081fd5b81356117cd816131c1565b600060208284031215612cf9578081fd5b81516117cd816131c1565b600060208284031215612d15578081fd5b813567ffffffffffffffff811115612d2b578182fd5b611c0884828501612b5b565b600060208284031215612d48578081fd5b813567ffffffffffffffff80821115612d5f578283fd5b908301906101a08286031215612d73578283fd5b612d7b61302b565b823582811115612d89578485fd5b612d9587828601612b5b565b825250602083013582811115612da9578485fd5b612db587828601612b5b565b60208301525060408301356040820152612dd160608401612b34565b6060820152608083013582811115612de7578485fd5b612df387828601612b5b565b60808301525060a083013560a082015260c083013560c0820152612e1960e08401612b4b565b60e08201526101009150612e2e828401612b4b565b828201526101209150612e42828401612b34565b82820152610140915081830135828201526101609150612e63828401612b34565b828201526101809150612e77828401612b34565b91810191909152949350505050565b600060208284031215612e97578081fd5b5035919050565b60008060408385031215612eb0578182fd5b82359150612bbd60208401612b34565b60008060008060808587031215612ed5578182fd5b8435935060208501359250612eec60408601612b4b565b9150612efa60608601612b4b565b905092959194509250565b60008060008060008060c08789031215612f1d578384fd5b863560ff81168114612f2d578485fd5b955060208701359450604087013593506060870135925060808701359150612f5760a08801612b34565b90509295509295509295565b60008151808452612f7b8160208601602086016130e3565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60008351612fbf8184602088016130e3565b835190830190612fd38183602088016130e3565b01949350505050565b60006001600160a01b0380871683528086166020840152508360408301526080606083015261300e6080830184612f63565b9695505050505050565b6020815260006117cd6020830184612f63565b6040516101a0810167ffffffffffffffff8111828210171561304f5761304f613192565b60405290565b6000821982111561306857613068613163565b500190565b6000826130a1577f4e487b710000000000000000000000000000000000000000000000000000000081526012600452602481fd5b500490565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156130de576130de613163565b500290565b60005b838110156130fe5781810151838201526020016130e6565b838111156117305750506000910152565b600181811c9082168061312357607f821691505b6020821081141561315d577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7fffffffff00000000000000000000000000000000000000000000000000000000811681146118b357600080fdfea26469706673582212207db246e58074412286ce96d0f63a4d2b1f0927de8d477ab8de6bb8a4551e05b964736f6c63430008040033
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 33 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
Loading...
Loading
Loading...
Loading
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.