Token Vicinity
Polygon Sponsored slots available. Book your slot here!
Overview ERC-20
Price
$0.00 @ 0.000000 MATIC
Fully Diluted Market Cap
Total Supply:
10,000,000 VCNT
Holders:
116 addresses
Transfers:
-
Contract:
Decimals:
18
[ Download CSV Export ]
[ Download CSV Export ]
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Name:
Vicinity
Compiler Version
v0.8.10+commit.fc410830
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "AccessControlEnumerable.sol"; import "Ownable.sol"; import "Pausable.sol"; import "ERC20.sol"; import "SafeMath.sol"; abstract contract VicinityAccess is Ownable, AccessControlEnumerable { bytes32 internal constant MINTER_ROLE_NAME = "minter"; bytes32 internal constant AIRDROP_ROLE_NAME = "airdrop"; constructor() { _setupRole(DEFAULT_ADMIN_ROLE, msg.sender); } modifier onlyOwnerOrRole(bytes32 role) { if (msg.sender != owner()) { _checkRole(role, msg.sender); } _; } /** * This will throw an exception. You MUST NOT renounce ownership. * You can only transfer to another address. */ function renounceOwnership() public override onlyOwner { revert("You MUST NOT renounce ownership. You can only transfer to another address."); } /** * Make another account the owner of this contract. * @param newOwner the new owner. * * Requirements: * * - Calling user MUST be owner. */ function transferOwnership(address newOwner) public virtual override onlyOwner { grantRole(DEFAULT_ADMIN_ROLE, newOwner); super.transferOwnership(newOwner); } /** * Take the role away from the account. This will throw an exception * if you try to take the admin role (0x00) away from the owner. * * Requirements: * * - Calling user has admin role. * - If `role` is admin, `address` MUST NOT be owner. */ function revokeRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) { require( role != DEFAULT_ADMIN_ROLE || account != owner(), "You MUST NOT revoke admin from the contract owner." ); super.revokeRole(role, account); } /** * Take a role away from yourself. This will throw an exception if you * are the contract owner and you are trying to renounce the admin role (0x00). * * Requirements: * * - if `role` is admin, calling user MUST NOT be owner. * - `account` MUST be the same as the calling user. */ function renounceRole(bytes32 role, address account) public virtual override { require( role != DEFAULT_ADMIN_ROLE || account != owner(), "The contract owner MUST NOT renounce admin." ); super.renounceRole(role, msg.sender); } } /** * A community token for charity NFT auctions. */ contract Vicinity is ERC20, VicinityAccess, Pausable { using SafeMath for uint256; uint256 public airdropcount = 0; mapping (address => uint256) private time; mapping (address => uint256) private _lockedAmount; mapping (address => bool) public isBlackListed; event DestroyedBlackFunds(address _blackListedUser, uint _balance); event AddedBlackList(address _user); event RemovedBlackList(address _user); /** * @dev Deploy the new token contract. * @param name the name of the token. * @param symbol the token symbol. * @param initialSupply the initial supply of tokens, in wei. */ constructor( string memory name, string memory symbol, uint256 initialSupply ) ERC20(name, symbol) { if (initialSupply > 0) { _mint(msg.sender, initialSupply); } } /** * @dev time calculator for locked tokens */ function addLockingTime(address lockingAddress,uint256 lockingTime, uint256 amount) internal returns (bool){ time[lockingAddress] = block.timestamp + (lockingTime * 1 days); _lockedAmount[lockingAddress] = _lockedAmount[lockingAddress].add(amount); return true; } /** * @dev check for time based lock * @param _address address to check for locking time * @return time in block format */ function checkLockingTimeByAddress(address _address) public view returns(uint256){ return time[_address]; } /** * @dev get amount of locked tokens by address * @param _address address to check for locking amount * @return amount in wei */ function checkLockingAmountByAddress(address _address) external view returns(uint256){ if (block.timestamp < time[_address]){ return _lockedAmount[_address]; } else{ return 0; } } /** * @dev return locking status * @param userAddress address of to check * @return locking status in true or false */ function getLockingStatus(address userAddress) public view returns(bool){ return ( block.timestamp < time[userAddress] && _lockedAmount[userAddress] > 0 ); } /** * @dev Decrease locking time for an account. * @param _affectiveAddress Address of the locked address * @param _decreasedTime Time in days to be affected * * Requirements: * * - Contract MUST NOT be paused * - Calling user MUST be owner or have the minter role. * - The `decreasedTime` MAY cause the locked time to be in the past. */ function decreaseLockingTimeByAddress(address _affectiveAddress, uint _decreasedTime) external whenNotPaused onlyOwnerOrRole(MINTER_ROLE_NAME) returns(bool){ require( _decreasedTime > 0 && time[_affectiveAddress] > block.timestamp, "Please check address status or Incorrect input" ); time[_affectiveAddress] = time[_affectiveAddress] - (_decreasedTime * 1 days); return true; } /** * @dev Increase locking time for an account. * @param _affectiveAddress Address of the locked address * @param _increasedTime Time in days to be affected * * Requirements: * * - Contract MUST NOT be paused * - Calling user MUST be owner or have the minter role. */ function increaseLockingTimeByAddress(address _affectiveAddress, uint _increasedTime) external whenNotPaused onlyOwnerOrRole(MINTER_ROLE_NAME) returns(bool){ require( _increasedTime > 0 && time[_affectiveAddress] > block.timestamp, "Please check address status or Incorrect input" ); time[_affectiveAddress] = time[_affectiveAddress] + (_increasedTime * 1 days); return true; } modifier checkLocking(address _address,uint256 requestedAmount){ if(block.timestamp < time[_address]){ require( !( balanceOf(_address).sub(_lockedAmount[_address]) < requestedAmount), "Insufficient unlocked balance" ); } _; } /* ---------------------------------------------------------------------------- * Transfer, allow, mint and burn functions * ---------------------------------------------------------------------------- */ /** * @dev Mint some coins. * @param account The account to receive the newly minted coins. * @param amount The number of coins to mint, in wei. * * Requirements: * * - Contract MUST NOT be paused. * = Calling user MUST be owner or have the minter role. */ function mint(address account, uint256 amount) public whenNotPaused onlyOwnerOrRole(MINTER_ROLE_NAME) { super._mint(account, amount); } /** * @dev Burns a specific amount of tokens from the calling user's account. * @param amount The amount of token to be burned, in wei. * * Requirements: * * - Contract MUST NOT be paused. * = Calling user MUST be owner or have the minter role. * - `amount` MUST NOT exceed the calling user's account balance. */ function burn(uint256 amount) public whenNotPaused onlyOwnerOrRole(MINTER_ROLE_NAME) { _burn(msg.sender, amount); } /** * @dev Transfer token to a specified address. * @param to The address to transfer to. * @param value The amount to be transferred, in wei. * * Requirements: * * - Contract MUST NOT be paused. * - `to` MUST NOT be the zero address. * - `to` and Calling user MUST NOT be blacklisted users. * - `amount` MUST NOT exceed the calling user's account balance. */ function transfer(address to, uint256 value) public whenNotPaused checkLocking(msg.sender,value) override returns (bool) { require(!isBlackListed[msg.sender] && !isBlackListed[to]); _transfer(msg.sender, to, value); return true; } /** * @dev See {IERC20-approve}. * * Requirements: * * - Contract MUST NOT be paused. * - `spender` MUST NOT be the zero address. * - `to` and Calling user MUST NOT be blacklisted users. * - `amount` MAY exceed calling user's balance. */ function approve(address spender, uint256 amount) public virtual override whenNotPaused returns (bool) { require(!isBlackListed[msg.sender] && !isBlackListed[spender]); return super.approve(spender, amount); } /** * @dev Transfer tokens from one address to another. * Note that while this function emits an Approval event, this is not required as per the specification, * and other compliant implementations may not emit the event. * @param from address The address which you want to send tokens from * @param to address The address which you want to transfer to * @param value uint256 the amount of tokens to be transferred, in wei * * Requirements: * * - Contract MUST NOT be paused. * - `from` and `to` MUST NOT be the zero address. * - `to`, `from`, and calling user MUST NOT be blacklisted users. * - `value` MUST NOT exceed the balance of `from`. * - `value` MUST NOT exceed the allowance granted to calling user by `from`. */ function transferFrom(address from, address to, uint256 value) public whenNotPaused checkLocking(from, value) override returns (bool) { require(!isBlackListed[msg.sender] && !isBlackListed[from] && !isBlackListed[to]); return super.transferFrom(from, to, value); } /** * @dev Atomically increases the allowance granted to `spender` by the caller. * * This is an alternative to {approve} that can be used as a mitigation for * problems described in {IERC20-approve}. * * Emits an {Approval} event indicating the updated allowance. * * Requirements: * * - Contract MUST NOT be paused. * - `spender` MUST NOT be the zero address. * - Calling user and `spender` MUST NOT be blacklisted users. */ function increaseAllowance(address spender, uint256 addedValue) public virtual override whenNotPaused returns (bool) { require(!isBlackListed[msg.sender] && !isBlackListed[spender]); return super.increaseAllowance(spender, addedValue); } /** * @dev Atomically decreases the allowance granted to `spender` by the caller. * * This is an alternative to {approve} that can be used as a mitigation for * problems described in {IERC20-approve}. * * Emits an {Approval} event indicating the updated allowance. * * Requirements: * * - Contract MUST NOT be paused. * - `spender` MUST NOT be the zero address. * - `spender` MUST have allowance for the caller of at least * `subtractedValue`. * - Calling user and `spender` MUST NOT be blacklisted users. */ function decreaseAllowance(address spender, uint256 subtractedValue) public virtual override whenNotPaused returns (bool) { require(!isBlackListed[msg.sender] && !isBlackListed[spender]); return super.decreaseAllowance(spender, subtractedValue); } /** * @dev Transfer tokens to a specified address (For Only Owner or Minter). * @param to The address to transfer to. * @param value The amount to be transferred, in wei. * @param lockingTime locking period in days, applied to the recipient. * @return Transfer status in true or false * * Requirements: * * - Contract MUST NOT be paused. * - Calling user MUST be owner or have the minter role. * - `to` MUST NOT be the zero address. * - `value` MUST NOT exceed the balance of `to`. */ function transferLockedTokens(address to, uint256 value, uint8 lockingTime) public whenNotPaused onlyOwnerOrRole(MINTER_ROLE_NAME) returns (bool) { addLockingTime(to,lockingTime,value); _transfer(msg.sender, to, value); return true; } /** * @dev Transfer and unlock tokens. (For Only Owner or Minter). * If from and to address are the same, this will unlock the tokens for the user. * @param from locked address * @param to address to be transfer tokens * @param value amount of tokens to unlock and transfer, in wei * @return transfer status * * Requirements: * * - Contract MUST NOT be paused. * - Calling user MUST be owner or have the minter role. * - `from` and `to` MUST NOT be the zero address. * - `value` MUST NOT exceed the balance or locked balance of `to`. */ function GetBackLockedTokens(address from, address to, uint256 value) external whenNotPaused onlyOwnerOrRole(MINTER_ROLE_NAME) returns (bool){ require( (_lockedAmount[from] >= value) && (block.timestamp < time[from]), "Insufficient locked balance" ); _lockedAmount[from] = _lockedAmount[from].sub(value); if (from != to) { _transfer(from,to,value); } return true; } /** * @dev Airdrop function to airdrop tokens. Best works upto 50 addresses in one time. * Maximum limit is 200 addresses in one time. * @param _addresses array of address in serial order * @param _amount amount in serial order with respect to address array, in wei * * Requirements: * * - Contract MUST NOT be paused. * - Calling user MUST be owner or have the airdropper role. * - The length of `_addresses` MUST equal the length `_amount`. * - `_addresses` MUST NOT contain the zero address. * - the sum of `_amount` MUST NOT exceed the calling user's balance. */ function airdropByOwner(address[] memory _addresses, uint256[] memory _amount) public whenNotPaused onlyOwnerOrRole(AIRDROP_ROLE_NAME) returns (bool){ require( _addresses.length == _amount.length, "Invalid Array" ); uint256 count = _addresses.length; for (uint256 i = 0; i < count; i++){ _transfer(msg.sender, _addresses[i], _amount[i]); airdropcount = airdropcount + 1; } return true; } /** * @dev Locked Airdrop function to airdrop tokens. Best works upto 50 addresses in one time. Maximum limit is 200 addresses in one time. * @param _addresses array of address in serial order * @param _amount amount in serial order with respect to address array, in wei * @param _lockedTime the number of days to lock the airdrop. * * Requirements: * * - Contract MUST NOT be paused. * - Calling user MUST be owner or have the airdropper role. * - The lengths of `_addresses`, `_amount`, and `_lockedTime` MUST all be equal. * - `_addresses` MUST NOT contain the zero address. * - the sum of `_amount` MUST NOT exceed the calling user's balance. */ function lockedAirdropByOwner( address[] memory _addresses, uint256[] memory _amount,uint8[] memory _lockedTime ) public whenNotPaused onlyOwnerOrRole(AIRDROP_ROLE_NAME) returns (bool){ require( _addresses.length == _amount.length, "Invalid amounts Array" ); require( _addresses.length == _lockedTime.length, "Invalid lockedTime Array" ); uint256 count = _addresses.length; for (uint256 i = 0; i < count; i++){ addLockingTime(_addresses[i],_lockedTime[i],_amount[i]); _transfer(msg.sender, _addresses[i], _amount[i]); airdropcount = airdropcount + 1; } return true; } /** * Prevent the account from being used. * @param _evilUser the account to be blacklisted * * Requirements: * * - Calling user MUST be owner. */ function addBlackList (address _evilUser) public onlyOwner { isBlackListed[_evilUser] = true; emit AddedBlackList(_evilUser); } /** * Reinstate a blacklisted account. * @param _clearedUser the account to be reinstated * * Requirements: * * - Calling user MUST be owner. */ function removeBlackList (address _clearedUser) public onlyOwner { isBlackListed[_clearedUser] = false; emit RemovedBlackList(_clearedUser); } /** * Burn the tokens held in the blacklisted account * @param _blackListedUser the blacklisted account * * Requirements: * * - Calling user MUST be owner. * - `_blackListedUser` must be a blacklisted user. */ function destroyBlackFunds (address _blackListedUser) public onlyOwner { require(isBlackListed[_blackListedUser]); uint dirtyFunds = balanceOf(_blackListedUser); _burn(_blackListedUser, dirtyFunds); emit DestroyedBlackFunds(_blackListedUser, dirtyFunds); } /** * @dev Triggers stopped state. * * Requirements: * * - Calling user MUST be owner. * - The contract must not be paused. */ function pause() external onlyOwner { _pause(); } /** * @dev Returns to normal state. * * Requirements: * * - Calling user MUST be owner. * - The contract must be paused. */ function unpause() external onlyOwner { _unpause(); } function withdrawn(address payable _to) public onlyOwner returns(bool){ _transfer(address(this), _to, balanceOf(address(this))); return true; } function withdrawnTokens(uint256 _amount, address _to, address _tokenContract) public onlyOwner returns(bool){ IERC20 tokenContract = IERC20(_tokenContract); tokenContract.transfer(_to, _amount); return true; } receive() external payable {} }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "IAccessControlEnumerable.sol"; import "AccessControl.sol"; import "EnumerableSet.sol"; /** * @dev Extension of {AccessControl} that allows enumerating the members of each role. */ abstract contract AccessControlEnumerable is IAccessControlEnumerable, AccessControl { using EnumerableSet for EnumerableSet.AddressSet; mapping(bytes32 => EnumerableSet.AddressSet) private _roleMembers; /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IAccessControlEnumerable).interfaceId || super.supportsInterface(interfaceId); } /** * @dev Returns one of the accounts that have `role`. `index` must be a * value between 0 and {getRoleMemberCount}, non-inclusive. * * Role bearers are not sorted in any particular way, and their ordering may * change at any point. * * WARNING: When using {getRoleMember} and {getRoleMemberCount}, make sure * you perform all queries on the same block. See the following * https://forum.openzeppelin.com/t/iterating-over-elements-on-enumerableset-in-openzeppelin-contracts/2296[forum post] * for more information. */ function getRoleMember(bytes32 role, uint256 index) public view override returns (address) { return _roleMembers[role].at(index); } /** * @dev Returns the number of accounts that have `role`. Can be used * together with {getRoleMember} to enumerate all bearers of a role. */ function getRoleMemberCount(bytes32 role) public view override returns (uint256) { return _roleMembers[role].length(); } /** * @dev Overload {grantRole} to track enumerable memberships */ function grantRole(bytes32 role, address account) public virtual override(AccessControl, IAccessControl) { super.grantRole(role, account); _roleMembers[role].add(account); } /** * @dev Overload {revokeRole} to track enumerable memberships */ function revokeRole(bytes32 role, address account) public virtual override(AccessControl, IAccessControl) { super.revokeRole(role, account); _roleMembers[role].remove(account); } /** * @dev Overload {renounceRole} to track enumerable memberships */ function renounceRole(bytes32 role, address account) public virtual override(AccessControl, IAccessControl) { super.renounceRole(role, account); _roleMembers[role].remove(account); } /** * @dev Overload {_setupRole} to track enumerable memberships */ function _setupRole(bytes32 role, address account) internal virtual override { super._setupRole(role, account); _roleMembers[role].add(account); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "IAccessControl.sol"; /** * @dev External interface of AccessControlEnumerable declared to support ERC165 detection. */ interface IAccessControlEnumerable is IAccessControl { /** * @dev Returns one of the accounts that have `role`. `index` must be a * value between 0 and {getRoleMemberCount}, non-inclusive. * * Role bearers are not sorted in any particular way, and their ordering may * change at any point. * * WARNING: When using {getRoleMember} and {getRoleMemberCount}, make sure * you perform all queries on the same block. See the following * https://forum.openzeppelin.com/t/iterating-over-elements-on-enumerableset-in-openzeppelin-contracts/2296[forum post] * for more information. */ function getRoleMember(bytes32 role, uint256 index) external view returns (address); /** * @dev Returns the number of accounts that have `role`. Can be used * together with {getRoleMember} to enumerate all bearers of a role. */ function getRoleMemberCount(bytes32 role) external view returns (uint256); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev External interface of AccessControl declared to support ERC165 detection. */ interface IAccessControl { /** * @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole` * * `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite * {RoleAdminChanged} not being emitted signaling this. * * _Available since v3.1._ */ event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole); /** * @dev Emitted when `account` is granted `role`. * * `sender` is the account that originated the contract call, an admin role * bearer except when using {AccessControl-_setupRole}. */ event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender); /** * @dev Emitted when `account` is revoked `role`. * * `sender` is the account that originated the contract call: * - if using `revokeRole`, it is the admin role bearer * - if using `renounceRole`, it is the role bearer (i.e. `account`) */ event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender); /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) external view returns (bool); /** * @dev Returns the admin role that controls `role`. See {grantRole} and * {revokeRole}. * * To change a role's admin, use {AccessControl-_setRoleAdmin}. */ function getRoleAdmin(bytes32 role) external view returns (bytes32); /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function grantRole(bytes32 role, address account) external; /** * @dev Revokes `role` from `account`. * * If `account` had been granted `role`, emits a {RoleRevoked} event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function revokeRole(bytes32 role, address account) external; /** * @dev Revokes `role` from the calling account. * * Roles are often managed via {grantRole} and {revokeRole}: this function's * purpose is to provide a mechanism for accounts to lose their privileges * if they are compromised (such as when a trusted device is misplaced). * * If the calling account had been granted `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `account`. */ function renounceRole(bytes32 role, address account) external; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "IAccessControl.sol"; import "Context.sol"; import "Strings.sol"; import "ERC165.sol"; /** * @dev Contract module that allows children to implement role-based access * control mechanisms. This is a lightweight version that doesn't allow enumerating role * members except through off-chain means by accessing the contract event logs. Some * applications may benefit from on-chain enumerability, for those cases see * {AccessControlEnumerable}. * * Roles are referred to by their `bytes32` identifier. These should be exposed * in the external API and be unique. The best way to achieve this is by * using `public constant` hash digests: * * ``` * bytes32 public constant MY_ROLE = keccak256("MY_ROLE"); * ``` * * Roles can be used to represent a set of permissions. To restrict access to a * function call, use {hasRole}: * * ``` * function foo() public { * require(hasRole(MY_ROLE, msg.sender)); * ... * } * ``` * * Roles can be granted and revoked dynamically via the {grantRole} and * {revokeRole} functions. Each role has an associated admin role, and only * accounts that have a role's admin role can call {grantRole} and {revokeRole}. * * By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means * that only accounts with this role will be able to grant or revoke other * roles. More complex role relationships can be created by using * {_setRoleAdmin}. * * WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to * grant and revoke this role. Extra precautions should be taken to secure * accounts that have been granted it. */ abstract contract AccessControl is Context, IAccessControl, ERC165 { struct RoleData { mapping(address => bool) members; bytes32 adminRole; } mapping(bytes32 => RoleData) private _roles; bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00; /** * @dev Modifier that checks that an account has a specific role. Reverts * with a standardized message including the required role. * * The format of the revert reason is given by the following regular expression: * * /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/ * * _Available since v4.1._ */ modifier onlyRole(bytes32 role) { _checkRole(role, _msgSender()); _; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IAccessControl).interfaceId || super.supportsInterface(interfaceId); } /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) public view override returns (bool) { return _roles[role].members[account]; } /** * @dev Revert with a standard message if `account` is missing `role`. * * The format of the revert reason is given by the following regular expression: * * /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/ */ function _checkRole(bytes32 role, address account) internal view { if (!hasRole(role, account)) { revert( string( abi.encodePacked( "AccessControl: account ", Strings.toHexString(uint160(account), 20), " is missing role ", Strings.toHexString(uint256(role), 32) ) ) ); } } /** * @dev Returns the admin role that controls `role`. See {grantRole} and * {revokeRole}. * * To change a role's admin, use {_setRoleAdmin}. */ function getRoleAdmin(bytes32 role) public view override returns (bytes32) { return _roles[role].adminRole; } /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function grantRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) { _grantRole(role, account); } /** * @dev Revokes `role` from `account`. * * If `account` had been granted `role`, emits a {RoleRevoked} event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function revokeRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) { _revokeRole(role, account); } /** * @dev Revokes `role` from the calling account. * * Roles are often managed via {grantRole} and {revokeRole}: this function's * purpose is to provide a mechanism for accounts to lose their privileges * if they are compromised (such as when a trusted device is misplaced). * * If the calling account had been granted `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `account`. */ function renounceRole(bytes32 role, address account) public virtual override { require(account == _msgSender(), "AccessControl: can only renounce roles for self"); _revokeRole(role, account); } /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. Note that unlike {grantRole}, this function doesn't perform any * checks on the calling account. * * [WARNING] * ==== * This function should only be called from the constructor when setting * up the initial roles for the system. * * Using this function in any other way is effectively circumventing the admin * system imposed by {AccessControl}. * ==== */ function _setupRole(bytes32 role, address account) internal virtual { _grantRole(role, account); } /** * @dev Sets `adminRole` as ``role``'s admin role. * * Emits a {RoleAdminChanged} event. */ function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual { bytes32 previousAdminRole = getRoleAdmin(role); _roles[role].adminRole = adminRole; emit RoleAdminChanged(role, previousAdminRole, adminRole); } function _grantRole(bytes32 role, address account) private { if (!hasRole(role, account)) { _roles[role].members[account] = true; emit RoleGranted(role, account, _msgSender()); } } function _revokeRole(bytes32 role, address account) private { if (hasRole(role, account)) { _roles[role].members[account] = false; emit RoleRevoked(role, account, _msgSender()); } } }
// SPDX-License-Identifier: MIT 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 pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "IERC165.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` * * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation. */ abstract contract ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165 { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Library for managing * https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive * types. * * Sets have the following properties: * * - Elements are added, removed, and checked for existence in constant time * (O(1)). * - Elements are enumerated in O(n). No guarantees are made on the ordering. * * ``` * contract Example { * // Add the library methods * using EnumerableSet for EnumerableSet.AddressSet; * * // Declare a set state variable * EnumerableSet.AddressSet private mySet; * } * ``` * * As of v3.3.0, sets of type `bytes32` (`Bytes32Set`), `address` (`AddressSet`) * and `uint256` (`UintSet`) are supported. */ library EnumerableSet { // To implement this library for multiple types with as little code // repetition as possible, we write it in terms of a generic Set type with // bytes32 values. // The Set implementation uses private functions, and user-facing // implementations (such as AddressSet) are just wrappers around the // underlying Set. // This means that we can only create new EnumerableSets for types that fit // in bytes32. struct Set { // Storage of set values bytes32[] _values; // Position of the value in the `values` array, plus 1 because index 0 // means a value is not in the set. mapping(bytes32 => uint256) _indexes; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function _add(Set storage set, bytes32 value) private returns (bool) { if (!_contains(set, value)) { set._values.push(value); // The value is stored at length-1, but we add 1 to all indexes // and use 0 as a sentinel value set._indexes[value] = set._values.length; return true; } else { return false; } } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function _remove(Set storage set, bytes32 value) private returns (bool) { // We read and store the value's index to prevent multiple reads from the same storage slot uint256 valueIndex = set._indexes[value]; if (valueIndex != 0) { // Equivalent to contains(set, value) // To delete an element from the _values array in O(1), we swap the element to delete with the last one in // the array, and then remove the last element (sometimes called as 'swap and pop'). // This modifies the order of the array, as noted in {at}. uint256 toDeleteIndex = valueIndex - 1; uint256 lastIndex = set._values.length - 1; if (lastIndex != toDeleteIndex) { bytes32 lastvalue = set._values[lastIndex]; // Move the last value to the index where the value to delete is set._values[toDeleteIndex] = lastvalue; // Update the index for the moved value set._indexes[lastvalue] = valueIndex; // Replace lastvalue's index to valueIndex } // Delete the slot where the moved value was stored set._values.pop(); // Delete the index for the deleted slot delete set._indexes[value]; return true; } else { return false; } } /** * @dev Returns true if the value is in the set. O(1). */ function _contains(Set storage set, bytes32 value) private view returns (bool) { return set._indexes[value] != 0; } /** * @dev Returns the number of values on the set. O(1). */ function _length(Set storage set) private view returns (uint256) { return set._values.length; } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function _at(Set storage set, uint256 index) private view returns (bytes32) { return set._values[index]; } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function _values(Set storage set) private view returns (bytes32[] memory) { return set._values; } // Bytes32Set struct Bytes32Set { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(Bytes32Set storage set, bytes32 value) internal returns (bool) { return _add(set._inner, value); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(Bytes32Set storage set, bytes32 value) internal returns (bool) { return _remove(set._inner, value); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(Bytes32Set storage set, bytes32 value) internal view returns (bool) { return _contains(set._inner, value); } /** * @dev Returns the number of values in the set. O(1). */ function length(Bytes32Set storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(Bytes32Set storage set, uint256 index) internal view returns (bytes32) { return _at(set._inner, index); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(Bytes32Set storage set) internal view returns (bytes32[] memory) { return _values(set._inner); } // AddressSet struct AddressSet { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(AddressSet storage set, address value) internal returns (bool) { return _add(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(AddressSet storage set, address value) internal returns (bool) { return _remove(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(AddressSet storage set, address value) internal view returns (bool) { return _contains(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Returns the number of values in the set. O(1). */ function length(AddressSet storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(AddressSet storage set, uint256 index) internal view returns (address) { return address(uint160(uint256(_at(set._inner, index)))); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(AddressSet storage set) internal view returns (address[] memory) { bytes32[] memory store = _values(set._inner); address[] memory result; assembly { result := store } return result; } // UintSet struct UintSet { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(UintSet storage set, uint256 value) internal returns (bool) { return _add(set._inner, bytes32(value)); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(UintSet storage set, uint256 value) internal returns (bool) { return _remove(set._inner, bytes32(value)); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(UintSet storage set, uint256 value) internal view returns (bool) { return _contains(set._inner, bytes32(value)); } /** * @dev Returns the number of values on the set. O(1). */ function length(UintSet storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(UintSet storage set, uint256 index) internal view returns (uint256) { return uint256(_at(set._inner, index)); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(UintSet storage set) internal view returns (uint256[] memory) { bytes32[] memory store = _values(set._inner); uint256[] memory result; assembly { result := store } return result; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "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() { _setOwner(_msgSender()); } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { require(owner() == _msgSender(), "Ownable: caller is not the owner"); _; } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _setOwner(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"); _setOwner(newOwner); } function _setOwner(address newOwner) private { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "Context.sol"; /** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your contract. Note that they will not be pausable by * simply including this module, only once the modifiers are put in place. */ abstract contract Pausable is Context { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** * @dev Initializes the contract in unpaused state. */ constructor() { _paused = false; } /** * @dev Returns true if the contract is paused, and false otherwise. */ function paused() public view virtual returns (bool) { return _paused; } /** * @dev Modifier to make a function callable only when the contract is not paused. * * Requirements: * * - The contract must not be paused. */ modifier whenNotPaused() { require(!paused(), "Pausable: paused"); _; } /** * @dev Modifier to make a function callable only when the contract is paused. * * Requirements: * * - The contract must be paused. */ modifier whenPaused() { require(paused(), "Pausable: not paused"); _; } /** * @dev Triggers stopped state. * * Requirements: * * - The contract must not be paused. */ function _pause() internal virtual whenNotPaused { _paused = true; emit Paused(_msgSender()); } /** * @dev Returns to normal state. * * Requirements: * * - The contract must be paused. */ function _unpause() internal virtual whenPaused { _paused = false; emit Unpaused(_msgSender()); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "IERC20.sol"; import "IERC20Metadata.sol"; import "Context.sol"; /** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our guide * https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How * to implement supply mechanisms]. * * We have followed general OpenZeppelin Contracts guidelines: functions revert * instead returning `false` on failure. This behavior is nonetheless * conventional and does not conflict with the expectations of ERC20 * applications. * * Additionally, an {Approval} event is emitted on calls to {transferFrom}. * This allows applications to reconstruct the allowance for all accounts just * by listening to said events. Other implementations of the EIP may not emit * these events, as it isn't required by the specification. * * Finally, the non-standard {decreaseAllowance} and {increaseAllowance} * functions have been added to mitigate the well-known issues around setting * allowances. See {IERC20-approve}. */ contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {name} and {symbol}. * * The default value of {decimals} is 18. To select a different value for * {decimals} you should overload it. * * All two of these values are immutable: they can only be set once during * construction. */ constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; } /** * @dev Returns the name of the token. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev Returns the symbol of the token, usually a shorter version of the * name. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev Returns the number of decimals used to get its user representation. * For example, if `decimals` equals `2`, a balance of `505` tokens should * be displayed to a user as `5.05` (`505 / 10 ** 2`). * * Tokens usually opt for a value of 18, imitating the relationship between * Ether and Wei. This is the value {ERC20} uses, unless this function is * overridden; * * NOTE: This information is only used for _display_ purposes: it in * no way affects any of the arithmetic of the contract, including * {IERC20-balanceOf} and {IERC20-transfer}. */ function decimals() public view virtual override returns (uint8) { return 18; } /** * @dev See {IERC20-totalSupply}. */ function totalSupply() public view virtual override returns (uint256) { return _totalSupply; } /** * @dev See {IERC20-balanceOf}. */ function balanceOf(address account) public view virtual override returns (uint256) { return _balances[account]; } /** * @dev See {IERC20-transfer}. * * Requirements: * * - `recipient` cannot be the zero address. * - the caller must have a balance of at least `amount`. */ function transfer(address recipient, uint256 amount) public virtual override returns (bool) { _transfer(_msgSender(), recipient, amount); return true; } /** * @dev See {IERC20-allowance}. */ function allowance(address owner, address spender) public view virtual override returns (uint256) { return _allowances[owner][spender]; } /** * @dev See {IERC20-approve}. * * Requirements: * * - `spender` cannot be the zero address. */ function approve(address spender, uint256 amount) public virtual override returns (bool) { _approve(_msgSender(), spender, amount); return true; } /** * @dev See {IERC20-transferFrom}. * * Emits an {Approval} event indicating the updated allowance. This is not * required by the EIP. See the note at the beginning of {ERC20}. * * Requirements: * * - `sender` and `recipient` cannot be the zero address. * - `sender` must have a balance of at least `amount`. * - the caller must have allowance for ``sender``'s tokens of at least * `amount`. */ function transferFrom( address sender, address recipient, uint256 amount ) public virtual override returns (bool) { _transfer(sender, recipient, amount); uint256 currentAllowance = _allowances[sender][_msgSender()]; require(currentAllowance >= amount, "ERC20: transfer amount exceeds allowance"); unchecked { _approve(sender, _msgSender(), currentAllowance - amount); } return true; } /** * @dev Atomically increases the allowance granted to `spender` by the caller. * * This is an alternative to {approve} that can be used as a mitigation for * problems described in {IERC20-approve}. * * Emits an {Approval} event indicating the updated allowance. * * Requirements: * * - `spender` cannot be the zero address. */ function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) { _approve(_msgSender(), spender, _allowances[_msgSender()][spender] + addedValue); return true; } /** * @dev Atomically decreases the allowance granted to `spender` by the caller. * * This is an alternative to {approve} that can be used as a mitigation for * problems described in {IERC20-approve}. * * Emits an {Approval} event indicating the updated allowance. * * Requirements: * * - `spender` cannot be the zero address. * - `spender` must have allowance for the caller of at least * `subtractedValue`. */ function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) { uint256 currentAllowance = _allowances[_msgSender()][spender]; require(currentAllowance >= subtractedValue, "ERC20: decreased allowance below zero"); unchecked { _approve(_msgSender(), spender, currentAllowance - subtractedValue); } return true; } /** * @dev Moves `amount` of tokens from `sender` to `recipient`. * * This internal function is equivalent to {transfer}, and can be used to * e.g. implement automatic token fees, slashing mechanisms, etc. * * Emits a {Transfer} event. * * Requirements: * * - `sender` cannot be the zero address. * - `recipient` cannot be the zero address. * - `sender` must have a balance of at least `amount`. */ function _transfer( address sender, address recipient, uint256 amount ) internal virtual { require(sender != address(0), "ERC20: transfer from the zero address"); require(recipient != address(0), "ERC20: transfer to the zero address"); _beforeTokenTransfer(sender, recipient, amount); uint256 senderBalance = _balances[sender]; require(senderBalance >= amount, "ERC20: transfer amount exceeds balance"); unchecked { _balances[sender] = senderBalance - amount; } _balances[recipient] += amount; emit Transfer(sender, recipient, amount); _afterTokenTransfer(sender, recipient, amount); } /** @dev Creates `amount` tokens and assigns them to `account`, increasing * the total supply. * * Emits a {Transfer} event with `from` set to the zero address. * * Requirements: * * - `account` cannot be the zero address. */ function _mint(address account, uint256 amount) internal virtual { require(account != address(0), "ERC20: mint to the zero address"); _beforeTokenTransfer(address(0), account, amount); _totalSupply += amount; _balances[account] += amount; emit Transfer(address(0), account, amount); _afterTokenTransfer(address(0), account, amount); } /** * @dev Destroys `amount` tokens from `account`, reducing the * total supply. * * Emits a {Transfer} event with `to` set to the zero address. * * Requirements: * * - `account` cannot be the zero address. * - `account` must have at least `amount` tokens. */ function _burn(address account, uint256 amount) internal virtual { require(account != address(0), "ERC20: burn from the zero address"); _beforeTokenTransfer(account, address(0), amount); uint256 accountBalance = _balances[account]; require(accountBalance >= amount, "ERC20: burn amount exceeds balance"); unchecked { _balances[account] = accountBalance - amount; } _totalSupply -= amount; emit Transfer(account, address(0), amount); _afterTokenTransfer(account, address(0), amount); } /** * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens. * * This internal function is equivalent to `approve`, and can be used to * e.g. set automatic allowances for certain subsystems, etc. * * Emits an {Approval} event. * * Requirements: * * - `owner` cannot be the zero address. * - `spender` cannot be the zero address. */ 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"); _allowances[owner][spender] = amount; emit Approval(owner, spender, amount); } /** * @dev Hook that is called before any transfer of tokens. This includes * minting and burning. * * Calling conditions: * * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens * will be transferred to `to`. * - when `from` is zero, `amount` tokens will be minted for `to`. * - when `to` is zero, `amount` of ``from``'s tokens will be burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address from, address to, uint256 amount ) internal virtual {} /** * @dev Hook that is called after any transfer of tokens. This includes * minting and burning. * * Calling conditions: * * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens * has been transferred to `to`. * - when `from` is zero, `amount` tokens have been minted for `to`. * - when `to` is zero, `amount` of ``from``'s tokens have been burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _afterTokenTransfer( address from, address to, uint256 amount ) internal virtual {} }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @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 `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address recipient, 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 `sender` to `recipient` 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 sender, address recipient, uint256 amount ) external returns (bool); /** * @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); }
// SPDX-License-Identifier: MIT 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 pragma solidity ^0.8.0; // CAUTION // This version of SafeMath should only be used with Solidity 0.8 or later, // because it relies on the compiler's built in overflow checks. /** * @dev Wrappers over Solidity's arithmetic operations. * * NOTE: `SafeMath` is no longer needed starting with Solidity 0.8. The compiler * now has built in overflow checking. */ library SafeMath { /** * @dev Returns the addition of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { uint256 c = a + b; if (c < a) return (false, 0); return (true, c); } } /** * @dev Returns the substraction of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b > a) return (false, 0); return (true, a - b); } } /** * @dev Returns the multiplication of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == 0) return (true, 0); uint256 c = a * b; if (c / a != b) return (false, 0); return (true, c); } } /** * @dev Returns the division of two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a / b); } } /** * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a % b); } } /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { return a + b; } /** * @dev Returns the subtraction of two unsigned integers, reverting on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { return a - b; } /** * @dev Returns the multiplication of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * * - Multiplication cannot overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { return a * b; } /** * @dev Returns the integer division of two unsigned integers, reverting on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. * * Requirements: * * - The divisor cannot be zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { return a / b; } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { return a % b; } /** * @dev Returns the subtraction of two unsigned integers, reverting with custom message on * overflow (when the result is negative). * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {trySub}. * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b <= a, errorMessage); return a - b; } } /** * @dev Returns the integer division of two unsigned integers, reverting with custom message on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function div( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a / b; } } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting with custom message when dividing by zero. * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {tryMod}. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a % b; } } }
{ "evmVersion": "istanbul", "optimizer": { "enabled": true, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"symbol","type":"string"},{"internalType":"uint256","name":"initialSupply","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_user","type":"address"}],"name":"AddedBlackList","type":"event"},{"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":false,"internalType":"address","name":"_blackListedUser","type":"address"},{"indexed":false,"internalType":"uint256","name":"_balance","type":"uint256"}],"name":"DestroyedBlackFunds","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_user","type":"address"}],"name":"RemovedBlackList","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"GetBackLockedTokens","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_evilUser","type":"address"}],"name":"addBlackList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_addresses","type":"address[]"},{"internalType":"uint256[]","name":"_amount","type":"uint256[]"}],"name":"airdropByOwner","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"airdropcount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","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":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"}],"name":"checkLockingAmountByAddress","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"}],"name":"checkLockingTimeByAddress","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","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":"_affectiveAddress","type":"address"},{"internalType":"uint256","name":"_decreasedTime","type":"uint256"}],"name":"decreaseLockingTimeByAddress","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_blackListedUser","type":"address"}],"name":"destroyBlackFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"userAddress","type":"address"}],"name":"getLockingStatus","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"getRoleMember","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleMemberCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"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":"_affectiveAddress","type":"address"},{"internalType":"uint256","name":"_increasedTime","type":"uint256"}],"name":"increaseLockingTimeByAddress","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"isBlackListed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"_addresses","type":"address[]"},{"internalType":"uint256[]","name":"_amount","type":"uint256[]"},{"internalType":"uint8[]","name":"_lockedTime","type":"uint8[]"}],"name":"lockedAirdropByOwner","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","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":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_clearedUser","type":"address"}],"name":"removeBlackList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"uint8","name":"lockingTime","type":"uint8"}],"name":"transferLockedTokens","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":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address payable","name":"_to","type":"address"}],"name":"withdrawn","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"address","name":"_to","type":"address"},{"internalType":"address","name":"_tokenContract","type":"address"}],"name":"withdrawnTokens","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}]
Contract Creation Code
608060405260006009553480156200001657600080fd5b5060405162003659380380620036598339810160408190526200003991620004cf565b825183908390620000529060039060208501906200035c565b508051620000689060049060208401906200035c565b505050620000856200007f620000b860201b60201c565b620000bc565b620000926000336200010e565b6008805460ff191690558015620000af57620000af338262000151565b505050620005a6565b3390565b600580546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6200012582826200023a60201b62001a8a1760201c565b60008281526007602090815260409091206200014c91839062001a9462000246821b17901c565b505050565b6001600160a01b038216620001ac5760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f206164647265737300604482015260640160405180910390fd5b8060026000828254620001c0919062000542565b90915550506001600160a01b03821660009081526020819052604081208054839290620001ef90849062000542565b90915550506040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35b5050565b62000236828262000266565b60006200025d836001600160a01b0384166200030a565b90505b92915050565b60008281526006602090815260408083206001600160a01b038516845290915290205460ff16620002365760008281526006602090815260408083206001600160a01b03851684529091529020805460ff19166001179055620002c63390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b6000818152600183016020526040812054620003535750815460018181018455600084815260208082209093018490558454848252828601909352604090209190915562000260565b50600062000260565b8280546200036a9062000569565b90600052602060002090601f0160209004810192826200038e5760008555620003d9565b82601f10620003a957805160ff1916838001178555620003d9565b82800160010185558215620003d9579182015b82811115620003d9578251825591602001919060010190620003bc565b50620003e7929150620003eb565b5090565b5b80821115620003e75760008155600101620003ec565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200042a57600080fd5b81516001600160401b038082111562000447576200044762000402565b604051601f8301601f19908116603f0116810190828211818310171562000472576200047262000402565b816040528381526020925086838588010111156200048f57600080fd5b600091505b83821015620004b3578582018301518183018401529082019062000494565b83821115620004c55760008385830101525b9695505050505050565b600080600060608486031215620004e557600080fd5b83516001600160401b0380821115620004fd57600080fd5b6200050b8783880162000418565b945060208601519150808211156200052257600080fd5b50620005318682870162000418565b925050604084015190509250925092565b600082198211156200056457634e487b7160e01b600052601160045260246000fd5b500190565b600181811c908216806200057e57607f821691505b60208210811415620005a057634e487b7160e01b600052602260045260246000fd5b50919050565b6130a380620005b66000396000f3fe60806040526004361061026a5760003560e01c80638456cb5911610144578063ca15c873116100b6578063defcf51f1161007a578063defcf51f14610775578063e47d606014610795578063e4997dc5146107c5578063f2fde38b146107e5578063f3bdc22814610805578063f797a06a1461082557600080fd5b8063ca15c873146106b9578063cb9bd15a146106d9578063cddade79146106f9578063d547741f1461070f578063dd62ed3e1461072f57600080fd5b8063942f026011610108578063942f02601461060f57806394a6b7121461062f57806395d89b411461064f578063a217fddf14610664578063a457c2d714610679578063a9059cbb1461069957600080fd5b80638456cb5914610552578063894f879e146105675780638da5cb5b1461059d5780639010d07c146105cf57806391d14854146105ef57600080fd5b806336568abe116101dd57806345db2979116101a157806345db29791461048f5780635c975abb146104af5780636ef61092146104c757806370a08231146104e7578063715018a61461051d5780637338e39d1461053257600080fd5b806336568abe146103fa578063395093511461041a5780633f4ba83a1461043a57806340c10f191461044f57806342966c681461046f57600080fd5b806318160ddd1161022f57806318160ddd1461032f57806323b872dd1461034e578063248a9ca31461036e5780632d2e02b21461039e5780632f2ff15d146103be578063313ce567146103de57600080fd5b8062fe907e1461027657806301ffc9a7146102ab57806306fdde03146102cb578063095ea7b3146102ed5780630ecb93c01461030d57600080fd5b3661027157005b600080fd5b34801561028257600080fd5b5061029661029136600461297d565b610845565b60405190151581526020015b60405180910390f35b3480156102b757600080fd5b506102966102c63660046129bb565b6108dc565b3480156102d757600080fd5b506102e0610907565b6040516102a29190612a11565b3480156102f957600080fd5b50610296610308366004612a44565b610999565b34801561031957600080fd5b5061032d610328366004612a70565b610a17565b005b34801561033b57600080fd5b506002545b6040519081526020016102a2565b34801561035a57600080fd5b50610296610369366004612a8d565b610a9c565b34801561037a57600080fd5b50610340610389366004612ace565b60009081526006602052604090206001015490565b3480156103aa57600080fd5b506102966103b9366004612a8d565b610be6565b3480156103ca57600080fd5b5061032d6103d9366004612ae7565b610d2c565b3480156103ea57600080fd5b50604051601281526020016102a2565b34801561040657600080fd5b5061032d610415366004612ae7565b610d53565b34801561042657600080fd5b50610296610435366004612a44565b610ddd565b34801561044657600080fd5b5061032d610e54565b34801561045b57600080fd5b5061032d61046a366004612a44565b610e88565b34801561047b57600080fd5b5061032d61048a366004612ace565b610ef3565b34801561049b57600080fd5b506102966104aa366004612c51565b610f5e565b3480156104bb57600080fd5b5060085460ff16610296565b3480156104d357600080fd5b506102966104e2366004612a70565b611136565b3480156104f357600080fd5b50610340610502366004612a70565b6001600160a01b031660009081526020819052604090205490565b34801561052957600080fd5b5061032d611188565b34801561053e57600080fd5b5061029661054d366004612a44565b611233565b34801561055e57600080fd5b5061032d611333565b34801561057357600080fd5b50610340610582366004612a70565b6001600160a01b03166000908152600a602052604090205490565b3480156105a957600080fd5b506005546001600160a01b03165b6040516001600160a01b0390911681526020016102a2565b3480156105db57600080fd5b506105b76105ea366004612d36565b611365565b3480156105fb57600080fd5b5061029661060a366004612ae7565b61137d565b34801561061b57600080fd5b5061029661062a366004612d58565b6113a8565b34801561063b57600080fd5b5061029661064a366004612a44565b611457565b34801561065b57600080fd5b506102e0611533565b34801561067057600080fd5b50610340600081565b34801561068557600080fd5b50610296610694366004612a44565b611542565b3480156106a557600080fd5b506102966106b4366004612a44565b6115b9565b3480156106c557600080fd5b506103406106d4366004612ace565b6116c7565b3480156106e557600080fd5b506102966106f4366004612a70565b6116de565b34801561070557600080fd5b5061034060095481565b34801561071b57600080fd5b5061032d61072a366004612ae7565b61171e565b34801561073b57600080fd5b5061034061074a366004612d9a565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b34801561078157600080fd5b50610296610790366004612dc8565b6117c7565b3480156107a157600080fd5b506102966107b0366004612a70565b600c6020526000908152604090205460ff1681565b3480156107d157600080fd5b5061032d6107e0366004612a70565b6118d2565b3480156107f157600080fd5b5061032d610800366004612a70565b61194d565b34801561081157600080fd5b5061032d610820366004612a70565b61198e565b34801561083157600080fd5b50610340610840366004612a70565b611a46565b600061085360085460ff1690565b156108795760405162461bcd60e51b815260040161087090612e2c565b60405180910390fd5b6536b4b73a32b960d11b6108956005546001600160a01b031690565b6001600160a01b0316336001600160a01b0316146108b7576108b78133611aa9565b6108c5858460ff1686611b0d565b506108d1338686611b78565b506001949350505050565b60006001600160e01b03198216635a05180f60e01b1480610901575061090182611d48565b92915050565b60606003805461091690612e56565b80601f016020809104026020016040519081016040528092919081815260200182805461094290612e56565b801561098f5780601f106109645761010080835404028352916020019161098f565b820191906000526020600020905b81548152906001019060200180831161097257829003601f168201915b5050505050905090565b60006109a760085460ff1690565b156109c45760405162461bcd60e51b815260040161087090612e2c565b336000908152600c602052604090205460ff161580156109fd57506001600160a01b0383166000908152600c602052604090205460ff16155b610a0657600080fd5b610a108383611d7d565b9392505050565b6005546001600160a01b03163314610a415760405162461bcd60e51b815260040161087090612e91565b6001600160a01b0381166000818152600c6020908152604091829020805460ff1916600117905590519182527f42e160154868087d6bfdc0ca23d96a1c1cfa32f1b72ba9ba27b69b98a0d819dc91015b60405180910390a150565b6000610aaa60085460ff1690565b15610ac75760405162461bcd60e51b815260040161087090612e2c565b6001600160a01b0384166000908152600a602052604090205484908390421015610b6a576001600160a01b0382166000908152600b602090815260408083205491839052909120548291610b1c915b90611d93565b1015610b6a5760405162461bcd60e51b815260206004820152601d60248201527f496e73756666696369656e7420756e6c6f636b65642062616c616e63650000006044820152606401610870565b336000908152600c602052604090205460ff16158015610ba357506001600160a01b0386166000908152600c602052604090205460ff16155b8015610bc857506001600160a01b0385166000908152600c602052604090205460ff16155b610bd157600080fd5b610bdc868686611d9f565b9695505050505050565b6000610bf460085460ff1690565b15610c115760405162461bcd60e51b815260040161087090612e2c565b6536b4b73a32b960d11b610c2d6005546001600160a01b031690565b6001600160a01b0316336001600160a01b031614610c4f57610c4f8133611aa9565b6001600160a01b0385166000908152600b60205260409020548311801590610c8e57506001600160a01b0385166000908152600a602052604090205442105b610cda5760405162461bcd60e51b815260206004820152601b60248201527f496e73756666696369656e74206c6f636b65642062616c616e636500000000006044820152606401610870565b6001600160a01b0385166000908152600b6020526040902054610cfd9084611d93565b6001600160a01b038087166000818152600b60205260409020929092558516146108d1576108d1858585611b78565b610d368282611e3e565b6000828152600760205260409020610d4e9082611a94565b505050565b81151580610d6f57506005546001600160a01b03828116911614155b610dcf5760405162461bcd60e51b815260206004820152602b60248201527f54686520636f6e7472616374206f776e6572204d555354204e4f542072656e6f60448201526a3ab731b29030b236b4b71760a91b6064820152608401610870565b610dd98233611e64565b5050565b6000610deb60085460ff1690565b15610e085760405162461bcd60e51b815260040161087090612e2c565b336000908152600c602052604090205460ff16158015610e4157506001600160a01b0383166000908152600c602052604090205460ff16155b610e4a57600080fd5b610a108383611e86565b6005546001600160a01b03163314610e7e5760405162461bcd60e51b815260040161087090612e91565b610e86611ec2565b565b60085460ff1615610eab5760405162461bcd60e51b815260040161087090612e2c565b6536b4b73a32b960d11b610ec76005546001600160a01b031690565b6001600160a01b0316336001600160a01b031614610ee957610ee98133611aa9565b610d4e8383611f55565b60085460ff1615610f165760405162461bcd60e51b815260040161087090612e2c565b6536b4b73a32b960d11b610f326005546001600160a01b031690565b6001600160a01b0316336001600160a01b031614610f5457610f548133611aa9565b610dd93383612034565b6000610f6c60085460ff1690565b15610f895760405162461bcd60e51b815260040161087090612e2c565b66061697264726f760cc1b610fa66005546001600160a01b031690565b6001600160a01b0316336001600160a01b031614610fc857610fc88133611aa9565b83518551146110115760405162461bcd60e51b8152602060048201526015602482015274496e76616c696420616d6f756e747320417272617960581b6044820152606401610870565b82518551146110625760405162461bcd60e51b815260206004820152601860248201527f496e76616c6964206c6f636b656454696d6520417272617900000000000000006044820152606401610870565b845160005b81811015611129576110c887828151811061108457611084612ec6565b602002602001015186838151811061109e5761109e612ec6565b602002602001015160ff168884815181106110bb576110bb612ec6565b6020026020010151611b0d565b50611106338883815181106110df576110df612ec6565b60200260200101518884815181106110f9576110f9612ec6565b6020026020010151611b78565b600954611114906001612ef2565b6009558061112181612f0a565b915050611067565b5060019695505050505050565b6005546000906001600160a01b031633146111635760405162461bcd60e51b815260040161087090612e91565b3060008181526020819052604090205461117f91908490611b78565b5060015b919050565b6005546001600160a01b031633146111b25760405162461bcd60e51b815260040161087090612e91565b60405162461bcd60e51b815260206004820152604a60248201527f596f75204d555354204e4f542072656e6f756e6365206f776e6572736869702e60448201527f20596f752063616e206f6e6c79207472616e7366657220746f20616e6f746865606482015269391030b2323932b9b99760b11b608482015260a401610870565b600061124160085460ff1690565b1561125e5760405162461bcd60e51b815260040161087090612e2c565b6536b4b73a32b960d11b61127a6005546001600160a01b031690565b6001600160a01b0316336001600160a01b03161461129c5761129c8133611aa9565b6000831180156112c357506001600160a01b0384166000908152600a602052604090205442105b6112df5760405162461bcd60e51b815260040161087090612f25565b6112ec8362015180612f73565b6001600160a01b0385166000908152600a602052604090205461130f9190612f92565b6001600160a01b0385166000908152600a6020526040902055600191505092915050565b6005546001600160a01b0316331461135d5760405162461bcd60e51b815260040161087090612e91565b610e86612182565b6000828152600760205260408120610a1090836121da565b60009182526006602090815260408084206001600160a01b0393909316845291905290205460ff1690565b6005546000906001600160a01b031633146113d55760405162461bcd60e51b815260040161087090612e91565b60405163a9059cbb60e01b81526001600160a01b0384811660048301526024820186905283919082169063a9059cbb906044016020604051808303816000875af1158015611427573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061144b9190612fa9565b50600195945050505050565b600061146560085460ff1690565b156114825760405162461bcd60e51b815260040161087090612e2c565b6536b4b73a32b960d11b61149e6005546001600160a01b031690565b6001600160a01b0316336001600160a01b0316146114c0576114c08133611aa9565b6000831180156114e757506001600160a01b0384166000908152600a602052604090205442105b6115035760405162461bcd60e51b815260040161087090612f25565b6115108362015180612f73565b6001600160a01b0385166000908152600a602052604090205461130f9190612ef2565b60606004805461091690612e56565b600061155060085460ff1690565b1561156d5760405162461bcd60e51b815260040161087090612e2c565b336000908152600c602052604090205460ff161580156115a657506001600160a01b0383166000908152600c602052604090205460ff16155b6115af57600080fd5b610a1083836121e6565b60006115c760085460ff1690565b156115e45760405162461bcd60e51b815260040161087090612e2c565b336000818152600a6020526040902054839042101561167a576001600160a01b0382166000908152600b60209081526040808320549183905290912054829161162c91610b16565b101561167a5760405162461bcd60e51b815260206004820152601d60248201527f496e73756666696369656e7420756e6c6f636b65642062616c616e63650000006044820152606401610870565b336000908152600c602052604090205460ff161580156116b357506001600160a01b0385166000908152600c602052604090205460ff16155b6116bc57600080fd5b6108d1338686611b78565b60008181526007602052604081206109019061227f565b6001600160a01b0381166000908152600a6020526040812054421080156109015750506001600160a01b03166000908152600b6020526040902054151590565b60008281526006602052604090206001015461173a8133611aa9565b8215158061175657506005546001600160a01b03838116911614155b6117bd5760405162461bcd60e51b815260206004820152603260248201527f596f75204d555354204e4f54207265766f6b652061646d696e2066726f6d207460448201527134329031b7b73a3930b1ba1037bbb732b91760711b6064820152608401610870565b610d4e8383612289565b60006117d560085460ff1690565b156117f25760405162461bcd60e51b815260040161087090612e2c565b66061697264726f760cc1b61180f6005546001600160a01b031690565b6001600160a01b0316336001600160a01b031614611831576118318133611aa9565b82518451146118725760405162461bcd60e51b815260206004820152600d60248201526c496e76616c696420417272617960981b6044820152606401610870565b835160005b8181101561144b576118af3387838151811061189557611895612ec6565b60200260200101518784815181106110f9576110f9612ec6565b6009546118bd906001612ef2565b600955806118ca81612f0a565b915050611877565b6005546001600160a01b031633146118fc5760405162461bcd60e51b815260040161087090612e91565b6001600160a01b0381166000818152600c6020908152604091829020805460ff1916905590519182527fd7e9ec6e6ecd65492dce6bf513cd6867560d49544421d0783ddf06e76c24470c9101610a91565b6005546001600160a01b031633146119775760405162461bcd60e51b815260040161087090612e91565b611982600082610d2c565b61198b81612293565b50565b6005546001600160a01b031633146119b85760405162461bcd60e51b815260040161087090612e91565b6001600160a01b0381166000908152600c602052604090205460ff166119dd57600080fd5b6001600160a01b038116600090815260208190526040902054611a008282612034565b604080516001600160a01b0384168152602081018390527f61e6e66b0d6339b2980aecc6ccc0039736791f0ccde9ed512e789a7fbdd698c6910160405180910390a15050565b6001600160a01b0381166000908152600a6020526040812054421015611a8257506001600160a01b03166000908152600b602052604090205490565b506000919050565b610dd9828261232b565b6000610a10836001600160a01b0384166123b1565b611ab3828261137d565b610dd957611acb816001600160a01b03166014612400565b611ad6836020612400565b604051602001611ae7929190612fcb565b60408051601f198184030181529082905262461bcd60e51b825261087091600401612a11565b6000611b1c8362015180612f73565b611b269042612ef2565b6001600160a01b0385166000908152600a6020908152604080832093909355600b90522054611b55908361259c565b6001600160a01b0385166000908152600b60205260409020555060019392505050565b6001600160a01b038316611bdc5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610870565b6001600160a01b038216611c3e5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610870565b6001600160a01b03831660009081526020819052604090205481811015611cb65760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b6064820152608401610870565b6001600160a01b03808516600090815260208190526040808220858503905591851681529081208054849290611ced908490612ef2565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef84604051611d3991815260200190565b60405180910390a35b50505050565b60006001600160e01b03198216637965db0b60e01b148061090157506301ffc9a760e01b6001600160e01b0319831614610901565b6000611d8a3384846125a8565b50600192915050565b6000610a108284612f92565b6000611dac848484611b78565b6001600160a01b038416600090815260016020908152604080832033845290915290205482811015611e315760405162461bcd60e51b815260206004820152602860248201527f45524332303a207472616e7366657220616d6f756e74206578636565647320616044820152676c6c6f77616e636560c01b6064820152608401610870565b6108d185338584036125a8565b600082815260066020526040902060010154611e5a8133611aa9565b610d4e838361232b565b611e6e82826126cc565b6000828152600760205260409020610d4e9082612746565b3360008181526001602090815260408083206001600160a01b03871684529091528120549091611d8a918590611ebd908690612ef2565b6125a8565b60085460ff16611f0b5760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b6044820152606401610870565b6008805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b6001600160a01b038216611fab5760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610870565b8060026000828254611fbd9190612ef2565b90915550506001600160a01b03821660009081526020819052604081208054839290611fea908490612ef2565b90915550506040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b6001600160a01b0382166120945760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b6064820152608401610870565b6001600160a01b038216600090815260208190526040902054818110156121085760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b6064820152608401610870565b6001600160a01b0383166000908152602081905260408120838303905560028054849290612137908490612f92565b90915550506040518281526000906001600160a01b038516907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a3505050565b60085460ff16156121a55760405162461bcd60e51b815260040161087090612e2c565b6008805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258611f383390565b6000610a10838361275b565b3360009081526001602090815260408083206001600160a01b0386168452909152812054828110156122685760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b6064820152608401610870565b61227533858584036125a8565b5060019392505050565b6000610901825490565b611e6e8282612785565b6005546001600160a01b031633146122bd5760405162461bcd60e51b815260040161087090612e91565b6001600160a01b0381166123225760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610870565b61198b816127ab565b612335828261137d565b610dd95760008281526006602090815260408083206001600160a01b03851684529091529020805460ff1916600117905561236d3390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b60008181526001830160205260408120546123f857508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610901565b506000610901565b6060600061240f836002612f73565b61241a906002612ef2565b67ffffffffffffffff81111561243257612432612b17565b6040519080825280601f01601f19166020018201604052801561245c576020820181803683370190505b509050600360fc1b8160008151811061247757612477612ec6565b60200101906001600160f81b031916908160001a905350600f60fb1b816001815181106124a6576124a6612ec6565b60200101906001600160f81b031916908160001a90535060006124ca846002612f73565b6124d5906001612ef2565b90505b600181111561254d576f181899199a1a9b1b9c1cb0b131b232b360811b85600f166010811061250957612509612ec6565b1a60f81b82828151811061251f5761251f612ec6565b60200101906001600160f81b031916908160001a90535060049490941c9361254681613040565b90506124d8565b508315610a105760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610870565b6000610a108284612ef2565b6001600160a01b03831661260a5760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610870565b6001600160a01b03821661266b5760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610870565b6001600160a01b0383811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b6001600160a01b038116331461273c5760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b6064820152608401610870565b610dd982826127fd565b6000610a10836001600160a01b038416612864565b600082600001828154811061277257612772612ec6565b9060005260206000200154905092915050565b6000828152600660205260409020600101546127a18133611aa9565b610d4e83836127fd565b600580546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b612807828261137d565b15610dd95760008281526006602090815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b6000818152600183016020526040812054801561294d576000612888600183612f92565b855490915060009061289c90600190612f92565b90508181146129015760008660000182815481106128bc576128bc612ec6565b90600052602060002001549050808760000184815481106128df576128df612ec6565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061291257612912613057565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610901565b6000915050610901565b6001600160a01b038116811461198b57600080fd5b803560ff8116811461118357600080fd5b60008060006060848603121561299257600080fd5b833561299d81612957565b9250602084013591506129b26040850161296c565b90509250925092565b6000602082840312156129cd57600080fd5b81356001600160e01b031981168114610a1057600080fd5b60005b83811015612a005781810151838201526020016129e8565b83811115611d425750506000910152565b6020815260008251806020840152612a308160408501602087016129e5565b601f01601f19169190910160400192915050565b60008060408385031215612a5757600080fd5b8235612a6281612957565b946020939093013593505050565b600060208284031215612a8257600080fd5b8135610a1081612957565b600080600060608486031215612aa257600080fd5b8335612aad81612957565b92506020840135612abd81612957565b929592945050506040919091013590565b600060208284031215612ae057600080fd5b5035919050565b60008060408385031215612afa57600080fd5b823591506020830135612b0c81612957565b809150509250929050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff81118282101715612b5657612b56612b17565b604052919050565b600067ffffffffffffffff821115612b7857612b78612b17565b5060051b60200190565b600082601f830112612b9357600080fd5b81356020612ba8612ba383612b5e565b612b2d565b82815260059290921b84018101918181019086841115612bc757600080fd5b8286015b84811015612beb578035612bde81612957565b8352918301918301612bcb565b509695505050505050565b600082601f830112612c0757600080fd5b81356020612c17612ba383612b5e565b82815260059290921b84018101918181019086841115612c3657600080fd5b8286015b84811015612beb5780358352918301918301612c3a565b600080600060608486031215612c6657600080fd5b833567ffffffffffffffff80821115612c7e57600080fd5b612c8a87838801612b82565b9450602091508186013581811115612ca157600080fd5b612cad88828901612bf6565b945050604086013581811115612cc257600080fd5b86019050601f81018713612cd557600080fd5b8035612ce3612ba382612b5e565b81815260059190911b82018301908381019089831115612d0257600080fd5b928401925b82841015612d2757612d188461296c565b82529284019290840190612d07565b80955050505050509250925092565b60008060408385031215612d4957600080fd5b50508035926020909101359150565b600080600060608486031215612d6d57600080fd5b833592506020840135612d7f81612957565b91506040840135612d8f81612957565b809150509250925092565b60008060408385031215612dad57600080fd5b8235612db881612957565b91506020830135612b0c81612957565b60008060408385031215612ddb57600080fd5b823567ffffffffffffffff80821115612df357600080fd5b612dff86838701612b82565b93506020850135915080821115612e1557600080fd5b50612e2285828601612bf6565b9150509250929050565b60208082526010908201526f14185d5cd8589b194e881c185d5cd95960821b604082015260600190565b600181811c90821680612e6a57607f821691505b60208210811415612e8b57634e487b7160e01b600052602260045260246000fd5b50919050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b60008219821115612f0557612f05612edc565b500190565b6000600019821415612f1e57612f1e612edc565b5060010190565b6020808252602e908201527f506c6561736520636865636b206164647265737320737461747573206f72204960408201526d1b98dbdc9c9958dd081a5b9c1d5d60921b606082015260800190565b6000816000190483118215151615612f8d57612f8d612edc565b500290565b600082821015612fa457612fa4612edc565b500390565b600060208284031215612fbb57600080fd5b81518015158114610a1057600080fd5b7f416363657373436f6e74726f6c3a206163636f756e74200000000000000000008152600083516130038160178501602088016129e5565b7001034b99036b4b9b9b4b733903937b6329607d1b60179184019182015283516130348160288401602088016129e5565b01602801949350505050565b60008161304f5761304f612edc565b506000190190565b634e487b7160e01b600052603160045260246000fdfea2646970667358221220a584a310c45aa9d6c5b53efd14d169c940da63170c147c1dbfad84c8a6bab71364736f6c634300080a0033000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008566963696e697479000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000456434e5400000000000000000000000000000000000000000000000000000000
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008566963696e697479000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000456434e5400000000000000000000000000000000000000000000000000000000
-----Decoded View---------------
Arg [0] : name (string): Vicinity
Arg [1] : symbol (string): VCNT
Arg [2] : initialSupply (uint256): 0
-----Encoded View---------------
7 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000060
Arg [1] : 00000000000000000000000000000000000000000000000000000000000000a0
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000008
Arg [4] : 566963696e697479000000000000000000000000000000000000000000000000
Arg [5] : 0000000000000000000000000000000000000000000000000000000000000004
Arg [6] : 56434e5400000000000000000000000000000000000000000000000000000000