Feature Tip: Add private address tag to any address under My Name Tag !
Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
TokenTracker
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Name:
BobToken
Compiler Version
v0.8.15+commit.e14f2714
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: CC0-1.0 pragma solidity 0.8.15; import "./proxy/EIP1967Admin.sol"; import "./token/ERC677.sol"; import "./token/ERC20Permit.sol"; import "./token/ERC20MintBurn.sol"; import "./token/ERC20Recovery.sol"; import "./token/ERC20Blocklist.sol"; import "./utils/Claimable.sol"; /** * @title BobToken */ contract BobToken is EIP1967Admin, BaseERC20, ERC677, ERC20Permit, ERC20MintBurn, ERC20Recovery, ERC20Blocklist, Claimable { /** * @dev Creates a proxy implementation for BobToken. * @param _self address of the proxy contract, linked to the deployed implementation, * required for correct EIP712 domain derivation. */ constructor(address _self) ERC20Permit(_self) {} /** * @dev Returns the name of the token. */ function name() public view override returns (string memory) { return "BOB"; } /** * @dev Returns the symbol of the token. */ function symbol() public view override returns (string memory) { return "BOB"; } /** * @dev Tells if caller is the contract owner. * Gives ownership rights to the proxy admin as well. * @return true, if caller is the contract owner or proxy admin. */ function _isOwner() internal view override returns (bool) { return super._isOwner() || _admin() == _msgSender(); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol) pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _transferOwnership(_msgSender()); } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { _checkOwner(); _; } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { require(owner() == _msgSender(), "Ownable: caller is not the owner"); } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `to`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address to, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an {Approval} event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `from` to `to` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 amount ) external returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/IERC20Metadata.sol) pragma solidity ^0.8.0; import "../IERC20.sol"; /** * @dev Interface for the optional metadata functions from the ERC20 standard. * * _Available since v4.1._ */ interface IERC20Metadata is IERC20 { /** * @dev Returns the name of the token. */ function name() external view returns (string memory); /** * @dev Returns the symbol of the token. */ function symbol() external view returns (string memory); /** * @dev Returns the decimals places of the token. */ function decimals() external view returns (uint8); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (utils/Address.sol) pragma solidity ^0.8.1; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== * * [IMPORTANT] * ==== * You shouldn't rely on `isContract` to protect against flash loan attacks! * * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract * constructor. * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize/address.code.length, which returns 0 // for contracts in construction, since the code is only stored at the end // of the constructor execution. return account.code.length > 0; } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, "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"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResultFromTarget(target, 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) { (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResultFromTarget(target, success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResultFromTarget(target, success, returndata, errorMessage); } /** * @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling * the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract. * * _Available since v4.8._ */ function verifyCallResultFromTarget( address target, bool success, bytes memory returndata, string memory errorMessage ) internal view returns (bytes memory) { if (success) { if (returndata.length == 0) { // only check isContract if the call was successful and the return data is empty // otherwise we already know that it was a contract require(isContract(target), "Address: call to non-contract"); } return returndata; } else { _revert(returndata, errorMessage); } } /** * @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason or 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 { _revert(returndata, errorMessage); } } function _revert(bytes memory returndata, string memory errorMessage) private pure { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly /// @solidity memory-safe-assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (utils/Strings.sol) pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; uint8 private constant _ADDRESS_LENGTH = 20; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } /** * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation. */ function toHexString(address addr) internal pure returns (string memory) { return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (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. /// @solidity memory-safe-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. /// @solidity memory-safe-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 = vs & bytes32(0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff); uint8 v = uint8((uint256(vs) >> 255) + 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: CC0-1.0 pragma solidity 0.8.15; interface IBurnableERC20 { function burn(uint256 amount) external; }
// SPDX-License-Identifier: CC0-1.0 pragma solidity 0.8.15; interface IERC20Permit { function permit( address owner, address spender, uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s ) external; function nonces(address owner) external view returns (uint256); function DOMAIN_SEPARATOR() external view returns (bytes32); function PERMIT_TYPEHASH() external view returns (bytes32); function SALTED_PERMIT_TYPEHASH() external view returns (bytes32); function receiveWithPermit( address _holder, uint256 _value, uint256 _deadline, uint8 _v, bytes32 _r, bytes32 _s ) external; function receiveWithSaltedPermit( address _holder, uint256 _value, uint256 _deadline, bytes32 _salt, uint8 _v, bytes32 _r, bytes32 _s ) external; }
// SPDX-License-Identifier: CC0-1.0 pragma solidity 0.8.15; interface IERC677 { function transferAndCall(address to, uint256 amount, bytes calldata data) external; }
// SPDX-License-Identifier: CC0-1.0 pragma solidity 0.8.15; interface IERC677Receiver { function onTokenTransfer(address from, uint256 value, bytes calldata data) external returns (bool); }
// SPDX-License-Identifier: CC0-1.0 pragma solidity 0.8.15; interface IMintableERC20 { function mint(address to, uint256 amount) external; }
// SPDX-License-Identifier: CC0-1.0 pragma solidity 0.8.15; /** * @title EIP1967Admin * @dev Upgradeable proxy pattern implementation according to minimalistic EIP1967. */ contract EIP1967Admin { // EIP 1967 // bytes32(uint256(keccak256('eip1967.proxy.admin')) - 1) uint256 internal constant EIP1967_ADMIN_STORAGE = 0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103; modifier onlyAdmin() { require(msg.sender == _admin(), "EIP1967Admin: not an admin"); _; } function _admin() internal view returns (address res) { assembly { res := sload(EIP1967_ADMIN_STORAGE) } } }
// SPDX-License-Identifier: MIT pragma solidity 0.8.15; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol"; /** * @title BaseERC20 */ abstract contract BaseERC20 is IERC20, IERC20Metadata { mapping(address => uint256) internal _balances; mapping(address => mapping(address => uint256)) public allowance; uint256 public totalSupply; function name() public view virtual override returns (string memory); function symbol() public view virtual override returns (string memory); function decimals() public view override returns (uint8) { return 18; } function balanceOf(address account) public view virtual override returns (uint256 _balance) { _balance = _balances[account]; assembly { _balance := and(_balance, 0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff) } } function transfer(address to, uint256 amount) public virtual override returns (bool) { _transfer(msg.sender, to, amount); return true; } function approve(address spender, uint256 amount) public virtual override returns (bool) { _approve(msg.sender, spender, amount); return true; } function transferFrom(address from, address to, uint256 amount) public virtual override returns (bool) { _spendAllowance(from, msg.sender, amount); _transfer(from, to, amount); return true; } function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) { _approve(msg.sender, spender, allowance[msg.sender][spender] + addedValue); return true; } function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) { uint256 currentAllowance = allowance[msg.sender][spender]; require(currentAllowance >= subtractedValue, "ERC20: decreased allowance below zero"); unchecked { _approve(msg.sender, spender, currentAllowance - subtractedValue); } return true; } function _transfer(address from, address to, uint256 amount) internal virtual { require(from != address(0), "ERC20: transfer from the zero address"); require(to != address(0), "ERC20: transfer to the zero address"); _decreaseBalance(from, amount); _increaseBalance(to, amount); emit Transfer(from, to, amount); } function _mint(address account, uint256 amount) internal virtual { require(account != address(0), "ERC20: mint to the zero address"); totalSupply += amount; _increaseBalance(account, amount); emit Transfer(address(0), account, amount); } function _burn(address account, uint256 amount) internal virtual { require(account != address(0), "ERC20: burn from the zero address"); _decreaseBalance(account, amount); totalSupply -= amount; emit Transfer(account, address(0), amount); } function _approve(address owner, address spender, uint256 amount) internal virtual { require(owner != address(0), "ERC20: approve from the zero address"); require(spender != address(0), "ERC20: approve to the zero address"); allowance[owner][spender] = amount; emit Approval(owner, spender, amount); } function _spendAllowance(address owner, address spender, uint256 amount) internal virtual { uint256 currentAllowance = allowance[owner][spender]; if (currentAllowance != type(uint256).max) { require(currentAllowance >= amount, "ERC20: insufficient allowance"); unchecked { _approve(owner, spender, currentAllowance - amount); } } } function _increaseBalance(address _account, uint256 _amount) internal { uint256 balance = _balances[_account]; require(balance < 1 << 255, "ERC20: account frozen"); unchecked { _balances[_account] = balance + _amount; } } function _decreaseBalance(address _account, uint256 _amount) internal { uint256 balance = _balances[_account]; require(balance < 1 << 255, "ERC20: account frozen"); require(balance >= _amount, "ERC20: amount exceeds balance"); unchecked { _balances[_account] = balance - _amount; } } function _decreaseBalanceUnchecked(address _account, uint256 _amount) internal { uint256 balance = _balances[_account]; unchecked { _balances[_account] = balance - _amount; } } function _isFrozen(address _account) internal view returns (bool) { return _balances[_account] >= 1 << 255; } function _freezeBalance(address _account) internal { _balances[_account] |= 1 << 255; } function _unfreezeBalance(address _account) internal { _balances[_account] &= (1 << 255) - 1; } }
// SPDX-License-Identifier: CC0-1.0 pragma solidity 0.8.15; import "../utils/Ownable.sol"; import "./BaseERC20.sol"; /** * @title ERC20Blocklist */ abstract contract ERC20Blocklist is Ownable, BaseERC20 { address public blocklister; event Blocked(address indexed account); event Unblocked(address indexed account); event BlocklisterChanged(address indexed account); /** * @dev Throws if called by any account other than the blocklister. */ modifier onlyBlocklister() { require(msg.sender == blocklister, "Blocklist: caller is not the blocklister"); _; } /** * @dev Checks if account is blocked. * @param _account The address to check. */ function isBlocked(address _account) external view returns (bool) { return _isFrozen(_account); } /** * @dev Adds account to blocklist. * @param _account The address to blocklist. */ function blockAccount(address _account) external onlyBlocklister { _freezeBalance(_account); emit Blocked(_account); } /** * @dev Removes account from blocklist. * @param _account The address to remove from the blocklist. */ function unblockAccount(address _account) external onlyBlocklister { _unfreezeBalance(_account); emit Unblocked(_account); } /** * @dev Updates address of the blocklister account. * Callable only by the contract owner. * @param _newBlocklister address of new blocklister account. */ function updateBlocklister(address _newBlocklister) external onlyOwner { blocklister = _newBlocklister; emit BlocklisterChanged(_newBlocklister); } }
// SPDX-License-Identifier: CC0-1.0 pragma solidity 0.8.15; import "../utils/Ownable.sol"; import "../interfaces/IMintableERC20.sol"; import "./BaseERC20.sol"; import "../interfaces/IMintableERC20.sol"; import "../interfaces/IBurnableERC20.sol"; /** * @title ERC20MintBurn */ abstract contract ERC20MintBurn is IMintableERC20, IBurnableERC20, Ownable, BaseERC20 { mapping(address => uint256) internal permissions; event UpdateMinter(address indexed minter, bool canMint, bool canBurn); function isMinter(address _account) public view returns (bool) { return permissions[_account] & 2 > 0; } function isBurner(address _account) public view returns (bool) { return permissions[_account] & 1 > 0; } /** * @dev Updates mint/burn permissions of the specific account. * Callable only by the contract owner. * @param _account address of the new minter EOA or contract. * @param _canMint true if minting is allowed. * @param _canBurn true if burning is allowed. */ function updateMinter(address _account, bool _canMint, bool _canBurn) external onlyOwner { permissions[_account] = (_canMint ? 2 : 0) + (_canBurn ? 1 : 0); emit UpdateMinter(_account, _canMint, _canBurn); } /** * @dev Mints the specified amount of tokens. * Callable only by one of the minter addresses. * @param _to address of the tokens receiver. * @param _amount amount of tokens to mint. */ function mint(address _to, uint256 _amount) external { require(isMinter(msg.sender), "ERC20MintBurn: not a minter"); _mint(_to, _amount); } /** * @dev Burns tokens from the caller. * Callable only by one of the burner addresses. * @param _value amount of tokens to burn. Should be less than or equal to caller balance. */ function burn(uint256 _value) external virtual { require(isBurner(msg.sender), "ERC20MintBurn: not a burner"); _burn(msg.sender, _value); } }
// SPDX-License-Identifier: CC0-1.0 pragma solidity 0.8.15; import "@openzeppelin/contracts/utils/cryptography/ECDSA.sol"; import "../interfaces/IERC20Permit.sol"; import "./BaseERC20.sol"; import "../utils/EIP712.sol"; /** * @title ERC20Permit */ abstract contract ERC20Permit is IERC20Permit, BaseERC20, EIP712 { // EIP2612 permit typehash bytes32 public constant PERMIT_TYPEHASH = keccak256("Permit(address owner,address spender,uint256 value,uint256 nonce,uint256 deadline)"); // Custom "salted" permit typehash // Works exactly the same as EIP2612 permit, except that includes an additional salt, // which should be explicitly signed by the user, as part of the permit message. bytes32 public constant SALTED_PERMIT_TYPEHASH = keccak256("Permit(address owner,address spender,uint256 value,uint256 nonce,uint256 deadline,bytes32 salt)"); mapping(address => uint256) public nonces; constructor(address _self) EIP712(_self, name(), "1") {} function DOMAIN_SEPARATOR() external view override returns (bytes32) { return _domainSeparatorV4(); } /** * @dev Allows to spend holder's unlimited amount by the specified spender according to EIP2612. * The function can be called by anyone, but requires having allowance parameters * signed by the holder according to EIP712. * Note: call to permit can be executed in the front-running transaction sent by other party, * contracts using permit/receiveWithPermit are advised to implement necessary fallbacks for failing permit calls, * avoiding entire transaction failures if possible. * @param _holder The holder's address. * @param _spender The spender's address. * @param _value Allowance value to set as a result of the call. * @param _deadline The deadline timestamp to call the permit function. Must be a timestamp in the future. * Note that timestamps are not precise, malicious miner/validator can manipulate them to some extend. * Assume that there can be a 900 seconds time delta between the desired timestamp and the actual expiration. * @param _v A final byte of signature (ECDSA component). * @param _r The first 32 bytes of signature (ECDSA component). * @param _s The second 32 bytes of signature (ECDSA component). */ function permit( address _holder, address _spender, uint256 _value, uint256 _deadline, uint8 _v, bytes32 _r, bytes32 _s ) external { _checkPermit(_holder, _spender, _value, _deadline, _v, _r, _s); _approve(_holder, _spender, _value); } /** * @dev Cheap shortcut for making sequential calls to permit() + transferFrom() functions. * Note: signatures from receiveWithPermit can be re-used in the front-running permit transaction sent by other party, * contracts using permit/receiveWithPermit are advised to implement necessary fallbacks for failing * receiveWithPermit calls, avoiding entire transaction failures if possible. */ function receiveWithPermit( address _holder, uint256 _value, uint256 _deadline, uint8 _v, bytes32 _r, bytes32 _s ) public virtual { _checkPermit(_holder, msg.sender, _value, _deadline, _v, _r, _s); // we don't make calls to _approve to avoid unnecessary storage writes // however, emitting ERC20 events is still desired emit Approval(_holder, msg.sender, _value); _approve(_holder, msg.sender, 0); _transfer(_holder, msg.sender, _value); } /** * @dev Cheap shortcut for making sequential calls to saltedPermit() + transferFrom() functions. */ function receiveWithSaltedPermit( address _holder, uint256 _value, uint256 _deadline, bytes32 _salt, uint8 _v, bytes32 _r, bytes32 _s ) public virtual { _checkSaltedPermit(_holder, msg.sender, _value, _deadline, _salt, _v, _r, _s); // we don't make calls to _approve to avoid unnecessary storage writes // however, emitting ERC20 events is still desired emit Approval(_holder, msg.sender, _value); _approve(_holder, msg.sender, 0); _transfer(_holder, msg.sender, _value); } function _checkPermit( address _holder, address _spender, uint256 _value, uint256 _deadline, uint8 _v, bytes32 _r, bytes32 _s ) private { require(block.timestamp <= _deadline, "ERC20Permit: expired permit"); uint256 nonce = nonces[_holder]++; bytes32 digest = ECDSA.toTypedDataHash( _domainSeparatorV4(), keccak256(abi.encode(PERMIT_TYPEHASH, _holder, _spender, _value, nonce, _deadline)) ); require(_holder == ECDSA.recover(digest, _v, _r, _s), "ERC20Permit: invalid ERC2612 signature"); } function _checkSaltedPermit( address _holder, address _spender, uint256 _value, uint256 _deadline, bytes32 _salt, uint8 _v, bytes32 _r, bytes32 _s ) private { require(block.timestamp <= _deadline, "ERC20Permit: expired permit"); uint256 nonce = nonces[_holder]++; bytes32 digest = ECDSA.toTypedDataHash( _domainSeparatorV4(), keccak256(abi.encode(SALTED_PERMIT_TYPEHASH, _holder, _spender, _value, nonce, _deadline, _salt)) ); require(_holder == ECDSA.recover(digest, _v, _r, _s), "ERC20Permit: invalid signature"); } }
// SPDX-License-Identifier: CC0-1.0 pragma solidity 0.8.15; import "@openzeppelin/contracts/utils/Address.sol"; import "../utils/Ownable.sol"; import "../interfaces/IERC677Receiver.sol"; import "./BaseERC20.sol"; /** * @title ERC20Recovery */ abstract contract ERC20Recovery is Ownable, BaseERC20 { event ExecutedRecovery(bytes32 indexed hash, uint256 value); event CancelledRecovery(bytes32 indexed hash); event RequestedRecovery( bytes32 indexed hash, uint256 requestTimestamp, uint256 executionTimestamp, address[] accounts, uint256[] values ); address public recoveryAdmin; address public recoveredFundsReceiver; uint64 public recoveryLimitPercent; uint32 public recoveryRequestTimelockPeriod; uint256 public totalRecovered; bytes32 public recoveryRequestHash; uint256 public recoveryRequestExecutionTimestamp; /** * @dev Throws if called by any account other than the contract owner or recovery admin. */ modifier onlyRecoveryAdmin() { require(_msgSender() == recoveryAdmin || _isOwner(), "Recovery: not authorized for recovery"); _; } /** * @dev Updates the address of the recovery admin account. * Callable only by the contract owner. * Recovery admin is only authorized to request/execute/cancel recovery operations. * The availability, parameters and impact limits of recovery is controlled by the contract owner. * @param _recoveryAdmin address of the new recovery admin account. */ function setRecoveryAdmin(address _recoveryAdmin) external onlyOwner { recoveryAdmin = _recoveryAdmin; } /** * @dev Updates the address of the recovered funds receiver. * Callable only by the contract owner. * Recovered funds receiver will receive ERC20, recovered from lost/unused accounts. * If receiver is a smart contract, it must correctly process a ERC677 callback, sent once on the recovery execution. * @param _recoveredFundsReceiver address of the new recovered funds receiver. */ function setRecoveredFundsReceiver(address _recoveredFundsReceiver) external onlyOwner { recoveredFundsReceiver = _recoveredFundsReceiver; } /** * @dev Updates the max allowed percentage of total supply, which can be recovered. * Limits the impact that could be caused by the recovery admin. * Callable only by the contract owner. * @param _recoveryLimitPercent percentage, as a fraction of 1 ether, should be at most 100%. * In theory, recovery can exceed total supply, if recovered funds are then lost once again, * but in practice, we do not expect totalRecovered to reach such extreme values. */ function setRecoveryLimitPercent(uint64 _recoveryLimitPercent) external onlyOwner { require(_recoveryLimitPercent <= 1 ether, "Recovery: invalid percentage"); recoveryLimitPercent = _recoveryLimitPercent; } /** * @dev Updates the timelock period between submission of the recovery request and its execution. * Any user, who is not willing to accept the recovery, can safely withdraw his tokens within such period. * Callable only by the contract owner. * @param _recoveryRequestTimelockPeriod new timelock period in seconds. */ function setRecoveryRequestTimelockPeriod(uint32 _recoveryRequestTimelockPeriod) external onlyOwner { require(_recoveryRequestTimelockPeriod >= 1 days, "Recovery: too low timelock period"); require(_recoveryRequestTimelockPeriod <= 30 days, "Recovery: too high timelock period"); recoveryRequestTimelockPeriod = _recoveryRequestTimelockPeriod; } /** * @dev Tells if recovery of funds is available, given the current configuration of recovery parameters. * @return true, if at least 1 wei of tokens could be recovered within the available limit. */ function isRecoveryEnabled() external view returns (bool) { return _remainingRecoveryLimit() > 0; } /** * @dev Internal function telling the remaining available limit for recovery. * @return available recovery limit. */ function _remainingRecoveryLimit() internal view returns (uint256) { if (recoveredFundsReceiver == address(0)) { return 0; } uint256 limit = totalSupply * recoveryLimitPercent / 1 ether; if (limit > totalRecovered) { return limit - totalRecovered; } return 0; } /** * @dev Creates a request to recover funds from abandoned/unused accounts. * Only one request could be active at a time. Any pending request would be cancelled and won't take any effect. * Callable only by the contract owner or recovery admin. * @param _accounts list of accounts to recover funds from. * @param _values list of max values to recover from each of the specified account. */ function requestRecovery(address[] calldata _accounts, uint256[] calldata _values) external onlyRecoveryAdmin { require(_accounts.length == _values.length, "Recovery: different lengths"); require(_accounts.length > 0, "Recovery: empty accounts"); uint256 limit = _remainingRecoveryLimit(); require(limit > 0, "Recovery: not enabled"); bytes32 hash = recoveryRequestHash; if (hash != bytes32(0)) { emit CancelledRecovery(hash); } uint256[] memory values = new uint256[](_values.length); uint256 total = 0; for (uint256 i = 0; i < _values.length; i++) { uint256 balance = balanceOf(_accounts[i]); uint256 value = balance < _values[i] ? balance : _values[i]; values[i] = value; total += value; } require(total <= limit, "Recovery: exceed recovery limit"); uint256 executionTimestamp = block.timestamp + recoveryRequestTimelockPeriod; hash = keccak256(abi.encode(executionTimestamp, _accounts, values)); recoveryRequestHash = hash; recoveryRequestExecutionTimestamp = executionTimestamp; emit RequestedRecovery(hash, block.timestamp, executionTimestamp, _accounts, values); } /** * @dev Executes the request to recover funds from abandoned/unused accounts. * Executed request should have exactly the same parameters, as emitted in the RequestedRecovery event. * Request could only be executed once configured timelock was surpassed. * After execution of the request, total amount of recovered funds should not exceed the configured percentage. * Callable only by the contract owner or recovery admin. * @param _accounts list of accounts to recover funds from. * @param _values list of max values to recover from each of the specified account. */ function executeRecovery(address[] calldata _accounts, uint256[] calldata _values) external onlyRecoveryAdmin { uint256 executionTimestamp = recoveryRequestExecutionTimestamp; delete recoveryRequestExecutionTimestamp; require(executionTimestamp > 0, "Recovery: no active recovery request"); require(executionTimestamp <= block.timestamp, "Recovery: request still timelocked"); uint256 limit = _remainingRecoveryLimit(); require(limit > 0, "Recovery: not enabled"); bytes32 storedHash = recoveryRequestHash; delete recoveryRequestHash; bytes32 receivedHash = keccak256(abi.encode(executionTimestamp, _accounts, _values)); require(storedHash == receivedHash, "Recovery: request hashes do not match"); uint256 value = _recoverTokens(_accounts, _values); require(value <= limit, "Recovery: exceed recovery limit"); emit ExecutedRecovery(storedHash, value); } /** * @dev Cancels pending recovery request. * Callable only by the contract owner or recovery admin. */ function cancelRecovery() external onlyRecoveryAdmin { bytes32 hash = recoveryRequestHash; require(hash != bytes32(0), "Recovery: no active recovery request"); delete recoveryRequestHash; delete recoveryRequestExecutionTimestamp; emit CancelledRecovery(hash); } function _recoverTokens(address[] calldata _accounts, uint256[] calldata _values) internal returns (uint256) { uint256 total = 0; address receiver = recoveredFundsReceiver; for (uint256 i = 0; i < _accounts.length; i++) { uint256 balance = balanceOf(_accounts[i]); uint256 value = balance < _values[i] ? balance : _values[i]; total += value; _decreaseBalanceUnchecked(_accounts[i], value); emit Transfer(_accounts[i], receiver, value); } _increaseBalance(receiver, total); totalRecovered += total; if (Address.isContract(receiver)) { require(IERC677Receiver(receiver).onTokenTransfer(address(this), total, new bytes(0))); } return total; } }
// SPDX-License-Identifier: CC0-1.0 pragma solidity 0.8.15; import "../interfaces/IERC677.sol"; import "../interfaces/IERC677Receiver.sol"; import "./BaseERC20.sol"; /** * @title ERC677 */ abstract contract ERC677 is IERC677, BaseERC20 { /** * @dev ERC677 extension to ERC20 transfer. Will notify receiver after transfer completion. * @param _to address of the tokens receiver. * @param _amount amount of tokens to mint. * @param _data extra data to pass in the notification callback. */ function transferAndCall(address _to, uint256 _amount, bytes calldata _data) external override { _transfer(msg.sender, _to, _amount); require(IERC677Receiver(_to).onTokenTransfer(msg.sender, _amount, _data), "ERC677: callback failed"); } }
// SPDX-License-Identifier: CC0-1.0 pragma solidity 0.8.15; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "./Ownable.sol"; /** * @title Claimable */ contract Claimable is Ownable { address claimingAdmin; /** * @dev Throws if called by any account other than the contract owner or claiming admin. */ modifier onlyClaimingAdmin() { require(_msgSender() == claimingAdmin || _isOwner(), "Claimable: not authorized for claiming"); _; } /** * @dev Updates the address of the claiming admin account. * Callable only by the contract owner. * Claiming admin is only authorized to claim ERC20 tokens or native tokens mistakenly sent to the token contract address. * @param _claimingAdmin address of the new claiming admin account. */ function setClaimingAdmin(address _claimingAdmin) external onlyOwner { claimingAdmin = _claimingAdmin; } /** * @dev Allows to transfer any locked token from this contract. * Callable only by the contract owner or claiming admin. * @param _token address of the token contract, or 0x00..00 for transferring native coins. * @param _to locked tokens receiver address. */ function claimTokens(address _token, address _to) external virtual onlyClaimingAdmin { if (_token == address(0)) { payable(_to).transfer(address(this).balance); } else { uint256 balance = IERC20(_token).balanceOf(address(this)); IERC20(_token).transfer(_to, balance); } } }
// SPDX-License-Identifier: MIT pragma solidity 0.8.15; import "@openzeppelin/contracts/utils/cryptography/ECDSA.sol"; /** * @dev https://eips.ethereum.org/EIPS/eip-712[EIP 712] is a standard for hashing and signing of typed structured data. * * The encoding specified in the EIP is very generic, and such a generic implementation in Solidity is not feasible, * thus this contract does not implement the encoding itself. Protocols need to implement the type-specific encoding * they need in their contracts using a combination of `abi.encode` and `keccak256`. * * This contract implements the EIP 712 domain separator ({_domainSeparatorV4}) that is used as part of the encoding * scheme, and the final step of the encoding to obtain the message digest that is then signed via ECDSA * ({_hashTypedDataV4}). * * The implementation of the domain separator was designed to be as efficient as possible while still properly updating * the chain id to protect against replay attacks on an eventual fork of the chain. * * NOTE: This contract implements the version of the encoding known as "v4", as implemented by the JSON RPC method * https://docs.metamask.io/guide/signing-data.html[`eth_signTypedDataV4` in MetaMask]. * * Adapted from OpenZeppelin library to support address(this) overrides in proxy implementations. */ abstract contract EIP712 { /* solhint-disable var-name-mixedcase */ // Cache the domain separator as an immutable value, but also store the chain id that it corresponds to, in order to // invalidate the cached domain separator if the chain id changes. bytes32 private immutable _CACHED_DOMAIN_SEPARATOR; uint256 private immutable _CACHED_CHAIN_ID; address private immutable _CACHED_THIS; bytes32 private immutable _HASHED_NAME; bytes32 private immutable _HASHED_VERSION; bytes32 private immutable _TYPE_HASH; /* solhint-enable var-name-mixedcase */ /** * @dev Initializes the domain separator and parameter caches. * * The meaning of `name` and `version` is specified in * https://eips.ethereum.org/EIPS/eip-712#definition-of-domainseparator[EIP 712]: * * - `name`: the user readable name of the signing domain, i.e. the name of the DApp or the protocol. * - `version`: the current major version of the signing domain. * * NOTE: These parameters cannot be changed except through a xref:learn::upgrading-smart-contracts.adoc[smart * contract upgrade]. */ constructor(address self, string memory name, string memory version) { bytes32 hashedName = keccak256(bytes(name)); bytes32 hashedVersion = keccak256(bytes(version)); bytes32 typeHash = keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"); _HASHED_NAME = hashedName; _HASHED_VERSION = hashedVersion; _CACHED_CHAIN_ID = block.chainid; _CACHED_DOMAIN_SEPARATOR = _buildDomainSeparator(typeHash, hashedName, hashedVersion, self); _CACHED_THIS = self; _TYPE_HASH = typeHash; } /** * @dev Returns the domain separator for the current chain. */ function _domainSeparatorV4() internal view returns (bytes32) { if (address(this) == _CACHED_THIS && block.chainid == _CACHED_CHAIN_ID) { return _CACHED_DOMAIN_SEPARATOR; } else { return _buildDomainSeparator(_TYPE_HASH, _HASHED_NAME, _HASHED_VERSION, address(this)); } } function _buildDomainSeparator( bytes32 typeHash, bytes32 nameHash, bytes32 versionHash, address self ) private view returns (bytes32) { return keccak256(abi.encode(typeHash, nameHash, versionHash, block.chainid, self)); } /** * @dev Given an already https://eips.ethereum.org/EIPS/eip-712#definition-of-hashstruct[hashed struct], this * function returns the hash of the fully encoded EIP712 message for this domain. * * This hash can be used together with {ECDSA-recover} to obtain the signer of a message. For example: * * ```solidity * bytes32 digest = _hashTypedDataV4(keccak256(abi.encode( * keccak256("Mail(address to,string contents)"), * mailTo, * keccak256(bytes(mailContents)) * ))); * address signer = ECDSA.recover(digest, signature); * ``` */ function _hashTypedDataV4(bytes32 structHash) internal view virtual returns (bytes32) { return ECDSA.toTypedDataHash(_domainSeparatorV4(), structHash); } }
// SPDX-License-Identifier: CC0-1.0 pragma solidity 0.8.15; import "@openzeppelin/contracts/access/Ownable.sol" as OZOwnable; /** * @title Ownable */ contract Ownable is OZOwnable.Ownable { /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view override { require(_isOwner(), "Ownable: caller is not the owner"); } /** * @dev Tells if caller is the contract owner. * @return true, if caller is the contract owner. */ function _isOwner() internal view virtual returns (bool) { return owner() == _msgSender(); } }
{ "remappings": [ "@gnosis/=lib/@gnosis/", "@gnosis/auction/=lib/@gnosis/auction/contracts/", "@openzeppelin/=lib/@openzeppelin/contracts/", "@openzeppelin/contracts/=lib/@openzeppelin/contracts/contracts/", "@uniswap/=lib/@uniswap/", "ds-test/=lib/forge-std/lib/ds-test/src/", "forge-std/=lib/forge-std/src/" ], "optimizer": { "enabled": true, "runs": 200 }, "metadata": { "bytecodeHash": "ipfs" }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "evmVersion": "london", "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[{"internalType":"address","name":"_self","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"}],"name":"Blocked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"}],"name":"BlocklisterChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"hash","type":"bytes32"}],"name":"CancelledRecovery","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"hash","type":"bytes32"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"ExecutedRecovery","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":"bytes32","name":"hash","type":"bytes32"},{"indexed":false,"internalType":"uint256","name":"requestTimestamp","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"executionTimestamp","type":"uint256"},{"indexed":false,"internalType":"address[]","name":"accounts","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"values","type":"uint256[]"}],"name":"RequestedRecovery","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"}],"name":"Unblocked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"minter","type":"address"},{"indexed":false,"internalType":"bool","name":"canMint","type":"bool"},{"indexed":false,"internalType":"bool","name":"canBurn","type":"bool"}],"name":"UpdateMinter","type":"event"},{"inputs":[],"name":"DOMAIN_SEPARATOR","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"PERMIT_TYPEHASH","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SALTED_PERMIT_TYPEHASH","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"_balance","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"blockAccount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"blocklister","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_value","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"cancelRecovery","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"address","name":"_to","type":"address"}],"name":"claimTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_accounts","type":"address[]"},{"internalType":"uint256[]","name":"_values","type":"uint256[]"}],"name":"executeRecovery","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"isBlocked","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"isBurner","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"isMinter","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isRecoveryEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"nonces","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_holder","type":"address"},{"internalType":"address","name":"_spender","type":"address"},{"internalType":"uint256","name":"_value","type":"uint256"},{"internalType":"uint256","name":"_deadline","type":"uint256"},{"internalType":"uint8","name":"_v","type":"uint8"},{"internalType":"bytes32","name":"_r","type":"bytes32"},{"internalType":"bytes32","name":"_s","type":"bytes32"}],"name":"permit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_holder","type":"address"},{"internalType":"uint256","name":"_value","type":"uint256"},{"internalType":"uint256","name":"_deadline","type":"uint256"},{"internalType":"uint8","name":"_v","type":"uint8"},{"internalType":"bytes32","name":"_r","type":"bytes32"},{"internalType":"bytes32","name":"_s","type":"bytes32"}],"name":"receiveWithPermit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_holder","type":"address"},{"internalType":"uint256","name":"_value","type":"uint256"},{"internalType":"uint256","name":"_deadline","type":"uint256"},{"internalType":"bytes32","name":"_salt","type":"bytes32"},{"internalType":"uint8","name":"_v","type":"uint8"},{"internalType":"bytes32","name":"_r","type":"bytes32"},{"internalType":"bytes32","name":"_s","type":"bytes32"}],"name":"receiveWithSaltedPermit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"recoveredFundsReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"recoveryAdmin","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"recoveryLimitPercent","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"recoveryRequestExecutionTimestamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"recoveryRequestHash","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"recoveryRequestTimelockPeriod","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_accounts","type":"address[]"},{"internalType":"uint256[]","name":"_values","type":"uint256[]"}],"name":"requestRecovery","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_claimingAdmin","type":"address"}],"name":"setClaimingAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_recoveredFundsReceiver","type":"address"}],"name":"setRecoveredFundsReceiver","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_recoveryAdmin","type":"address"}],"name":"setRecoveryAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint64","name":"_recoveryLimitPercent","type":"uint64"}],"name":"setRecoveryLimitPercent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint32","name":"_recoveryRequestTimelockPeriod","type":"uint32"}],"name":"setRecoveryRequestTimelockPeriod","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalRecovered","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"transferAndCall","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"unblockAccount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_newBlocklister","type":"address"}],"name":"updateBlocklister","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"bool","name":"_canMint","type":"bool"},{"internalType":"bool","name":"_canBurn","type":"bool"}],"name":"updateMinter","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
6101406040523480156200001257600080fd5b50604051620031f1380380620031f183398101604081905262000035916200016f565b8080620000586040805180820190915260038152622127a160e91b602082015290565b6040805180820190915260018152603160f81b60208201526200007b336200011f565b815160209283012081519183019190912060e08290526101008190524660a0818152604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f8188018190528183019690965260608101949094526080808501939093526001600160a01b03969096168382018190528651808503909201825260c093840190965280519401939093209092529190526101205250620001a19050565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000602082840312156200018257600080fd5b81516001600160a01b03811681146200019a57600080fd5b9392505050565b60805160a05160c05160e0516101005161012051613000620001f16000396000611b7b01526000611bca01526000611ba501526000611afe01526000611b2801526000611b5201526130006000f3fe608060405234801561001057600080fd5b50600436106102bb5760003560e01c80637ecebe0011610182578063b88e9ca2116100e9578063d92118c2116100a2578063f2fde38b1161007c578063f2fde38b146106d9578063f9b5aa92146106ec578063fa3e36e7146106ff578063fbac39511461071257600080fd5b8063d92118c214610688578063dd62ed3e1461069b578063e6c10d2a146106c657600080fd5b8063b88e9ca214610620578063bb7b734f14610633578063ca1a6fbb14610646578063d1f58d261461064f578063d4113cfb14610662578063d505accf1461067557600080fd5b8063a457c2d71161013b578063a457c2d71461057d578063a744eec814610590578063a871f4d1146105c4578063a9059cbb146105cc578063aa271e1a146105df578063b54d94971461060d57600080fd5b80637ecebe00146104f05780637f0159b6146105105780638da5cb5b1461053757806395d89b41146102d557806398fd662414610548578063a104e1121461057457600080fd5b80634000aea0116102265780635937f650116101df5780635937f6501461046a5780635f6529a31461047d57806369ffa08a1461049057806370a08231146104a3578063715018a6146104d55780637c0a893d146104dd57600080fd5b80634000aea0146103e757806340c10f19146103fa57806342966c681461040d5780634334614a146104205780634d78fdc61461044e57806353d3e8711461046157600080fd5b806323b872dd1161027857806323b872dd1461035857806330adf81f1461036b578063313ce5671461039257806334ed26e4146103a15780633644e515146103cc57806339509351146103d457600080fd5b8063027e231b146102c057806306fdde03146102d5578063095ea7b3146103035780630ba234d61461032657806318160ddd1461032e57806319dc47e814610345575b600080fd5b6102d36102ce3660046127ac565b610742565b005b60408051808201825260038152622127a160e91b602082015290516102fa919061281b565b60405180910390f35b61031661031136600461282e565b61076c565b60405190151581526020016102fa565b6102d3610782565b61033760035481565b6040519081526020016102fa565b6102d3610353366004612858565b610823565b61031661036636600461287e565b610917565b6103377f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b604051601281526020016102fa565b6007546103b4906001600160a01b031681565b6040516001600160a01b0390911681526020016102fa565b610337610939565b6103166103e236600461282e565b610948565b6102d36103f53660046128ba565b610984565b6102d361040836600461282e565b610a56565b6102d361041b366004612941565b610ac3565b61031661042e3660046127ac565b6001600160a01b0316600090815260056020526040902054600116151590565b6102d361045c3660046127ac565b610b2f565b610337600a5481565b6102d36104783660046127ac565b610bba565b6006546103b4906001600160a01b031681565b6102d361049e36600461295a565b610be4565b6103376104b13660046127ac565b6001600160a01b03166000908152600160205260409020546001600160ff1b031690565b6102d3610d8e565b6102d36104eb3660046127ac565b610da2565b6103376104fe3660046127ac565b60046020526000908152604090205481565b6103377f4bcf1917b4c6060d0cfc29abba53999d42824efa953155f8c376edb9e22cad8c81565b6000546001600160a01b03166103b4565b60075461055f90600160e01b900463ffffffff1681565b60405163ffffffff90911681526020016102fa565b61033760095481565b61031661058b36600461282e565b610e2a565b6007546105ab90600160a01b900467ffffffffffffffff1681565b60405167ffffffffffffffff90911681526020016102fa565b610316610eb9565b6103166105da36600461282e565b610eca565b6103166105ed3660046127ac565b6001600160a01b0316600090815260056020526040902054600216151590565b600b546103b4906001600160a01b031681565b6102d361062e36600461299e565b610ed7565b6102d3610641366004612a04565b610f45565b61033760085481565b6102d361065d366004612a4d565b610fe3565b6102d36106703660046127ac565b61107b565b6102d3610683366004612a77565b6110a5565b6102d3610696366004612b2d565b6110c8565b6103376106a936600461295a565b600260209081526000928352604080842090915290825290205481565b6102d36106d4366004612b2d565b611427565b6102d36106e73660046127ac565b61166c565b6102d36106fa3660046127ac565b6116e2565b6102d361070d366004612b99565b611734565b6103166107203660046127ac565b6001600160a01b0316600090815260016020526040902054600160ff1b111590565b61074a61179b565b600c80546001600160a01b0319166001600160a01b0392909216919091179055565b60006107793384846117ef565b50600192915050565b6006546001600160a01b0316336001600160a01b031614806107a757506107a7611914565b6107cc5760405162461bcd60e51b81526004016107c390612be0565b60405180910390fd5b600954806107ec5760405162461bcd60e51b81526004016107c390612c25565b60006009819055600a81905560405182917f498f8458de594d5a7326e3c17e836ba5a763e96022d30c5a1f0736ba65e9d0ca91a250565b61082b61179b565b620151808163ffffffff16101561088e5760405162461bcd60e51b815260206004820152602160248201527f5265636f766572793a20746f6f206c6f772074696d656c6f636b20706572696f6044820152601960fa1b60648201526084016107c3565b62278d008163ffffffff1611156108f25760405162461bcd60e51b815260206004820152602260248201527f5265636f766572793a20746f6f20686967682074696d656c6f636b20706572696044820152611bd960f21b60648201526084016107c3565b6007805463ffffffff909216600160e01b026001600160e01b03909216919091179055565b6000610924843384611958565b61092f8484846119e4565b5060019392505050565b6000610943611af1565b905090565b3360008181526002602090815260408083206001600160a01b0387168452909152812054909161077991859061097f908690612c7f565b6117ef565b61098f3385856119e4565b604051635260769b60e11b81526001600160a01b0385169063a4c0ed36906109c1903390879087908790600401612c97565b6020604051808303816000875af11580156109e0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a049190612cdf565b610a505760405162461bcd60e51b815260206004820152601760248201527f4552433637373a2063616c6c6261636b206661696c656400000000000000000060448201526064016107c3565b50505050565b33600090815260056020526040902054600216610ab55760405162461bcd60e51b815260206004820152601b60248201527f45524332304d696e744275726e3a206e6f742061206d696e746572000000000060448201526064016107c3565b610abf8282611c18565b5050565b33600090815260056020526040902054600116610b225760405162461bcd60e51b815260206004820152601b60248201527f45524332304d696e744275726e3a206e6f742061206275726e6572000000000060448201526064016107c3565b610b2c3382611cc4565b50565b600b546001600160a01b03163314610b595760405162461bcd60e51b81526004016107c390612cfc565b610b83816001600160a01b0316600090815260016020526040902080546001600160ff1b03169055565b6040516001600160a01b038216907f5c272fb29e21b46870af1850afe89126704c55a7781cc100da3f733e15446c7d90600090a250565b610bc261179b565b600680546001600160a01b0319166001600160a01b0392909216919091179055565b600c546001600160a01b0316336001600160a01b03161480610c095750610c09611914565b610c645760405162461bcd60e51b815260206004820152602660248201527f436c61696d61626c653a206e6f7420617574686f72697a656420666f7220636c60448201526561696d696e6760d01b60648201526084016107c3565b6001600160a01b038216610cac576040516001600160a01b038216904780156108fc02916000818181858888f19350505050158015610ca7573d6000803e3d6000fd5b505050565b6040516370a0823160e01b81523060048201526000906001600160a01b038416906370a0823190602401602060405180830381865afa158015610cf3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d179190612d44565b60405163a9059cbb60e01b81526001600160a01b038481166004830152602482018390529192509084169063a9059cbb906044016020604051808303816000875af1158015610d6a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a509190612cdf565b610d9661179b565b610da06000611d71565b565b600b546001600160a01b03163314610dcc5760405162461bcd60e51b81526004016107c390612cfc565b610df3816001600160a01b031660009081526001602052604090208054600160ff1b179055565b6040516001600160a01b038216907f75e91ce73c1d3352d8dd3610443539cd33dfe13b1de8f8caae54ec26dd0dc9cb90600090a250565b3360009081526002602090815260408083206001600160a01b038616845290915281205482811015610eac5760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b60648201526084016107c3565b61092f33858584036117ef565b600080610ec4611dc1565b11905090565b60006107793384846119e4565b610ee686338787878787611e39565b60405185815233906001600160a01b038816907f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259060200160405180910390a3610f32863360006117ef565b610f3d8633876119e4565b505050505050565b610f4d61179b565b80610f59576000610f5c565b60015b82610f68576000610f6b565b60025b610f759190612d5d565b6001600160a01b0384166000818152600560205260409081902060ff9390931690925590517fb625581fc22318da180188590e00c281ecdfbb5d9d538c35740a9564b17889dc90610fd6908590859091151582521515602082015260400190565b60405180910390a2505050565b610feb61179b565b670de0b6b3a76400008167ffffffffffffffff16111561104d5760405162461bcd60e51b815260206004820152601c60248201527f5265636f766572793a20696e76616c69642070657263656e746167650000000060448201526064016107c3565b6007805467ffffffffffffffff909216600160a01b0267ffffffffffffffff60a01b19909216919091179055565b61108361179b565b600780546001600160a01b0319166001600160a01b0392909216919091179055565b6110b487878787878787611e39565b6110bf8787876117ef565b50505050505050565b6006546001600160a01b0316336001600160a01b031614806110ed57506110ed611914565b6111095760405162461bcd60e51b81526004016107c390612be0565b8281146111585760405162461bcd60e51b815260206004820152601b60248201527f5265636f766572793a20646966666572656e74206c656e67746873000000000060448201526064016107c3565b826111a55760405162461bcd60e51b815260206004820152601860248201527f5265636f766572793a20656d707479206163636f756e7473000000000000000060448201526064016107c3565b60006111af611dc1565b9050600081116111f95760405162461bcd60e51b8152602060048201526015602482015274149958dbdd995c9e4e881b9bdd08195b98589b1959605a1b60448201526064016107c3565b600954801561122e5760405181907f498f8458de594d5a7326e3c17e836ba5a763e96022d30c5a1f0736ba65e9d0ca90600090a25b60008367ffffffffffffffff81111561124957611249612d82565b604051908082528060200260200182016040528015611272578160200160208202803683370190505b5090506000805b858110156113315760006112ad8a8a8481811061129857611298612d98565b90506020020160208101906104b191906127ac565b905060008888848181106112c3576112c3612d98565b9050602002013582106112ee578888848181106112e2576112e2612d98565b905060200201356112f0565b815b90508085848151811061130557611305612d98565b602090810291909101015261131a8185612c7f565b93505050808061132990612dae565b915050611279565b50838111156113825760405162461bcd60e51b815260206004820152601f60248201527f5265636f766572793a20657863656564207265636f76657279206c696d69740060448201526064016107c3565b60075460009061139f90600160e01b900463ffffffff1642612c7f565b9050808989856040516020016113b89493929190612e3e565b60408051601f198184030181529082905280516020909101206009819055600a839055945084907f67574952c8fe8f773bb77d781f3a57dd157f12f205efbe810810384a8d2a00149061141490429085908e908e908a90612e75565b60405180910390a2505050505050505050565b6006546001600160a01b0316336001600160a01b0316148061144c575061144c611914565b6114685760405162461bcd60e51b81526004016107c390612be0565b600a805460009091558061148e5760405162461bcd60e51b81526004016107c390612c25565b428111156114e95760405162461bcd60e51b815260206004820152602260248201527f5265636f766572793a2072657175657374207374696c6c2074696d656c6f636b604482015261195960f21b60648201526084016107c3565b60006114f3611dc1565b90506000811161153d5760405162461bcd60e51b8152602060048201526015602482015274149958dbdd995c9e4e881b9bdd08195b98589b1959605a1b60448201526064016107c3565b6000600954905060096000905560008388888888604051602001611565959493929190612eb3565b6040516020818303038152906040528051906020012090508082146115da5760405162461bcd60e51b815260206004820152602560248201527f5265636f766572793a20726571756573742068617368657320646f206e6f74206044820152640dac2e8c6d60db1b60648201526084016107c3565b60006115e889898989611ff2565b90508381111561163a5760405162461bcd60e51b815260206004820152601f60248201527f5265636f766572793a20657863656564207265636f76657279206c696d69740060448201526064016107c3565b827fbdbd8667b6c12f94c5a90a10097bfa133de72220146fefc2f5ff04b86cc6ae1a8260405161141491815260200190565b61167461179b565b6001600160a01b0381166116d95760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016107c3565b610b2c81611d71565b6116ea61179b565b600b80546001600160a01b0319166001600160a01b0383169081179091556040517f68f10ceb42d30acc930aaaedf5b94559e14fc4f22496dc2c1b38b1b1b5231f9890600090a250565b61174487338888888888886121fa565b60405186815233906001600160a01b038916907f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259060200160405180910390a3611790873360006117ef565b6110bf8733886119e4565b6117a3611914565b610da05760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107c3565b6001600160a01b0383166118515760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b60648201526084016107c3565b6001600160a01b0382166118b25760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b60648201526084016107c3565b6001600160a01b0383811660008181526002602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b600061191e612365565b8061094357507fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035433905b6001600160a01b031614905090565b6001600160a01b038084166000908152600260209081526040808320938616835292905220546000198114610a5057818110156119d75760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e636500000060448201526064016107c3565b610a5084848484036117ef565b6001600160a01b038316611a485760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b60648201526084016107c3565b6001600160a01b038216611aaa5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b60648201526084016107c3565b611ab48382612379565b611abe828261244c565b816001600160a01b0316836001600160a01b0316600080516020612fab8339815191528360405161190791815260200190565b6000306001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016148015611b4a57507f000000000000000000000000000000000000000000000000000000000000000046145b15611b7457507f000000000000000000000000000000000000000000000000000000000000000090565b50604080517f00000000000000000000000000000000000000000000000000000000000000006020808301919091527f0000000000000000000000000000000000000000000000000000000000000000828401527f000000000000000000000000000000000000000000000000000000000000000060608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b6001600160a01b038216611c6e5760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016107c3565b8060036000828254611c809190612c7f565b90915550611c909050828261244c565b6040518181526001600160a01b03831690600090600080516020612fab833981519152906020015b60405180910390a35050565b6001600160a01b038216611d245760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b60648201526084016107c3565b611d2e8282612379565b8060036000828254611d409190612f0c565b90915550506040518181526000906001600160a01b03841690600080516020612fab83398151915290602001611cb8565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6007546000906001600160a01b0316611dda5750600090565b600754600354600091670de0b6b3a764000091611e0891600160a01b900467ffffffffffffffff1690612f23565b611e129190612f42565b9050600854811115611e3157600854611e2b9082612f0c565b91505090565b600091505090565b83421115611e895760405162461bcd60e51b815260206004820152601b60248201527f45524332305065726d69743a2065787069726564207065726d6974000000000060448201526064016107c3565b6001600160a01b038716600090815260046020526040812080549082611eae83612dae565b9190505590506000611f6a611ec1611af1565b604080517f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c960208201526001600160a01b03808e1692820192909252908b166060820152608081018a905260a0810185905260c0810189905260e0015b60408051601f19818403018152828252805160209182012061190160f01b8483015260228401949094526042808401949094528151808403909401845260629092019052815191012090565b9050611f78818686866124cf565b6001600160a01b0316896001600160a01b031614611fe75760405162461bcd60e51b815260206004820152602660248201527f45524332305065726d69743a20696e76616c69642045524332363132207369676044820152656e617475726560d01b60648201526084016107c3565b505050505050505050565b60075460009081906001600160a01b0316815b8681101561213557600061202489898481811061129857611298612d98565b9050600087878481811061203a5761203a612d98565b9050602002013582106120655787878481811061205957612059612d98565b90506020020135612067565b815b90506120738186612c7f565b94506120bf8a8a8581811061208a5761208a612d98565b905060200201602081019061209f91906127ac565b6001600160a01b0316600090815260016020526040902080548390039055565b836001600160a01b03168a8a858181106120db576120db612d98565b90506020020160208101906120f091906127ac565b6001600160a01b0316600080516020612fab8339815191528360405161211891815260200190565b60405180910390a35050808061212d90612dae565b915050612005565b50612140818361244c565b81600860008282546121529190612c7f565b90915550506001600160a01b0381163b156121f05760408051600081526020810191829052635260769b60e11b9091526001600160a01b0382169063a4c0ed36906121a4903090869060248101612f64565b6020604051808303816000875af11580156121c3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906121e79190612cdf565b6121f057600080fd5b5095945050505050565b8442111561224a5760405162461bcd60e51b815260206004820152601b60248201527f45524332305065726d69743a2065787069726564207065726d6974000000000060448201526064016107c3565b6001600160a01b03881660009081526004602052604081208054908261226f83612dae565b91905055905060006122eb612282611af1565b604080517f4bcf1917b4c6060d0cfc29abba53999d42824efa953155f8c376edb9e22cad8c60208201526001600160a01b03808f1692820192909252908c166060820152608081018b905260a0810185905260c081018a905260e0810189905261010001611f1e565b90506122f9818686866124cf565b6001600160a01b03168a6001600160a01b0316146123595760405162461bcd60e51b815260206004820152601e60248201527f45524332305065726d69743a20696e76616c6964207369676e6174757265000060448201526064016107c3565b50505050505050505050565b6000805433906001600160a01b0316611949565b6001600160a01b038216600090815260016020526040902054600160ff1b81106123dd5760405162461bcd60e51b815260206004820152601560248201527422a92199181d1030b1b1b7bab73a10333937bd32b760591b60448201526064016107c3565b8181101561242d5760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20616d6f756e7420657863656564732062616c616e636500000060448201526064016107c3565b6001600160a01b03909216600090815260016020526040902091039055565b6001600160a01b038216600090815260016020526040902054600160ff1b81106124b05760405162461bcd60e51b815260206004820152601560248201527422a92199181d1030b1b1b7bab73a10333937bd32b760591b60448201526064016107c3565b6001600160a01b03909216600090815260016020526040902091019055565b60008060006124e0878787876124ed565b915091506121f0816125da565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a083111561252457506000905060036125d1565b8460ff16601b1415801561253c57508460ff16601c14155b1561254d57506000905060046125d1565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa1580156125a1573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381166125ca576000600192509250506125d1565b9150600090505b94509492505050565b60008160048111156125ee576125ee612f94565b036125f65750565b600181600481111561260a5761260a612f94565b036126575760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e6174757265000000000000000060448201526064016107c3565b600281600481111561266b5761266b612f94565b036126b85760405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e6774680060448201526064016107c3565b60038160048111156126cc576126cc612f94565b036127245760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c604482015261756560f01b60648201526084016107c3565b600481600481111561273857612738612f94565b03610b2c5760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202776272076616c604482015261756560f01b60648201526084016107c3565b80356001600160a01b03811681146127a757600080fd5b919050565b6000602082840312156127be57600080fd5b6127c782612790565b9392505050565b6000815180845260005b818110156127f4576020818501810151868301820152016127d8565b81811115612806576000602083870101525b50601f01601f19169290920160200192915050565b6020815260006127c760208301846127ce565b6000806040838503121561284157600080fd5b61284a83612790565b946020939093013593505050565b60006020828403121561286a57600080fd5b813563ffffffff811681146127c757600080fd5b60008060006060848603121561289357600080fd5b61289c84612790565b92506128aa60208501612790565b9150604084013590509250925092565b600080600080606085870312156128d057600080fd5b6128d985612790565b935060208501359250604085013567ffffffffffffffff808211156128fd57600080fd5b818701915087601f83011261291157600080fd5b81358181111561292057600080fd5b88602082850101111561293257600080fd5b95989497505060200194505050565b60006020828403121561295357600080fd5b5035919050565b6000806040838503121561296d57600080fd5b61297683612790565b915061298460208401612790565b90509250929050565b803560ff811681146127a757600080fd5b60008060008060008060c087890312156129b757600080fd5b6129c087612790565b955060208701359450604087013593506129dc6060880161298d565b92506080870135915060a087013590509295509295509295565b8015158114610b2c57600080fd5b600080600060608486031215612a1957600080fd5b612a2284612790565b92506020840135612a32816129f6565b91506040840135612a42816129f6565b809150509250925092565b600060208284031215612a5f57600080fd5b813567ffffffffffffffff811681146127c757600080fd5b600080600080600080600060e0888a031215612a9257600080fd5b612a9b88612790565b9650612aa960208901612790565b95506040880135945060608801359350612ac56080890161298d565b925060a0880135915060c0880135905092959891949750929550565b60008083601f840112612af357600080fd5b50813567ffffffffffffffff811115612b0b57600080fd5b6020830191508360208260051b8501011115612b2657600080fd5b9250929050565b60008060008060408587031215612b4357600080fd5b843567ffffffffffffffff80821115612b5b57600080fd5b612b6788838901612ae1565b90965094506020870135915080821115612b8057600080fd5b50612b8d87828801612ae1565b95989497509550505050565b600080600080600080600060e0888a031215612bb457600080fd5b612bbd88612790565b9650602088013595506040880135945060608801359350612ac56080890161298d565b60208082526025908201527f5265636f766572793a206e6f7420617574686f72697a656420666f72207265636040820152646f7665727960d81b606082015260800190565b60208082526024908201527f5265636f766572793a206e6f20616374697665207265636f76657279207265716040820152631d595cdd60e21b606082015260800190565b634e487b7160e01b600052601160045260246000fd5b60008219821115612c9257612c92612c69565b500190565b6001600160a01b0385168152602081018490526060604082018190528101829052818360808301376000818301608090810191909152601f909201601f191601019392505050565b600060208284031215612cf157600080fd5b81516127c7816129f6565b60208082526028908201527f426c6f636b6c6973743a2063616c6c6572206973206e6f742074686520626c6f60408201526731b5b634b9ba32b960c11b606082015260800190565b600060208284031215612d5657600080fd5b5051919050565b600060ff821660ff84168060ff03821115612d7a57612d7a612c69565b019392505050565b634e487b7160e01b600052604160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b600060018201612dc057612dc0612c69565b5060010190565b8183526000602080850194508260005b85811015612e03576001600160a01b03612df083612790565b1687529582019590820190600101612dd7565b509495945050505050565b600081518084526020808501945080840160005b83811015612e0357815187529582019590820190600101612e22565b848152606060208201526000612e58606083018587612dc7565b8281036040840152612e6a8185612e0e565b979650505050505050565b858152846020820152608060408201526000612e95608083018587612dc7565b8281036060840152612ea78185612e0e565b98975050505050505050565b858152606060208201526000612ecd606083018688612dc7565b82810360408401528381526001600160fb1b03841115612eec57600080fd5b8360051b8086602084013760009101602001908152979650505050505050565b600082821015612f1e57612f1e612c69565b500390565b6000816000190483118215151615612f3d57612f3d612c69565b500290565b600082612f5f57634e487b7160e01b600052601260045260246000fd5b500490565b60018060a01b0384168152826020820152606060408201526000612f8b60608301846127ce565b95945050505050565b634e487b7160e01b600052602160045260246000fdfeddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220e9729829fb1fe0e31764ab359a615f2d8608bd49786757d008d625840589cad764736f6c634300080f0033000000000000000000000000b0b195aefa3650a6908f15cdac7d92f8a5791b0b
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106102bb5760003560e01c80637ecebe0011610182578063b88e9ca2116100e9578063d92118c2116100a2578063f2fde38b1161007c578063f2fde38b146106d9578063f9b5aa92146106ec578063fa3e36e7146106ff578063fbac39511461071257600080fd5b8063d92118c214610688578063dd62ed3e1461069b578063e6c10d2a146106c657600080fd5b8063b88e9ca214610620578063bb7b734f14610633578063ca1a6fbb14610646578063d1f58d261461064f578063d4113cfb14610662578063d505accf1461067557600080fd5b8063a457c2d71161013b578063a457c2d71461057d578063a744eec814610590578063a871f4d1146105c4578063a9059cbb146105cc578063aa271e1a146105df578063b54d94971461060d57600080fd5b80637ecebe00146104f05780637f0159b6146105105780638da5cb5b1461053757806395d89b41146102d557806398fd662414610548578063a104e1121461057457600080fd5b80634000aea0116102265780635937f650116101df5780635937f6501461046a5780635f6529a31461047d57806369ffa08a1461049057806370a08231146104a3578063715018a6146104d55780637c0a893d146104dd57600080fd5b80634000aea0146103e757806340c10f19146103fa57806342966c681461040d5780634334614a146104205780634d78fdc61461044e57806353d3e8711461046157600080fd5b806323b872dd1161027857806323b872dd1461035857806330adf81f1461036b578063313ce5671461039257806334ed26e4146103a15780633644e515146103cc57806339509351146103d457600080fd5b8063027e231b146102c057806306fdde03146102d5578063095ea7b3146103035780630ba234d61461032657806318160ddd1461032e57806319dc47e814610345575b600080fd5b6102d36102ce3660046127ac565b610742565b005b60408051808201825260038152622127a160e91b602082015290516102fa919061281b565b60405180910390f35b61031661031136600461282e565b61076c565b60405190151581526020016102fa565b6102d3610782565b61033760035481565b6040519081526020016102fa565b6102d3610353366004612858565b610823565b61031661036636600461287e565b610917565b6103377f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b604051601281526020016102fa565b6007546103b4906001600160a01b031681565b6040516001600160a01b0390911681526020016102fa565b610337610939565b6103166103e236600461282e565b610948565b6102d36103f53660046128ba565b610984565b6102d361040836600461282e565b610a56565b6102d361041b366004612941565b610ac3565b61031661042e3660046127ac565b6001600160a01b0316600090815260056020526040902054600116151590565b6102d361045c3660046127ac565b610b2f565b610337600a5481565b6102d36104783660046127ac565b610bba565b6006546103b4906001600160a01b031681565b6102d361049e36600461295a565b610be4565b6103376104b13660046127ac565b6001600160a01b03166000908152600160205260409020546001600160ff1b031690565b6102d3610d8e565b6102d36104eb3660046127ac565b610da2565b6103376104fe3660046127ac565b60046020526000908152604090205481565b6103377f4bcf1917b4c6060d0cfc29abba53999d42824efa953155f8c376edb9e22cad8c81565b6000546001600160a01b03166103b4565b60075461055f90600160e01b900463ffffffff1681565b60405163ffffffff90911681526020016102fa565b61033760095481565b61031661058b36600461282e565b610e2a565b6007546105ab90600160a01b900467ffffffffffffffff1681565b60405167ffffffffffffffff90911681526020016102fa565b610316610eb9565b6103166105da36600461282e565b610eca565b6103166105ed3660046127ac565b6001600160a01b0316600090815260056020526040902054600216151590565b600b546103b4906001600160a01b031681565b6102d361062e36600461299e565b610ed7565b6102d3610641366004612a04565b610f45565b61033760085481565b6102d361065d366004612a4d565b610fe3565b6102d36106703660046127ac565b61107b565b6102d3610683366004612a77565b6110a5565b6102d3610696366004612b2d565b6110c8565b6103376106a936600461295a565b600260209081526000928352604080842090915290825290205481565b6102d36106d4366004612b2d565b611427565b6102d36106e73660046127ac565b61166c565b6102d36106fa3660046127ac565b6116e2565b6102d361070d366004612b99565b611734565b6103166107203660046127ac565b6001600160a01b0316600090815260016020526040902054600160ff1b111590565b61074a61179b565b600c80546001600160a01b0319166001600160a01b0392909216919091179055565b60006107793384846117ef565b50600192915050565b6006546001600160a01b0316336001600160a01b031614806107a757506107a7611914565b6107cc5760405162461bcd60e51b81526004016107c390612be0565b60405180910390fd5b600954806107ec5760405162461bcd60e51b81526004016107c390612c25565b60006009819055600a81905560405182917f498f8458de594d5a7326e3c17e836ba5a763e96022d30c5a1f0736ba65e9d0ca91a250565b61082b61179b565b620151808163ffffffff16101561088e5760405162461bcd60e51b815260206004820152602160248201527f5265636f766572793a20746f6f206c6f772074696d656c6f636b20706572696f6044820152601960fa1b60648201526084016107c3565b62278d008163ffffffff1611156108f25760405162461bcd60e51b815260206004820152602260248201527f5265636f766572793a20746f6f20686967682074696d656c6f636b20706572696044820152611bd960f21b60648201526084016107c3565b6007805463ffffffff909216600160e01b026001600160e01b03909216919091179055565b6000610924843384611958565b61092f8484846119e4565b5060019392505050565b6000610943611af1565b905090565b3360008181526002602090815260408083206001600160a01b0387168452909152812054909161077991859061097f908690612c7f565b6117ef565b61098f3385856119e4565b604051635260769b60e11b81526001600160a01b0385169063a4c0ed36906109c1903390879087908790600401612c97565b6020604051808303816000875af11580156109e0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a049190612cdf565b610a505760405162461bcd60e51b815260206004820152601760248201527f4552433637373a2063616c6c6261636b206661696c656400000000000000000060448201526064016107c3565b50505050565b33600090815260056020526040902054600216610ab55760405162461bcd60e51b815260206004820152601b60248201527f45524332304d696e744275726e3a206e6f742061206d696e746572000000000060448201526064016107c3565b610abf8282611c18565b5050565b33600090815260056020526040902054600116610b225760405162461bcd60e51b815260206004820152601b60248201527f45524332304d696e744275726e3a206e6f742061206275726e6572000000000060448201526064016107c3565b610b2c3382611cc4565b50565b600b546001600160a01b03163314610b595760405162461bcd60e51b81526004016107c390612cfc565b610b83816001600160a01b0316600090815260016020526040902080546001600160ff1b03169055565b6040516001600160a01b038216907f5c272fb29e21b46870af1850afe89126704c55a7781cc100da3f733e15446c7d90600090a250565b610bc261179b565b600680546001600160a01b0319166001600160a01b0392909216919091179055565b600c546001600160a01b0316336001600160a01b03161480610c095750610c09611914565b610c645760405162461bcd60e51b815260206004820152602660248201527f436c61696d61626c653a206e6f7420617574686f72697a656420666f7220636c60448201526561696d696e6760d01b60648201526084016107c3565b6001600160a01b038216610cac576040516001600160a01b038216904780156108fc02916000818181858888f19350505050158015610ca7573d6000803e3d6000fd5b505050565b6040516370a0823160e01b81523060048201526000906001600160a01b038416906370a0823190602401602060405180830381865afa158015610cf3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d179190612d44565b60405163a9059cbb60e01b81526001600160a01b038481166004830152602482018390529192509084169063a9059cbb906044016020604051808303816000875af1158015610d6a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a509190612cdf565b610d9661179b565b610da06000611d71565b565b600b546001600160a01b03163314610dcc5760405162461bcd60e51b81526004016107c390612cfc565b610df3816001600160a01b031660009081526001602052604090208054600160ff1b179055565b6040516001600160a01b038216907f75e91ce73c1d3352d8dd3610443539cd33dfe13b1de8f8caae54ec26dd0dc9cb90600090a250565b3360009081526002602090815260408083206001600160a01b038616845290915281205482811015610eac5760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b60648201526084016107c3565b61092f33858584036117ef565b600080610ec4611dc1565b11905090565b60006107793384846119e4565b610ee686338787878787611e39565b60405185815233906001600160a01b038816907f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259060200160405180910390a3610f32863360006117ef565b610f3d8633876119e4565b505050505050565b610f4d61179b565b80610f59576000610f5c565b60015b82610f68576000610f6b565b60025b610f759190612d5d565b6001600160a01b0384166000818152600560205260409081902060ff9390931690925590517fb625581fc22318da180188590e00c281ecdfbb5d9d538c35740a9564b17889dc90610fd6908590859091151582521515602082015260400190565b60405180910390a2505050565b610feb61179b565b670de0b6b3a76400008167ffffffffffffffff16111561104d5760405162461bcd60e51b815260206004820152601c60248201527f5265636f766572793a20696e76616c69642070657263656e746167650000000060448201526064016107c3565b6007805467ffffffffffffffff909216600160a01b0267ffffffffffffffff60a01b19909216919091179055565b61108361179b565b600780546001600160a01b0319166001600160a01b0392909216919091179055565b6110b487878787878787611e39565b6110bf8787876117ef565b50505050505050565b6006546001600160a01b0316336001600160a01b031614806110ed57506110ed611914565b6111095760405162461bcd60e51b81526004016107c390612be0565b8281146111585760405162461bcd60e51b815260206004820152601b60248201527f5265636f766572793a20646966666572656e74206c656e67746873000000000060448201526064016107c3565b826111a55760405162461bcd60e51b815260206004820152601860248201527f5265636f766572793a20656d707479206163636f756e7473000000000000000060448201526064016107c3565b60006111af611dc1565b9050600081116111f95760405162461bcd60e51b8152602060048201526015602482015274149958dbdd995c9e4e881b9bdd08195b98589b1959605a1b60448201526064016107c3565b600954801561122e5760405181907f498f8458de594d5a7326e3c17e836ba5a763e96022d30c5a1f0736ba65e9d0ca90600090a25b60008367ffffffffffffffff81111561124957611249612d82565b604051908082528060200260200182016040528015611272578160200160208202803683370190505b5090506000805b858110156113315760006112ad8a8a8481811061129857611298612d98565b90506020020160208101906104b191906127ac565b905060008888848181106112c3576112c3612d98565b9050602002013582106112ee578888848181106112e2576112e2612d98565b905060200201356112f0565b815b90508085848151811061130557611305612d98565b602090810291909101015261131a8185612c7f565b93505050808061132990612dae565b915050611279565b50838111156113825760405162461bcd60e51b815260206004820152601f60248201527f5265636f766572793a20657863656564207265636f76657279206c696d69740060448201526064016107c3565b60075460009061139f90600160e01b900463ffffffff1642612c7f565b9050808989856040516020016113b89493929190612e3e565b60408051601f198184030181529082905280516020909101206009819055600a839055945084907f67574952c8fe8f773bb77d781f3a57dd157f12f205efbe810810384a8d2a00149061141490429085908e908e908a90612e75565b60405180910390a2505050505050505050565b6006546001600160a01b0316336001600160a01b0316148061144c575061144c611914565b6114685760405162461bcd60e51b81526004016107c390612be0565b600a805460009091558061148e5760405162461bcd60e51b81526004016107c390612c25565b428111156114e95760405162461bcd60e51b815260206004820152602260248201527f5265636f766572793a2072657175657374207374696c6c2074696d656c6f636b604482015261195960f21b60648201526084016107c3565b60006114f3611dc1565b90506000811161153d5760405162461bcd60e51b8152602060048201526015602482015274149958dbdd995c9e4e881b9bdd08195b98589b1959605a1b60448201526064016107c3565b6000600954905060096000905560008388888888604051602001611565959493929190612eb3565b6040516020818303038152906040528051906020012090508082146115da5760405162461bcd60e51b815260206004820152602560248201527f5265636f766572793a20726571756573742068617368657320646f206e6f74206044820152640dac2e8c6d60db1b60648201526084016107c3565b60006115e889898989611ff2565b90508381111561163a5760405162461bcd60e51b815260206004820152601f60248201527f5265636f766572793a20657863656564207265636f76657279206c696d69740060448201526064016107c3565b827fbdbd8667b6c12f94c5a90a10097bfa133de72220146fefc2f5ff04b86cc6ae1a8260405161141491815260200190565b61167461179b565b6001600160a01b0381166116d95760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016107c3565b610b2c81611d71565b6116ea61179b565b600b80546001600160a01b0319166001600160a01b0383169081179091556040517f68f10ceb42d30acc930aaaedf5b94559e14fc4f22496dc2c1b38b1b1b5231f9890600090a250565b61174487338888888888886121fa565b60405186815233906001600160a01b038916907f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259060200160405180910390a3611790873360006117ef565b6110bf8733886119e4565b6117a3611914565b610da05760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107c3565b6001600160a01b0383166118515760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b60648201526084016107c3565b6001600160a01b0382166118b25760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b60648201526084016107c3565b6001600160a01b0383811660008181526002602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b600061191e612365565b8061094357507fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035433905b6001600160a01b031614905090565b6001600160a01b038084166000908152600260209081526040808320938616835292905220546000198114610a5057818110156119d75760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e636500000060448201526064016107c3565b610a5084848484036117ef565b6001600160a01b038316611a485760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b60648201526084016107c3565b6001600160a01b038216611aaa5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b60648201526084016107c3565b611ab48382612379565b611abe828261244c565b816001600160a01b0316836001600160a01b0316600080516020612fab8339815191528360405161190791815260200190565b6000306001600160a01b037f000000000000000000000000b0b195aefa3650a6908f15cdac7d92f8a5791b0b16148015611b4a57507f000000000000000000000000000000000000000000000000000000000000000146145b15611b7457507f89ae8e5c4b66ead9633eda9b816caf7be1b63c83da93250c795d803856f7c58890565b50604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f6020808301919091527f29d93e4f9fb5004362e31d9828e4c67c1125ce4f9a86862014fd68039a2e4c38828401527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc660608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b6001600160a01b038216611c6e5760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016107c3565b8060036000828254611c809190612c7f565b90915550611c909050828261244c565b6040518181526001600160a01b03831690600090600080516020612fab833981519152906020015b60405180910390a35050565b6001600160a01b038216611d245760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b60648201526084016107c3565b611d2e8282612379565b8060036000828254611d409190612f0c565b90915550506040518181526000906001600160a01b03841690600080516020612fab83398151915290602001611cb8565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6007546000906001600160a01b0316611dda5750600090565b600754600354600091670de0b6b3a764000091611e0891600160a01b900467ffffffffffffffff1690612f23565b611e129190612f42565b9050600854811115611e3157600854611e2b9082612f0c565b91505090565b600091505090565b83421115611e895760405162461bcd60e51b815260206004820152601b60248201527f45524332305065726d69743a2065787069726564207065726d6974000000000060448201526064016107c3565b6001600160a01b038716600090815260046020526040812080549082611eae83612dae565b9190505590506000611f6a611ec1611af1565b604080517f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c960208201526001600160a01b03808e1692820192909252908b166060820152608081018a905260a0810185905260c0810189905260e0015b60408051601f19818403018152828252805160209182012061190160f01b8483015260228401949094526042808401949094528151808403909401845260629092019052815191012090565b9050611f78818686866124cf565b6001600160a01b0316896001600160a01b031614611fe75760405162461bcd60e51b815260206004820152602660248201527f45524332305065726d69743a20696e76616c69642045524332363132207369676044820152656e617475726560d01b60648201526084016107c3565b505050505050505050565b60075460009081906001600160a01b0316815b8681101561213557600061202489898481811061129857611298612d98565b9050600087878481811061203a5761203a612d98565b9050602002013582106120655787878481811061205957612059612d98565b90506020020135612067565b815b90506120738186612c7f565b94506120bf8a8a8581811061208a5761208a612d98565b905060200201602081019061209f91906127ac565b6001600160a01b0316600090815260016020526040902080548390039055565b836001600160a01b03168a8a858181106120db576120db612d98565b90506020020160208101906120f091906127ac565b6001600160a01b0316600080516020612fab8339815191528360405161211891815260200190565b60405180910390a35050808061212d90612dae565b915050612005565b50612140818361244c565b81600860008282546121529190612c7f565b90915550506001600160a01b0381163b156121f05760408051600081526020810191829052635260769b60e11b9091526001600160a01b0382169063a4c0ed36906121a4903090869060248101612f64565b6020604051808303816000875af11580156121c3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906121e79190612cdf565b6121f057600080fd5b5095945050505050565b8442111561224a5760405162461bcd60e51b815260206004820152601b60248201527f45524332305065726d69743a2065787069726564207065726d6974000000000060448201526064016107c3565b6001600160a01b03881660009081526004602052604081208054908261226f83612dae565b91905055905060006122eb612282611af1565b604080517f4bcf1917b4c6060d0cfc29abba53999d42824efa953155f8c376edb9e22cad8c60208201526001600160a01b03808f1692820192909252908c166060820152608081018b905260a0810185905260c081018a905260e0810189905261010001611f1e565b90506122f9818686866124cf565b6001600160a01b03168a6001600160a01b0316146123595760405162461bcd60e51b815260206004820152601e60248201527f45524332305065726d69743a20696e76616c6964207369676e6174757265000060448201526064016107c3565b50505050505050505050565b6000805433906001600160a01b0316611949565b6001600160a01b038216600090815260016020526040902054600160ff1b81106123dd5760405162461bcd60e51b815260206004820152601560248201527422a92199181d1030b1b1b7bab73a10333937bd32b760591b60448201526064016107c3565b8181101561242d5760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20616d6f756e7420657863656564732062616c616e636500000060448201526064016107c3565b6001600160a01b03909216600090815260016020526040902091039055565b6001600160a01b038216600090815260016020526040902054600160ff1b81106124b05760405162461bcd60e51b815260206004820152601560248201527422a92199181d1030b1b1b7bab73a10333937bd32b760591b60448201526064016107c3565b6001600160a01b03909216600090815260016020526040902091019055565b60008060006124e0878787876124ed565b915091506121f0816125da565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a083111561252457506000905060036125d1565b8460ff16601b1415801561253c57508460ff16601c14155b1561254d57506000905060046125d1565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa1580156125a1573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381166125ca576000600192509250506125d1565b9150600090505b94509492505050565b60008160048111156125ee576125ee612f94565b036125f65750565b600181600481111561260a5761260a612f94565b036126575760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e6174757265000000000000000060448201526064016107c3565b600281600481111561266b5761266b612f94565b036126b85760405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e6774680060448201526064016107c3565b60038160048111156126cc576126cc612f94565b036127245760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c604482015261756560f01b60648201526084016107c3565b600481600481111561273857612738612f94565b03610b2c5760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202776272076616c604482015261756560f01b60648201526084016107c3565b80356001600160a01b03811681146127a757600080fd5b919050565b6000602082840312156127be57600080fd5b6127c782612790565b9392505050565b6000815180845260005b818110156127f4576020818501810151868301820152016127d8565b81811115612806576000602083870101525b50601f01601f19169290920160200192915050565b6020815260006127c760208301846127ce565b6000806040838503121561284157600080fd5b61284a83612790565b946020939093013593505050565b60006020828403121561286a57600080fd5b813563ffffffff811681146127c757600080fd5b60008060006060848603121561289357600080fd5b61289c84612790565b92506128aa60208501612790565b9150604084013590509250925092565b600080600080606085870312156128d057600080fd5b6128d985612790565b935060208501359250604085013567ffffffffffffffff808211156128fd57600080fd5b818701915087601f83011261291157600080fd5b81358181111561292057600080fd5b88602082850101111561293257600080fd5b95989497505060200194505050565b60006020828403121561295357600080fd5b5035919050565b6000806040838503121561296d57600080fd5b61297683612790565b915061298460208401612790565b90509250929050565b803560ff811681146127a757600080fd5b60008060008060008060c087890312156129b757600080fd5b6129c087612790565b955060208701359450604087013593506129dc6060880161298d565b92506080870135915060a087013590509295509295509295565b8015158114610b2c57600080fd5b600080600060608486031215612a1957600080fd5b612a2284612790565b92506020840135612a32816129f6565b91506040840135612a42816129f6565b809150509250925092565b600060208284031215612a5f57600080fd5b813567ffffffffffffffff811681146127c757600080fd5b600080600080600080600060e0888a031215612a9257600080fd5b612a9b88612790565b9650612aa960208901612790565b95506040880135945060608801359350612ac56080890161298d565b925060a0880135915060c0880135905092959891949750929550565b60008083601f840112612af357600080fd5b50813567ffffffffffffffff811115612b0b57600080fd5b6020830191508360208260051b8501011115612b2657600080fd5b9250929050565b60008060008060408587031215612b4357600080fd5b843567ffffffffffffffff80821115612b5b57600080fd5b612b6788838901612ae1565b90965094506020870135915080821115612b8057600080fd5b50612b8d87828801612ae1565b95989497509550505050565b600080600080600080600060e0888a031215612bb457600080fd5b612bbd88612790565b9650602088013595506040880135945060608801359350612ac56080890161298d565b60208082526025908201527f5265636f766572793a206e6f7420617574686f72697a656420666f72207265636040820152646f7665727960d81b606082015260800190565b60208082526024908201527f5265636f766572793a206e6f20616374697665207265636f76657279207265716040820152631d595cdd60e21b606082015260800190565b634e487b7160e01b600052601160045260246000fd5b60008219821115612c9257612c92612c69565b500190565b6001600160a01b0385168152602081018490526060604082018190528101829052818360808301376000818301608090810191909152601f909201601f191601019392505050565b600060208284031215612cf157600080fd5b81516127c7816129f6565b60208082526028908201527f426c6f636b6c6973743a2063616c6c6572206973206e6f742074686520626c6f60408201526731b5b634b9ba32b960c11b606082015260800190565b600060208284031215612d5657600080fd5b5051919050565b600060ff821660ff84168060ff03821115612d7a57612d7a612c69565b019392505050565b634e487b7160e01b600052604160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b600060018201612dc057612dc0612c69565b5060010190565b8183526000602080850194508260005b85811015612e03576001600160a01b03612df083612790565b1687529582019590820190600101612dd7565b509495945050505050565b600081518084526020808501945080840160005b83811015612e0357815187529582019590820190600101612e22565b848152606060208201526000612e58606083018587612dc7565b8281036040840152612e6a8185612e0e565b979650505050505050565b858152846020820152608060408201526000612e95608083018587612dc7565b8281036060840152612ea78185612e0e565b98975050505050505050565b858152606060208201526000612ecd606083018688612dc7565b82810360408401528381526001600160fb1b03841115612eec57600080fd5b8360051b8086602084013760009101602001908152979650505050505050565b600082821015612f1e57612f1e612c69565b500390565b6000816000190483118215151615612f3d57612f3d612c69565b500290565b600082612f5f57634e487b7160e01b600052601260045260246000fd5b500490565b60018060a01b0384168152826020820152606060408201526000612f8b60608301846127ce565b95945050505050565b634e487b7160e01b600052602160045260246000fdfeddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220e9729829fb1fe0e31764ab359a615f2d8608bd49786757d008d625840589cad764736f6c634300080f0033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000b0b195aefa3650a6908f15cdac7d92f8a5791b0b
-----Decoded View---------------
Arg [0] : _self (address): 0xB0B195aEFA3650A6908f15CdaC7D92F8a5791B0B
-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 000000000000000000000000b0b195aefa3650a6908f15cdac7d92f8a5791b0b
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 34 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.