Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Name:
BIFKN314Locker
Compiler Version
v0.8.20+commit.a1b79de6
Optimization Enabled:
Yes with 50 runs
Other Settings:
paris EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity 0.8.20; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol"; import "@openzeppelin/contracts/utils/ReentrancyGuard.sol"; contract BIFKN314Locker is Ownable(msg.sender), ReentrancyGuard { using SafeERC20 for IERC20; uint256 public constant FEE_RATE = 100; // 1% uint256 public constant EXTEND_LOCK_DURATION_FEE_RATE = 50; // 0.5% address public feeTo; address public feeToSetter; /** * @dev Represents a locked (Liquidity Provider) token. * * Each locked token has the following properties: * - `token`: The address of the token being locked. * - `amount`: The amount of tokens being locked. * - `unlockTime`: The timestamp when the tokens can be unlocked. * - `owner`: The address of the user who owns the locked tokens. */ struct LockedToken { IERC20 token; uint256 amount; uint256 unlockTime; uint256 totalLockDuration; address owner; uint256 lockId; bool claimed; } // Mapping from lock ID to the owner's address mapping(uint256 => address) public lockOwner; // Mapping from user address to an array of lock IDs mapping(address => uint256[]) public userLockIds; // Array to store all locks LockedToken[] public lockedTokens; event LockTokens(address indexed user, uint256 lockId, uint256 unlockTime); event ExtendLockDuration( address indexed user, uint256 lockId, uint256 additionalDuration ); event ClaimUnlockedTokens(address indexed user, uint256 lockId); event TransferLockOwnership( uint256 indexed lockId, address indexed oldOwner, address indexed newOwner ); error AmountMustBeGreaterThanZero(); error InvalidLockId(); error UnauthorizedLockId(); error InvalidAddress(address address_); error OnlyFeeToSetter(address caller); error LockNotExpired(uint256 unlockTime, uint256 currentTime); error AlreadyClaimed(); /** * @dev Modifier to restrict access to the `onlyFeeToSetter` function. * It ensures that only the `feeToSetter` address can execute the function. * Reverts with an error message if the caller is not the `feeToSetter`. */ modifier onlyFeeToSetter() { if (_msgSender() != feeToSetter) revert OnlyFeeToSetter(_msgSender()); _; } /** * @dev Initializes the contract with the specified feeTo and feeToSetter addresses. * @param _feeTo The address where the fees will be sent to. * @param _feeToSetter The address that is allowed to update the feeTo address. */ constructor(address _feeTo, address _feeToSetter) { if (_feeTo == address(0)) { revert InvalidAddress(_feeTo); } if (_feeToSetter == address(0)) { revert InvalidAddress(_feeToSetter); } feeTo = _feeTo; feeToSetter = _feeToSetter; } /** * @dev Updates the feeTo address. * @param _feeTo The address where the fees will be sent to. */ function setFeeTo(address _feeTo) external onlyFeeToSetter { if (_feeTo == address(0)) { revert InvalidAddress(_feeTo); } feeTo = _feeTo; } /** * @dev Updates the feeToSetter address. * @param _feeToSetter The address that is allowed to update the feeTo address. */ function setFeeToSetter(address _feeToSetter) external onlyFeeToSetter { if (_feeToSetter == address(0)) { revert InvalidAddress(_feeToSetter); } feeToSetter = _feeToSetter; } /** * @dev Locks tokens in the contract for a specified duration. * @param _token The token to lock. * @param _amount The amount of tokens to lock. * @param _daysToLock The number of days to lock the tokens for. */ function lockTokens( IERC20 _token, uint256 _amount, uint256 _daysToLock ) external nonReentrant { if (_amount == 0) { revert AmountMustBeGreaterThanZero(); } if (_daysToLock == 0) { revert AmountMustBeGreaterThanZero(); } address sender = _msgSender(); uint256 unlockTime = block.timestamp + (_daysToLock * 1 days); uint256 fee = (_amount * FEE_RATE) / 10000; // 1% fee uint256 amountAfterFee = _amount - fee; uint256 lockId = lockedTokens.length; // Lock ID is the index of the lock in the array LockedToken memory newLock = LockedToken({ token: _token, amount: amountAfterFee, unlockTime: unlockTime, totalLockDuration: _daysToLock, owner: sender, lockId: lockId, claimed: false }); lockedTokens.push(newLock); userLockIds[sender].push(lockId); lockOwner[lockId] = sender; _token.safeTransferFrom(sender, feeTo, fee); // Transfer fee to feeTo address _token.safeTransferFrom(sender, address(this), amountAfterFee); // Transfer tokens to this contract emit LockTokens(sender, lockId, unlockTime); } /** * Allows users to extend the lock duration of specific locked tokens by ID. * @param _lockId The unique identifier of the locked position to extend. * @param _additionalDurationInDays The additional duration in days to extend the lock period. */ function extendLockDuration( uint256 _lockId, uint256 _additionalDurationInDays ) public nonReentrant { if (_additionalDurationInDays == 0) revert AmountMustBeGreaterThanZero(); address sender = _msgSender(); if (_lockId >= lockedTokens.length) { revert InvalidLockId(); } if (lockOwner[_lockId] != sender) { revert UnauthorizedLockId(); } if (lockedTokens[_lockId].claimed) { revert AlreadyClaimed(); } LockedToken storage lock = lockedTokens[_lockId]; uint256 fee = (lock.amount * EXTEND_LOCK_DURATION_FEE_RATE) / 10000; // 0.5% fee // if the lock is already expired, the additional duration will be added to the current time if (block.timestamp >= lock.unlockTime) { lock.unlockTime = block.timestamp + (_additionalDurationInDays * 1 days); // if the lock is expired, duration can be extended for the original fee // This is to encourage users to extend the lock duration before the lock expires fee = (lock.amount * FEE_RATE) / 10000; // 1% fee } else { // if the lock is not expired, the additional duration will be added to the current unlock time // for the extend lock duration fee of 0.5% lock.unlockTime += (_additionalDurationInDays * 1 days); } // update the total lock duration lock.totalLockDuration += _additionalDurationInDays; lock.amount -= fee; lock.token.safeTransfer(feeTo, fee); // Transfer fee to feeTo address emit ExtendLockDuration(sender, _lockId, _additionalDurationInDays); } /** * @dev Allows the lock owner to claim unlocked tokens. * @param _lockId The ID of the lock. */ function claimUnlockedTokens(uint256 _lockId) public nonReentrant { address sender = _msgSender(); if (_lockId >= lockedTokens.length) { revert InvalidLockId(); } if (lockOwner[_lockId] != sender) { revert UnauthorizedLockId(); } if (lockedTokens[_lockId].claimed) { revert AlreadyClaimed(); } LockedToken storage lock = lockedTokens[_lockId]; if (block.timestamp < lock.unlockTime) { revert LockNotExpired(lock.unlockTime, block.timestamp); } if (block.timestamp >= lock.unlockTime) { lockOwner[_lockId] = address(0); lock.claimed = true; lock.token.safeTransfer(sender, lock.amount); emit ClaimUnlockedTokens(sender, _lockId); } } /** * @dev Claims all unlocked tokens for the caller. * This function transfers the unlocked tokens to the caller's address. * Only tokens associated with the caller's lock IDs and whose unlock time has passed will be claimed. * Emits a `ClaimUnlockedTokens` event for each successfully claimed token. */ function claimAllUnlockedTokens() public nonReentrant { address sender = _msgSender(); uint256[] memory lockIds = userLockIds[sender]; uint256 lockIdsLength = lockIds.length; for (uint256 i = 0; i < lockIdsLength; i++) { uint256 lockId = lockIds[i]; LockedToken storage lock = lockedTokens[lockId]; // if the lock is claimed, it cannot be claimed again if (!lock.claimed && block.timestamp >= lock.unlockTime) { lockOwner[lockId] = address(0); lock.claimed = true; lock.token.safeTransfer(sender, lock.amount); emit ClaimUnlockedTokens(sender, lockId); } } } /** * @dev Transfers the ownership of a lock to a new owner. * @param _lockId The ID of the lock to transfer ownership. * @param _newOwner The address of the new owner. * @notice This function can only be called by the current owner of the lock. * @notice The new owner cannot be the zero address. * @notice If the lock ID is invalid or the caller is not the current owner, the function will revert. * @notice The lock ownership is updated, and the lock is added to the new owner's list of locks. * @notice The lock is removed from the old owner's list of locks. * @notice Emits a TransferLockOwnership event with the lock ID, the current owner, and the new owner. */ function transferLockOwnership( uint256 _lockId, address _newOwner ) public nonReentrant { if (_newOwner == address(0)) revert InvalidAddress(_newOwner); if (_newOwner == _msgSender()) revert InvalidAddress(_newOwner); address sender = _msgSender(); if (_lockId >= lockedTokens.length) { revert InvalidLockId(); } if (lockOwner[_lockId] != sender) { revert UnauthorizedLockId(); } // if the lock is claimed, it cannot be transferred if (lockedTokens[_lockId].claimed) { revert AlreadyClaimed(); } lockOwner[_lockId] = _newOwner; // Update lock owner userLockIds[_newOwner].push(_lockId); // Add lock to new owner // Remove lock from old owner uint256[] storage oldOwnerLockIds = userLockIds[sender]; uint256 oldOwnerLockIdsLength = oldOwnerLockIds.length; for (uint256 i = 0; i < oldOwnerLockIdsLength; i++) { if (oldOwnerLockIds[i] == _lockId) { oldOwnerLockIds[i] = oldOwnerLockIds[oldOwnerLockIdsLength - 1]; oldOwnerLockIds.pop(); break; } } emit TransferLockOwnership(_lockId, sender, _newOwner); } /** * @dev Returns the lock IDs for a given user. * @param _user The address of the user. * @return _lockIDs An array of lock IDs. */ function getUserLocks( address _user ) external view returns (uint256[] memory _lockIDs) { return userLockIds[_user]; } /** * @dev Retrieves the details of a specific lock. * @param _lockId The ID of the lock to retrieve details for. * @return _lockDetails The details of the lock as a `LockedToken` struct. */ function getLockDetails( uint256 _lockId ) external view returns (LockedToken memory _lockDetails) { return lockedTokens[_lockId]; } /** * @dev Retrieves all lock details for a given user. * @param _user The address of the user. * @return _lockDetails An array of LockedToken structs representing the lock details. */ function getAllLockDetailsForUser( address _user ) external view returns (LockedToken[] memory _lockDetails) { uint256[] memory lockIds = userLockIds[_user]; uint256 lockIdsLength = lockIds.length; // Cached length for gas optimization LockedToken[] memory locks = new LockedToken[](lockIdsLength); for (uint256 i = 0; i < lockIdsLength; i++) { locks[i] = lockedTokens[lockIds[i]]; } return locks; } /** * @dev Retrieves the lock details for a specific user and token. * @param _user The address of the user. * @param _token The address of the token. * @return _lockDetails An array of LockedToken structs representing the lock details. */ function getLockDetailsByUserAndToken( address _user, IERC20 _token ) external view returns (LockedToken[] memory _lockDetails) { uint256[] memory lockIds = userLockIds[_user]; uint256 relevantLocksCount = 0; uint256 lockIdsLength = lockIds.length; // First pass: Count relevant locks for (uint256 i = 0; i < lockIdsLength; i++) { if (lockedTokens[lockIds[i]].token == _token) { relevantLocksCount++; } } // Allocate array of the correct size LockedToken[] memory relevantLocks = new LockedToken[]( relevantLocksCount ); // Second pass: Populate the array uint256 counter = 0; for (uint256 i = 0; i < lockIdsLength; i++) { if (lockedTokens[lockIds[i]].token == _token) { relevantLocks[counter] = lockedTokens[lockIds[i]]; counter++; } } return relevantLocks; } /** * @dev Retrieves the lock details for a specific token. * @param _token The ERC20 token for which to retrieve the lock details. * @return _lockDetails An array of LockedToken structs representing the lock details. */ function getLockDetailsByToken( IERC20 _token ) external view returns (LockedToken[] memory _lockDetails) { uint256 lockCount = lockedTokens.length; uint256 relevantLocksCount = 0; // First pass: Count relevant locks for (uint256 i = 0; i < lockCount; i++) { if (lockedTokens[i].token == _token) { relevantLocksCount++; } } // Allocate array of the correct size LockedToken[] memory relevantLocks = new LockedToken[]( relevantLocksCount ); // Second pass: Populate the array uint256 counter = 0; for (uint256 i = 0; i < lockCount; i++) { if (lockedTokens[i].token == _token) { relevantLocks[counter] = lockedTokens[i]; counter++; } } return relevantLocks; } /** * @dev Returns the number of locks for a given user. * @param _user The address of the user. * @return _count The number of locks. */ function getUserLocksCount( address _user ) external view returns (uint256 _count) { return userLockIds[_user].length; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (access/Ownable.sol) pragma solidity ^0.8.20; import {Context} from "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * The initial owner is set to the address provided by the deployer. 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; /** * @dev The caller account is not authorized to perform an operation. */ error OwnableUnauthorizedAccount(address account); /** * @dev The owner is not a valid owner account. (eg. `address(0)`) */ error OwnableInvalidOwner(address owner); event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the address provided by the deployer as the initial owner. */ constructor(address initialOwner) { if (initialOwner == address(0)) { revert OwnableInvalidOwner(address(0)); } _transferOwnership(initialOwner); } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { _checkOwner(); _; } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { if (owner() != _msgSender()) { revert OwnableUnauthorizedAccount(_msgSender()); } } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby disabling any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { if (newOwner == address(0)) { revert OwnableInvalidOwner(address(0)); } _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/IERC20.sol) pragma solidity ^0.8.20; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); /** * @dev Returns the value of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the value of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves a `value` amount of tokens from the caller's account to `to`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address to, uint256 value) 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 a `value` amount of tokens 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 value) external returns (bool); /** * @dev Moves a `value` amount of tokens from `from` to `to` using the * allowance mechanism. `value` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom(address from, address to, uint256 value) external returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/extensions/IERC20Permit.sol) pragma solidity ^0.8.20; /** * @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612]. * * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by * presenting a message signed by the account. By not relying on {IERC20-approve}, the token holder account doesn't * need to send a transaction, and thus is not required to hold Ether at all. * * ==== Security Considerations * * There are two important considerations concerning the use of `permit`. The first is that a valid permit signature * expresses an allowance, and it should not be assumed to convey additional meaning. In particular, it should not be * considered as an intention to spend the allowance in any specific way. The second is that because permits have * built-in replay protection and can be submitted by anyone, they can be frontrun. A protocol that uses permits should * take this into consideration and allow a `permit` call to fail. Combining these two aspects, a pattern that may be * generally recommended is: * * ```solidity * function doThingWithPermit(..., uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s) public { * try token.permit(msg.sender, address(this), value, deadline, v, r, s) {} catch {} * doThing(..., value); * } * * function doThing(..., uint256 value) public { * token.safeTransferFrom(msg.sender, address(this), value); * ... * } * ``` * * Observe that: 1) `msg.sender` is used as the owner, leaving no ambiguity as to the signer intent, and 2) the use of * `try/catch` allows the permit to fail and makes the code tolerant to frontrunning. (See also * {SafeERC20-safeTransferFrom}). * * Additionally, note that smart contract wallets (such as Argent or Safe) are not able to produce permit signatures, so * contracts should have entry points that don't rely on permit. */ interface IERC20Permit { /** * @dev Sets `value` as the allowance of `spender` over ``owner``'s tokens, * given ``owner``'s signed approval. * * IMPORTANT: The same issues {IERC20-approve} has related to transaction * ordering also apply here. * * Emits an {Approval} event. * * Requirements: * * - `spender` cannot be the zero address. * - `deadline` must be a timestamp in the future. * - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner` * over the EIP712-formatted function arguments. * - the signature must use ``owner``'s current nonce (see {nonces}). * * For more information on the signature format, see the * https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP * section]. * * CAUTION: See Security Considerations above. */ function permit( address owner, address spender, uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s ) external; /** * @dev Returns the current nonce for `owner`. This value must be * included whenever a signature is generated for {permit}. * * Every successful call to {permit} increases ``owner``'s nonce by one. This * prevents a signature from being used multiple times. */ function nonces(address owner) external view returns (uint256); /** * @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}. */ // solhint-disable-next-line func-name-mixedcase function DOMAIN_SEPARATOR() external view returns (bytes32); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/utils/SafeERC20.sol) pragma solidity ^0.8.20; import {IERC20} from "../IERC20.sol"; import {IERC20Permit} from "../extensions/IERC20Permit.sol"; import {Address} from "../../../utils/Address.sol"; /** * @title SafeERC20 * @dev Wrappers around ERC20 operations that throw on failure (when the token * contract returns false). Tokens that return no value (and instead revert or * throw on failure) are also supported, non-reverting calls are assumed to be * successful. * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract, * which allows you to call the safe operations as `token.safeTransfer(...)`, etc. */ library SafeERC20 { using Address for address; /** * @dev An operation with an ERC20 token failed. */ error SafeERC20FailedOperation(address token); /** * @dev Indicates a failed `decreaseAllowance` request. */ error SafeERC20FailedDecreaseAllowance(address spender, uint256 currentAllowance, uint256 requestedDecrease); /** * @dev Transfer `value` amount of `token` from the calling contract to `to`. If `token` returns no value, * non-reverting calls are assumed to be successful. */ function safeTransfer(IERC20 token, address to, uint256 value) internal { _callOptionalReturn(token, abi.encodeCall(token.transfer, (to, value))); } /** * @dev Transfer `value` amount of `token` from `from` to `to`, spending the approval given by `from` to the * calling contract. If `token` returns no value, non-reverting calls are assumed to be successful. */ function safeTransferFrom(IERC20 token, address from, address to, uint256 value) internal { _callOptionalReturn(token, abi.encodeCall(token.transferFrom, (from, to, value))); } /** * @dev Increase the calling contract's allowance toward `spender` by `value`. If `token` returns no value, * non-reverting calls are assumed to be successful. */ function safeIncreaseAllowance(IERC20 token, address spender, uint256 value) internal { uint256 oldAllowance = token.allowance(address(this), spender); forceApprove(token, spender, oldAllowance + value); } /** * @dev Decrease the calling contract's allowance toward `spender` by `requestedDecrease`. If `token` returns no * value, non-reverting calls are assumed to be successful. */ function safeDecreaseAllowance(IERC20 token, address spender, uint256 requestedDecrease) internal { unchecked { uint256 currentAllowance = token.allowance(address(this), spender); if (currentAllowance < requestedDecrease) { revert SafeERC20FailedDecreaseAllowance(spender, currentAllowance, requestedDecrease); } forceApprove(token, spender, currentAllowance - requestedDecrease); } } /** * @dev Set the calling contract's allowance toward `spender` to `value`. If `token` returns no value, * non-reverting calls are assumed to be successful. Meant to be used with tokens that require the approval * to be set to zero before setting it to a non-zero value, such as USDT. */ function forceApprove(IERC20 token, address spender, uint256 value) internal { bytes memory approvalCall = abi.encodeCall(token.approve, (spender, value)); if (!_callOptionalReturnBool(token, approvalCall)) { _callOptionalReturn(token, abi.encodeCall(token.approve, (spender, 0))); _callOptionalReturn(token, approvalCall); } } /** * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement * on the return value: the return value is optional (but if data is returned, it must not be false). * @param token The token targeted by the call. * @param data The call data (encoded using abi.encode or one of its variants). */ function _callOptionalReturn(IERC20 token, bytes memory data) private { // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since // we're implementing it ourselves. We use {Address-functionCall} to perform this call, which verifies that // the target address contains contract code and also asserts for success in the low-level call. bytes memory returndata = address(token).functionCall(data); if (returndata.length != 0 && !abi.decode(returndata, (bool))) { revert SafeERC20FailedOperation(address(token)); } } /** * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement * on the return value: the return value is optional (but if data is returned, it must not be false). * @param token The token targeted by the call. * @param data The call data (encoded using abi.encode or one of its variants). * * This is a variant of {_callOptionalReturn} that silents catches all reverts and returns a bool instead. */ function _callOptionalReturnBool(IERC20 token, bytes memory data) private returns (bool) { // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since // we're implementing it ourselves. We cannot use {Address-functionCall} here since this should return false // and not revert is the subcall reverts. (bool success, bytes memory returndata) = address(token).call(data); return success && (returndata.length == 0 || abi.decode(returndata, (bool))) && address(token).code.length > 0; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/Address.sol) pragma solidity ^0.8.20; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev The ETH balance of the account is not enough to perform the operation. */ error AddressInsufficientBalance(address account); /** * @dev There's no code at `target` (it is not a contract). */ error AddressEmptyCode(address target); /** * @dev A call to an address target failed. The target may have reverted. */ error FailedInnerCall(); /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://consensys.net/diligence/blog/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.8.20/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { if (address(this).balance < amount) { revert AddressInsufficientBalance(address(this)); } (bool success, ) = recipient.call{value: amount}(""); if (!success) { revert FailedInnerCall(); } } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason or custom error, it is bubbled * up by this function (like regular Solidity function calls). However, if * the call reverted with no returned reason, this function reverts with a * {FailedInnerCall} error. * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCallWithValue(target, data, 0); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. */ function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) { if (address(this).balance < value) { revert AddressInsufficientBalance(address(this)); } (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResultFromTarget(target, success, returndata); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResultFromTarget(target, success, returndata); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResultFromTarget(target, success, returndata); } /** * @dev Tool to verify that a low level call to smart-contract was successful, and reverts if the target * was not a contract or bubbling up the revert reason (falling back to {FailedInnerCall}) in case of an * unsuccessful call. */ function verifyCallResultFromTarget( address target, bool success, bytes memory returndata ) internal view returns (bytes memory) { if (!success) { _revert(returndata); } else { // only check if target is a contract if the call was successful and the return data is empty // otherwise we already know that it was a contract if (returndata.length == 0 && target.code.length == 0) { revert AddressEmptyCode(target); } return returndata; } } /** * @dev Tool to verify that a low level call was successful, and reverts if it wasn't, either by bubbling the * revert reason or with a default {FailedInnerCall} error. */ function verifyCallResult(bool success, bytes memory returndata) internal pure returns (bytes memory) { if (!success) { _revert(returndata); } else { return returndata; } } /** * @dev Reverts with returndata if present. Otherwise reverts with {FailedInnerCall}. */ function _revert(bytes memory returndata) private pure { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly /// @solidity memory-safe-assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert FailedInnerCall(); } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.1) (utils/Context.sol) pragma solidity ^0.8.20; /** * @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; } function _contextSuffixLength() internal view virtual returns (uint256) { return 0; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/ReentrancyGuard.sol) pragma solidity ^0.8.20; /** * @dev Contract module that helps prevent reentrant calls to a function. * * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier * available, which can be applied to functions to make sure there are no nested * (reentrant) calls to them. * * Note that because there is a single `nonReentrant` guard, functions marked as * `nonReentrant` may not call one another. This can be worked around by making * those functions `private`, and then adding `external` `nonReentrant` entry * points to them. * * TIP: If you would like to learn more about reentrancy and alternative ways * to protect against it, check out our blog post * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul]. */ abstract contract ReentrancyGuard { // Booleans are more expensive than uint256 or any type that takes up a full // word because each write operation emits an extra SLOAD to first read the // slot's contents, replace the bits taken up by the boolean, and then write // back. This is the compiler's defense against contract upgrades and // pointer aliasing, and it cannot be disabled. // The values being non-zero value makes deployment a bit more expensive, // but in exchange the refund on every call to nonReentrant will be lower in // amount. Since refunds are capped to a percentage of the total // transaction's gas, it is best to keep them low in cases like this one, to // increase the likelihood of the full refund coming into effect. uint256 private constant NOT_ENTERED = 1; uint256 private constant ENTERED = 2; uint256 private _status; /** * @dev Unauthorized reentrant call. */ error ReentrancyGuardReentrantCall(); constructor() { _status = NOT_ENTERED; } /** * @dev Prevents a contract from calling itself, directly or indirectly. * Calling a `nonReentrant` function from another `nonReentrant` * function is not supported. It is possible to prevent this from happening * by making the `nonReentrant` function external, and making it call a * `private` function that does the actual work. */ modifier nonReentrant() { _nonReentrantBefore(); _; _nonReentrantAfter(); } function _nonReentrantBefore() private { // On the first call to nonReentrant, _status will be NOT_ENTERED if (_status == ENTERED) { revert ReentrancyGuardReentrantCall(); } // Any calls to nonReentrant after this point will fail _status = ENTERED; } function _nonReentrantAfter() private { // By storing the original value once again, a refund is triggered (see // https://eips.ethereum.org/EIPS/eip-2200) _status = NOT_ENTERED; } /** * @dev Returns true if the reentrancy guard is currently set to "entered", which indicates there is a * `nonReentrant` function in the call stack. */ function _reentrancyGuardEntered() internal view returns (bool) { return _status == ENTERED; } }
{ "optimizer": { "enabled": true, "runs": 50 }, "evmVersion": "paris", "remappings": [], "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[{"internalType":"address","name":"_feeTo","type":"address"},{"internalType":"address","name":"_feeToSetter","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"target","type":"address"}],"name":"AddressEmptyCode","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"AddressInsufficientBalance","type":"error"},{"inputs":[],"name":"AlreadyClaimed","type":"error"},{"inputs":[],"name":"AmountMustBeGreaterThanZero","type":"error"},{"inputs":[],"name":"FailedInnerCall","type":"error"},{"inputs":[{"internalType":"address","name":"address_","type":"address"}],"name":"InvalidAddress","type":"error"},{"inputs":[],"name":"InvalidLockId","type":"error"},{"inputs":[{"internalType":"uint256","name":"unlockTime","type":"uint256"},{"internalType":"uint256","name":"currentTime","type":"uint256"}],"name":"LockNotExpired","type":"error"},{"inputs":[{"internalType":"address","name":"caller","type":"address"}],"name":"OnlyFeeToSetter","type":"error"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"OwnableInvalidOwner","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"OwnableUnauthorizedAccount","type":"error"},{"inputs":[],"name":"ReentrancyGuardReentrantCall","type":"error"},{"inputs":[{"internalType":"address","name":"token","type":"address"}],"name":"SafeERC20FailedOperation","type":"error"},{"inputs":[],"name":"UnauthorizedLockId","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"lockId","type":"uint256"}],"name":"ClaimUnlockedTokens","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"lockId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"additionalDuration","type":"uint256"}],"name":"ExtendLockDuration","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"lockId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"unlockTime","type":"uint256"}],"name":"LockTokens","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"lockId","type":"uint256"},{"indexed":true,"internalType":"address","name":"oldOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"TransferLockOwnership","type":"event"},{"inputs":[],"name":"EXTEND_LOCK_DURATION_FEE_RATE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"FEE_RATE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"claimAllUnlockedTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_lockId","type":"uint256"}],"name":"claimUnlockedTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_lockId","type":"uint256"},{"internalType":"uint256","name":"_additionalDurationInDays","type":"uint256"}],"name":"extendLockDuration","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"feeTo","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"feeToSetter","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_user","type":"address"}],"name":"getAllLockDetailsForUser","outputs":[{"components":[{"internalType":"contract IERC20","name":"token","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"unlockTime","type":"uint256"},{"internalType":"uint256","name":"totalLockDuration","type":"uint256"},{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"lockId","type":"uint256"},{"internalType":"bool","name":"claimed","type":"bool"}],"internalType":"struct BIFKN314Locker.LockedToken[]","name":"_lockDetails","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_lockId","type":"uint256"}],"name":"getLockDetails","outputs":[{"components":[{"internalType":"contract IERC20","name":"token","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"unlockTime","type":"uint256"},{"internalType":"uint256","name":"totalLockDuration","type":"uint256"},{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"lockId","type":"uint256"},{"internalType":"bool","name":"claimed","type":"bool"}],"internalType":"struct BIFKN314Locker.LockedToken","name":"_lockDetails","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"_token","type":"address"}],"name":"getLockDetailsByToken","outputs":[{"components":[{"internalType":"contract IERC20","name":"token","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"unlockTime","type":"uint256"},{"internalType":"uint256","name":"totalLockDuration","type":"uint256"},{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"lockId","type":"uint256"},{"internalType":"bool","name":"claimed","type":"bool"}],"internalType":"struct BIFKN314Locker.LockedToken[]","name":"_lockDetails","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_user","type":"address"},{"internalType":"contract IERC20","name":"_token","type":"address"}],"name":"getLockDetailsByUserAndToken","outputs":[{"components":[{"internalType":"contract IERC20","name":"token","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"unlockTime","type":"uint256"},{"internalType":"uint256","name":"totalLockDuration","type":"uint256"},{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"lockId","type":"uint256"},{"internalType":"bool","name":"claimed","type":"bool"}],"internalType":"struct BIFKN314Locker.LockedToken[]","name":"_lockDetails","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_user","type":"address"}],"name":"getUserLocks","outputs":[{"internalType":"uint256[]","name":"_lockIDs","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_user","type":"address"}],"name":"getUserLocksCount","outputs":[{"internalType":"uint256","name":"_count","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"lockOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"_token","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"uint256","name":"_daysToLock","type":"uint256"}],"name":"lockTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"lockedTokens","outputs":[{"internalType":"contract IERC20","name":"token","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"unlockTime","type":"uint256"},{"internalType":"uint256","name":"totalLockDuration","type":"uint256"},{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"lockId","type":"uint256"},{"internalType":"bool","name":"claimed","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_feeTo","type":"address"}],"name":"setFeeTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_feeToSetter","type":"address"}],"name":"setFeeToSetter","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_lockId","type":"uint256"},{"internalType":"address","name":"_newOwner","type":"address"}],"name":"transferLockOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"userLockIds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
60806040523480156200001157600080fd5b5060405162001f5938038062001f59833981016040819052620000349162000173565b33806200005c57604051631e4fbdf760e01b8152600060048201526024015b60405180910390fd5b620000678162000106565b50600180556001600160a01b038216620000a057604051634726455360e11b81526001600160a01b038316600482015260240162000053565b6001600160a01b038116620000d457604051634726455360e11b81526001600160a01b038216600482015260240162000053565b600280546001600160a01b039384166001600160a01b03199182161790915560038054929093169116179055620001ab565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b80516001600160a01b03811681146200016e57600080fd5b919050565b600080604083850312156200018757600080fd5b620001928362000156565b9150620001a26020840162000156565b90509250929050565b611d9e80620001bb6000396000f3fe608060405234801561001057600080fd5b506004361061012d5760003560e01c806376704de0116100b357806376704de014610245578063857c5b2e146102585780638da5cb5b1461026b578063a25983e51461027c578063a2e74af61461028f578063a30deb0a146102a2578063b510d8a8146102cb578063dcec3294146102de578063f2fde38b14610338578063f46901ed1461034b578063fe9661701461035e578063ff6698791461036657600080fd5b8063017e7e5814610132578063094b74151461015b578063182186eb1461016e57806323a35de9146101835780632d11c58a146101a35780634d6b39fe146101b95780635a04fb69146101c15780635b15bfd9146101d45780636988e642146101f45780636c212fe21461021d578063715018a61461023d575b600080fd5b600254610145906001600160a01b031681565b6040516101529190611a21565b60405180910390f35b600354610145906001600160a01b031681565b61018161017c366004611a35565b610379565b005b610196610191366004611a63565b61052c565b6040516101529190611a80565b6101ab606481565b604051908152602001610152565b610181610598565b6101816101cf366004611ac4565b610723565b6101e76101e2366004611a35565b61097d565b6040516101529190611b46565b6101ab610202366004611a63565b6001600160a01b031660009081526005602052604090205490565b61023061022b366004611a63565b610a13565b6040516101529190611b54565b610181610bf4565b610181610253366004611b96565b610c06565b610230610266366004611a63565b610e2f565b6000546001600160a01b0316610145565b61018161028a366004611bb8565b610fd9565b61018161029d366004611a63565b6112b5565b6101456102b0366004611a35565b6004602052600090815260409020546001600160a01b031681565b6102306102d9366004611bed565b611337565b6102f16102ec366004611a35565b6115cd565b604080516001600160a01b03988916815260208101979097528601949094526060850192909252909316608083015260a082019290925290151560c082015260e001610152565b610181610346366004611a63565b61162b565b610181610359366004611a63565b611666565b6101ab603281565b6101ab610374366004611c1b565b6116d2565b610381611703565b600654339082106103a55760405163aefe60c360e01b815260040160405180910390fd5b6000828152600460205260409020546001600160a01b038281169116146103df57604051639ea46bef60e01b815260040160405180910390fd5b600682815481106103f2576103f2611c47565b600091825260209091206006600790920201015460ff161561042757604051630c8d9eab60e31b815260040160405180910390fd5b60006006838154811061043c5761043c611c47565b90600052602060002090600702019050806002015442101561048557600281015460405163180be00360e01b815260048101919091524260248201526044015b60405180910390fd5b8060020154421061051e57600083815260046020526040902080546001600160a01b031916905560068101805460ff1916600190811790915581015481546104da916001600160a01b0390911690849061172d565b816001600160a01b03167f3e21f6abddff08d997ffb76b887af2a562420eea453d925cb74f8a970677d13f8460405161051591815260200190565b60405180910390a25b505061052960018055565b50565b6001600160a01b03811660009081526005602090815260409182902080548351818402810184019094528084526060939283018282801561058c57602002820191906000526020600020905b815481526020019060010190808311610578575b50505050509050919050565b6105a0611703565b336000818152600560209081526040808320805482518185028101850190935280835291929091908301828280156105f757602002820191906000526020600020905b8154815260200190600101908083116105e3575b505083519394506000925050505b8181101561071457600083828151811061062157610621611c47565b6020026020010151905060006006828154811061064057610640611c47565b60009182526020909120600790910201600681015490915060ff1615801561066c575080600201544210155b156106ff57600082815260046020526040902080546001600160a01b031916905560068101805460ff1916600190811790915581015481546106bb916001600160a01b0390911690889061172d565b856001600160a01b03167f3e21f6abddff08d997ffb76b887af2a562420eea453d925cb74f8a970677d13f836040516106f691815260200190565b60405180910390a25b5050808061070c90611c73565b915050610605565b5050505061072160018055565b565b61072b611703565b6001600160a01b0381166107545780604051634726455360e11b815260040161047c9190611a21565b336001600160a01b0382160361077f5780604051634726455360e11b815260040161047c9190611a21565b600654339083106107a35760405163aefe60c360e01b815260040160405180910390fd5b6000838152600460205260409020546001600160a01b038281169116146107dd57604051639ea46bef60e01b815260040160405180910390fd5b600683815481106107f0576107f0611c47565b600091825260209091206006600790920201015460ff161561082557604051630c8d9eab60e31b815260040160405180910390fd5b600083815260046020908152604080832080546001600160a01b0319166001600160a01b03878116918217909255845260058352818420805460018101825590855292842090920186905590831682528120805490915b8181101561092b578583828154811061089757610897611c47565b90600052602060002001540361091957826108b3600184611c8c565b815481106108c3576108c3611c47565b90600052602060002001548382815481106108e0576108e0611c47565b9060005260206000200181905550828054806108fe576108fe611c9f565b6001900381819060005260206000200160009055905561092b565b8061092381611c73565b91505061087c565b50836001600160a01b0316836001600160a01b0316867fd954f819e7486faa3bb7526c0ab88212ed887f29596295975edcde17216d872660405160405180910390a450505061097960018055565b5050565b6109856119d0565b6006828154811061099857610998611c47565b60009182526020918290206040805160e081018252600790930290910180546001600160a01b0390811684526001820154948401949094526002810154918301919091526003810154606083015260048101549092166080820152600582015460a082015260069091015460ff16151560c082015292915050565b6006546060906000805b82811015610a8157846001600160a01b031660068281548110610a4257610a42611c47565b60009182526020909120600790910201546001600160a01b031603610a6f5781610a6b81611c73565b9250505b80610a7981611c73565b915050610a1d565b5060008167ffffffffffffffff811115610a9d57610a9d611cb5565b604051908082528060200260200182016040528015610ad657816020015b610ac36119d0565b815260200190600190039081610abb5790505b5090506000805b84811015610be957866001600160a01b031660068281548110610b0257610b02611c47565b60009182526020909120600790910201546001600160a01b031603610bd75760068181548110610b3457610b34611c47565b60009182526020918290206040805160e081018252600790930290910180546001600160a01b0390811684526001820154948401949094526002810154918301919091526003810154606083015260048101549092166080820152600582015460a082015260069091015460ff16151560c08201528351849084908110610bbd57610bbd611c47565b60200260200101819052508180610bd390611c73565b9250505b80610be181611c73565b915050610add565b509095945050505050565b610bfc61178c565b61072160006117b9565b610c0e611703565b80600003610c2f57604051635e85ae7360e01b815260040160405180910390fd5b60065433908310610c535760405163aefe60c360e01b815260040160405180910390fd5b6000838152600460205260409020546001600160a01b03828116911614610c8d57604051639ea46bef60e01b815260040160405180910390fd5b60068381548110610ca057610ca0611c47565b600091825260209091206006600790920201015460ff1615610cd557604051630c8d9eab60e31b815260040160405180910390fd5b600060068481548110610cea57610cea611c47565b90600052602060002090600702019050600061271060328360010154610d109190611ccb565b610d1a9190611ce2565b905081600201544210610d6957610d348462015180611ccb565b610d3e9042611d04565b6002830155600182015461271090610d5890606490611ccb565b610d629190611ce2565b9050610d8f565b610d768462015180611ccb565b826002016000828254610d899190611d04565b90915550505b83826003016000828254610da39190611d04565b9250508190555080826001016000828254610dbe9190611c8c565b90915550506002548254610ddf916001600160a01b0391821691168361172d565b60408051868152602081018690526001600160a01b038516917ffb824d2fc963ca6109a9e449775566d249d764f508433034bc2787043037ab9f910160405180910390a250505061097960018055565b6001600160a01b0381166000908152600560209081526040808320805482518185028101850190935280835260609493830182828015610e8e57602002820191906000526020600020905b815481526020019060010190808311610e7a575b5050505050905060008151905060008167ffffffffffffffff811115610eb657610eb6611cb5565b604051908082528060200260200182016040528015610eef57816020015b610edc6119d0565b815260200190600190039081610ed45790505b50905060005b82811015610fd0576006848281518110610f1157610f11611c47565b602002602001015181548110610f2957610f29611c47565b60009182526020918290206040805160e081018252600790930290910180546001600160a01b0390811684526001820154948401949094526002810154918301919091526003810154606083015260048101549092166080820152600582015460a082015260069091015460ff16151560c08201528251839083908110610fb257610fb2611c47565b60200260200101819052508080610fc890611c73565b915050610ef5565b50949350505050565b610fe1611703565b8160000361100257604051635e85ae7360e01b815260040160405180910390fd5b8060000361102357604051635e85ae7360e01b815260040160405180910390fd5b3360006110338362015180611ccb565b61103d9042611d04565b9050600061271061104f606487611ccb565b6110599190611ce2565b905060006110678287611c8c565b90506000600680549050905060006040518060e001604052808a6001600160a01b03168152602001848152602001868152602001888152602001876001600160a01b03168152602001838152602001600015158152509050600681908060018154018082558091505060019003906000526020600020906007020160009091909190915060008201518160000160006101000a8154816001600160a01b0302191690836001600160a01b0316021790555060208201518160010155604082015181600201556060820151816003015560808201518160040160006101000a8154816001600160a01b0302191690836001600160a01b0316021790555060a0820151816005015560c08201518160060160006101000a81548160ff021916908315150217905550505060056000876001600160a01b03166001600160a01b03168152602001908152602001600020829080600181540180825580915050600190039060005260206000200160009091909190915055856004600084815260200190815260200160002060006101000a8154816001600160a01b0302191690836001600160a01b0316021790555061124886600260009054906101000a90046001600160a01b0316868c6001600160a01b0316611809909392919063ffffffff16565b61125d6001600160a01b038a16873086611809565b60408051838152602081018790526001600160a01b038816917f41eab929219e7bf8200f418241826f3ff85ad5654cb2f297e300058ebb07f4a1910160405180910390a25050505050506112b060018055565b505050565b6003546001600160a01b0316336001600160a01b0316146112ec57335b604051639dae072d60e01b815260040161047c9190611a21565b6001600160a01b0381166113155780604051634726455360e11b815260040161047c9190611a21565b600380546001600160a01b0319166001600160a01b0392909216919091179055565b6001600160a01b038216600090815260056020908152604080832080548251818502810185019093528083526060949383018282801561139657602002820191906000526020600020905b815481526020019060010190808311611382575b505050505090506000808251905060005b8181101561142457856001600160a01b031660068583815181106113cd576113cd611c47565b6020026020010151815481106113e5576113e5611c47565b60009182526020909120600790910201546001600160a01b031603611412578261140e81611c73565b9350505b8061141c81611c73565b9150506113a7565b5060008267ffffffffffffffff81111561144057611440611cb5565b60405190808252806020026020018201604052801561147957816020015b6114666119d0565b81526020019060019003908161145e5790505b5090506000805b838110156115be57876001600160a01b031660068783815181106114a6576114a6611c47565b6020026020010151815481106114be576114be611c47565b60009182526020909120600790910201546001600160a01b0316036115ac5760068682815181106114f1576114f1611c47565b60200260200101518154811061150957611509611c47565b60009182526020918290206040805160e081018252600790930290910180546001600160a01b0390811684526001820154948401949094526002810154918301919091526003810154606083015260048101549092166080820152600582015460a082015260069091015460ff16151560c0820152835184908490811061159257611592611c47565b602002602001018190525081806115a890611c73565b9250505b806115b681611c73565b915050611480565b50909450505050505b92915050565b600681815481106115dd57600080fd5b600091825260209091206007909102018054600182015460028301546003840154600485015460058601546006909601546001600160a01b0395861697509395929491939116919060ff1687565b61163361178c565b6001600160a01b03811661165d576000604051631e4fbdf760e01b815260040161047c9190611a21565b610529816117b9565b6003546001600160a01b0316336001600160a01b03161461168757336112d2565b6001600160a01b0381166116b05780604051634726455360e11b815260040161047c9190611a21565b600280546001600160a01b0319166001600160a01b0392909216919091179055565b600560205281600052604060002081815481106116ee57600080fd5b90600052602060002001600091509150505481565b60026001540361172657604051633ee5aeb560e01b815260040160405180910390fd5b6002600155565b6040516001600160a01b038381166024830152604482018390526112b091859182169063a9059cbb906064015b604051602081830303815290604052915060e01b6020820180516001600160e01b038381831617835250505050611848565b6000546001600160a01b03163314610721573360405163118cdaa760e01b815260040161047c9190611a21565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6040516001600160a01b0384811660248301528381166044830152606482018390526118429186918216906323b872dd9060840161175a565b50505050565b600061185d6001600160a01b038416836118a2565b905080516000141580156118825750808060200190518101906118809190611d17565b155b156112b05782604051635274afe760e01b815260040161047c9190611a21565b60606118b0838360006118b7565b9392505050565b6060814710156118dc573060405163cd78605960e01b815260040161047c9190611a21565b600080856001600160a01b031684866040516118f89190611d39565b60006040518083038185875af1925050503d8060008114611935576040519150601f19603f3d011682016040523d82523d6000602084013e61193a565b606091505b509150915061194a868383611954565b9695505050505050565b60608261196957611964826119a7565b6118b0565b815115801561198057506001600160a01b0384163b155b156119a05783604051639996b31560e01b815260040161047c9190611a21565b50806118b0565b8051156119b75780518082602001fd5b604051630a12f52160e11b815260040160405180910390fd5b6040518060e0016040528060006001600160a01b0316815260200160008152602001600081526020016000815260200160006001600160a01b03168152602001600081526020016000151581525090565b6001600160a01b0391909116815260200190565b600060208284031215611a4757600080fd5b5035919050565b6001600160a01b038116811461052957600080fd5b600060208284031215611a7557600080fd5b81356118b081611a4e565b6020808252825182820181905260009190848201906040850190845b81811015611ab857835183529284019291840191600101611a9c565b50909695505050505050565b60008060408385031215611ad757600080fd5b823591506020830135611ae981611a4e565b809150509250929050565b60018060a01b038082511683526020820151602084015260408201516040840152606082015160608401528060808301511660808401525060a081015160a083015260c0810151151560c08301525050565b60e081016115c78284611af4565b6020808252825182820181905260009190848201906040850190845b81811015611ab857611b83838551611af4565b9284019260e09290920191600101611b70565b60008060408385031215611ba957600080fd5b50508035926020909101359150565b600080600060608486031215611bcd57600080fd5b8335611bd881611a4e565b95602085013595506040909401359392505050565b60008060408385031215611c0057600080fd5b8235611c0b81611a4e565b91506020830135611ae981611a4e565b60008060408385031215611c2e57600080fd5b8235611c3981611a4e565b946020939093013593505050565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b600060018201611c8557611c85611c5d565b5060010190565b818103818111156115c7576115c7611c5d565b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052604160045260246000fd5b80820281158282048414176115c7576115c7611c5d565b600082611cff57634e487b7160e01b600052601260045260246000fd5b500490565b808201808211156115c7576115c7611c5d565b600060208284031215611d2957600080fd5b815180151581146118b057600080fd5b6000825160005b81811015611d5a5760208186018101518583015201611d40565b50600092019182525091905056fea26469706673582212206303da458ff1f59d346fb88a0b64ea3b08d6e85c708a7cbc6cc0c0fa1dcc472d64736f6c6343000814003300000000000000000000000078d4bc2aaac565e7b96ab6607563a1403e508b490000000000000000000000005568938bf4188bb868dbf31614091062c4a44b1e
Deployed Bytecode
0x608060405234801561001057600080fd5b506004361061012d5760003560e01c806376704de0116100b357806376704de014610245578063857c5b2e146102585780638da5cb5b1461026b578063a25983e51461027c578063a2e74af61461028f578063a30deb0a146102a2578063b510d8a8146102cb578063dcec3294146102de578063f2fde38b14610338578063f46901ed1461034b578063fe9661701461035e578063ff6698791461036657600080fd5b8063017e7e5814610132578063094b74151461015b578063182186eb1461016e57806323a35de9146101835780632d11c58a146101a35780634d6b39fe146101b95780635a04fb69146101c15780635b15bfd9146101d45780636988e642146101f45780636c212fe21461021d578063715018a61461023d575b600080fd5b600254610145906001600160a01b031681565b6040516101529190611a21565b60405180910390f35b600354610145906001600160a01b031681565b61018161017c366004611a35565b610379565b005b610196610191366004611a63565b61052c565b6040516101529190611a80565b6101ab606481565b604051908152602001610152565b610181610598565b6101816101cf366004611ac4565b610723565b6101e76101e2366004611a35565b61097d565b6040516101529190611b46565b6101ab610202366004611a63565b6001600160a01b031660009081526005602052604090205490565b61023061022b366004611a63565b610a13565b6040516101529190611b54565b610181610bf4565b610181610253366004611b96565b610c06565b610230610266366004611a63565b610e2f565b6000546001600160a01b0316610145565b61018161028a366004611bb8565b610fd9565b61018161029d366004611a63565b6112b5565b6101456102b0366004611a35565b6004602052600090815260409020546001600160a01b031681565b6102306102d9366004611bed565b611337565b6102f16102ec366004611a35565b6115cd565b604080516001600160a01b03988916815260208101979097528601949094526060850192909252909316608083015260a082019290925290151560c082015260e001610152565b610181610346366004611a63565b61162b565b610181610359366004611a63565b611666565b6101ab603281565b6101ab610374366004611c1b565b6116d2565b610381611703565b600654339082106103a55760405163aefe60c360e01b815260040160405180910390fd5b6000828152600460205260409020546001600160a01b038281169116146103df57604051639ea46bef60e01b815260040160405180910390fd5b600682815481106103f2576103f2611c47565b600091825260209091206006600790920201015460ff161561042757604051630c8d9eab60e31b815260040160405180910390fd5b60006006838154811061043c5761043c611c47565b90600052602060002090600702019050806002015442101561048557600281015460405163180be00360e01b815260048101919091524260248201526044015b60405180910390fd5b8060020154421061051e57600083815260046020526040902080546001600160a01b031916905560068101805460ff1916600190811790915581015481546104da916001600160a01b0390911690849061172d565b816001600160a01b03167f3e21f6abddff08d997ffb76b887af2a562420eea453d925cb74f8a970677d13f8460405161051591815260200190565b60405180910390a25b505061052960018055565b50565b6001600160a01b03811660009081526005602090815260409182902080548351818402810184019094528084526060939283018282801561058c57602002820191906000526020600020905b815481526020019060010190808311610578575b50505050509050919050565b6105a0611703565b336000818152600560209081526040808320805482518185028101850190935280835291929091908301828280156105f757602002820191906000526020600020905b8154815260200190600101908083116105e3575b505083519394506000925050505b8181101561071457600083828151811061062157610621611c47565b6020026020010151905060006006828154811061064057610640611c47565b60009182526020909120600790910201600681015490915060ff1615801561066c575080600201544210155b156106ff57600082815260046020526040902080546001600160a01b031916905560068101805460ff1916600190811790915581015481546106bb916001600160a01b0390911690889061172d565b856001600160a01b03167f3e21f6abddff08d997ffb76b887af2a562420eea453d925cb74f8a970677d13f836040516106f691815260200190565b60405180910390a25b5050808061070c90611c73565b915050610605565b5050505061072160018055565b565b61072b611703565b6001600160a01b0381166107545780604051634726455360e11b815260040161047c9190611a21565b336001600160a01b0382160361077f5780604051634726455360e11b815260040161047c9190611a21565b600654339083106107a35760405163aefe60c360e01b815260040160405180910390fd5b6000838152600460205260409020546001600160a01b038281169116146107dd57604051639ea46bef60e01b815260040160405180910390fd5b600683815481106107f0576107f0611c47565b600091825260209091206006600790920201015460ff161561082557604051630c8d9eab60e31b815260040160405180910390fd5b600083815260046020908152604080832080546001600160a01b0319166001600160a01b03878116918217909255845260058352818420805460018101825590855292842090920186905590831682528120805490915b8181101561092b578583828154811061089757610897611c47565b90600052602060002001540361091957826108b3600184611c8c565b815481106108c3576108c3611c47565b90600052602060002001548382815481106108e0576108e0611c47565b9060005260206000200181905550828054806108fe576108fe611c9f565b6001900381819060005260206000200160009055905561092b565b8061092381611c73565b91505061087c565b50836001600160a01b0316836001600160a01b0316867fd954f819e7486faa3bb7526c0ab88212ed887f29596295975edcde17216d872660405160405180910390a450505061097960018055565b5050565b6109856119d0565b6006828154811061099857610998611c47565b60009182526020918290206040805160e081018252600790930290910180546001600160a01b0390811684526001820154948401949094526002810154918301919091526003810154606083015260048101549092166080820152600582015460a082015260069091015460ff16151560c082015292915050565b6006546060906000805b82811015610a8157846001600160a01b031660068281548110610a4257610a42611c47565b60009182526020909120600790910201546001600160a01b031603610a6f5781610a6b81611c73565b9250505b80610a7981611c73565b915050610a1d565b5060008167ffffffffffffffff811115610a9d57610a9d611cb5565b604051908082528060200260200182016040528015610ad657816020015b610ac36119d0565b815260200190600190039081610abb5790505b5090506000805b84811015610be957866001600160a01b031660068281548110610b0257610b02611c47565b60009182526020909120600790910201546001600160a01b031603610bd75760068181548110610b3457610b34611c47565b60009182526020918290206040805160e081018252600790930290910180546001600160a01b0390811684526001820154948401949094526002810154918301919091526003810154606083015260048101549092166080820152600582015460a082015260069091015460ff16151560c08201528351849084908110610bbd57610bbd611c47565b60200260200101819052508180610bd390611c73565b9250505b80610be181611c73565b915050610add565b509095945050505050565b610bfc61178c565b61072160006117b9565b610c0e611703565b80600003610c2f57604051635e85ae7360e01b815260040160405180910390fd5b60065433908310610c535760405163aefe60c360e01b815260040160405180910390fd5b6000838152600460205260409020546001600160a01b03828116911614610c8d57604051639ea46bef60e01b815260040160405180910390fd5b60068381548110610ca057610ca0611c47565b600091825260209091206006600790920201015460ff1615610cd557604051630c8d9eab60e31b815260040160405180910390fd5b600060068481548110610cea57610cea611c47565b90600052602060002090600702019050600061271060328360010154610d109190611ccb565b610d1a9190611ce2565b905081600201544210610d6957610d348462015180611ccb565b610d3e9042611d04565b6002830155600182015461271090610d5890606490611ccb565b610d629190611ce2565b9050610d8f565b610d768462015180611ccb565b826002016000828254610d899190611d04565b90915550505b83826003016000828254610da39190611d04565b9250508190555080826001016000828254610dbe9190611c8c565b90915550506002548254610ddf916001600160a01b0391821691168361172d565b60408051868152602081018690526001600160a01b038516917ffb824d2fc963ca6109a9e449775566d249d764f508433034bc2787043037ab9f910160405180910390a250505061097960018055565b6001600160a01b0381166000908152600560209081526040808320805482518185028101850190935280835260609493830182828015610e8e57602002820191906000526020600020905b815481526020019060010190808311610e7a575b5050505050905060008151905060008167ffffffffffffffff811115610eb657610eb6611cb5565b604051908082528060200260200182016040528015610eef57816020015b610edc6119d0565b815260200190600190039081610ed45790505b50905060005b82811015610fd0576006848281518110610f1157610f11611c47565b602002602001015181548110610f2957610f29611c47565b60009182526020918290206040805160e081018252600790930290910180546001600160a01b0390811684526001820154948401949094526002810154918301919091526003810154606083015260048101549092166080820152600582015460a082015260069091015460ff16151560c08201528251839083908110610fb257610fb2611c47565b60200260200101819052508080610fc890611c73565b915050610ef5565b50949350505050565b610fe1611703565b8160000361100257604051635e85ae7360e01b815260040160405180910390fd5b8060000361102357604051635e85ae7360e01b815260040160405180910390fd5b3360006110338362015180611ccb565b61103d9042611d04565b9050600061271061104f606487611ccb565b6110599190611ce2565b905060006110678287611c8c565b90506000600680549050905060006040518060e001604052808a6001600160a01b03168152602001848152602001868152602001888152602001876001600160a01b03168152602001838152602001600015158152509050600681908060018154018082558091505060019003906000526020600020906007020160009091909190915060008201518160000160006101000a8154816001600160a01b0302191690836001600160a01b0316021790555060208201518160010155604082015181600201556060820151816003015560808201518160040160006101000a8154816001600160a01b0302191690836001600160a01b0316021790555060a0820151816005015560c08201518160060160006101000a81548160ff021916908315150217905550505060056000876001600160a01b03166001600160a01b03168152602001908152602001600020829080600181540180825580915050600190039060005260206000200160009091909190915055856004600084815260200190815260200160002060006101000a8154816001600160a01b0302191690836001600160a01b0316021790555061124886600260009054906101000a90046001600160a01b0316868c6001600160a01b0316611809909392919063ffffffff16565b61125d6001600160a01b038a16873086611809565b60408051838152602081018790526001600160a01b038816917f41eab929219e7bf8200f418241826f3ff85ad5654cb2f297e300058ebb07f4a1910160405180910390a25050505050506112b060018055565b505050565b6003546001600160a01b0316336001600160a01b0316146112ec57335b604051639dae072d60e01b815260040161047c9190611a21565b6001600160a01b0381166113155780604051634726455360e11b815260040161047c9190611a21565b600380546001600160a01b0319166001600160a01b0392909216919091179055565b6001600160a01b038216600090815260056020908152604080832080548251818502810185019093528083526060949383018282801561139657602002820191906000526020600020905b815481526020019060010190808311611382575b505050505090506000808251905060005b8181101561142457856001600160a01b031660068583815181106113cd576113cd611c47565b6020026020010151815481106113e5576113e5611c47565b60009182526020909120600790910201546001600160a01b031603611412578261140e81611c73565b9350505b8061141c81611c73565b9150506113a7565b5060008267ffffffffffffffff81111561144057611440611cb5565b60405190808252806020026020018201604052801561147957816020015b6114666119d0565b81526020019060019003908161145e5790505b5090506000805b838110156115be57876001600160a01b031660068783815181106114a6576114a6611c47565b6020026020010151815481106114be576114be611c47565b60009182526020909120600790910201546001600160a01b0316036115ac5760068682815181106114f1576114f1611c47565b60200260200101518154811061150957611509611c47565b60009182526020918290206040805160e081018252600790930290910180546001600160a01b0390811684526001820154948401949094526002810154918301919091526003810154606083015260048101549092166080820152600582015460a082015260069091015460ff16151560c0820152835184908490811061159257611592611c47565b602002602001018190525081806115a890611c73565b9250505b806115b681611c73565b915050611480565b50909450505050505b92915050565b600681815481106115dd57600080fd5b600091825260209091206007909102018054600182015460028301546003840154600485015460058601546006909601546001600160a01b0395861697509395929491939116919060ff1687565b61163361178c565b6001600160a01b03811661165d576000604051631e4fbdf760e01b815260040161047c9190611a21565b610529816117b9565b6003546001600160a01b0316336001600160a01b03161461168757336112d2565b6001600160a01b0381166116b05780604051634726455360e11b815260040161047c9190611a21565b600280546001600160a01b0319166001600160a01b0392909216919091179055565b600560205281600052604060002081815481106116ee57600080fd5b90600052602060002001600091509150505481565b60026001540361172657604051633ee5aeb560e01b815260040160405180910390fd5b6002600155565b6040516001600160a01b038381166024830152604482018390526112b091859182169063a9059cbb906064015b604051602081830303815290604052915060e01b6020820180516001600160e01b038381831617835250505050611848565b6000546001600160a01b03163314610721573360405163118cdaa760e01b815260040161047c9190611a21565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6040516001600160a01b0384811660248301528381166044830152606482018390526118429186918216906323b872dd9060840161175a565b50505050565b600061185d6001600160a01b038416836118a2565b905080516000141580156118825750808060200190518101906118809190611d17565b155b156112b05782604051635274afe760e01b815260040161047c9190611a21565b60606118b0838360006118b7565b9392505050565b6060814710156118dc573060405163cd78605960e01b815260040161047c9190611a21565b600080856001600160a01b031684866040516118f89190611d39565b60006040518083038185875af1925050503d8060008114611935576040519150601f19603f3d011682016040523d82523d6000602084013e61193a565b606091505b509150915061194a868383611954565b9695505050505050565b60608261196957611964826119a7565b6118b0565b815115801561198057506001600160a01b0384163b155b156119a05783604051639996b31560e01b815260040161047c9190611a21565b50806118b0565b8051156119b75780518082602001fd5b604051630a12f52160e11b815260040160405180910390fd5b6040518060e0016040528060006001600160a01b0316815260200160008152602001600081526020016000815260200160006001600160a01b03168152602001600081526020016000151581525090565b6001600160a01b0391909116815260200190565b600060208284031215611a4757600080fd5b5035919050565b6001600160a01b038116811461052957600080fd5b600060208284031215611a7557600080fd5b81356118b081611a4e565b6020808252825182820181905260009190848201906040850190845b81811015611ab857835183529284019291840191600101611a9c565b50909695505050505050565b60008060408385031215611ad757600080fd5b823591506020830135611ae981611a4e565b809150509250929050565b60018060a01b038082511683526020820151602084015260408201516040840152606082015160608401528060808301511660808401525060a081015160a083015260c0810151151560c08301525050565b60e081016115c78284611af4565b6020808252825182820181905260009190848201906040850190845b81811015611ab857611b83838551611af4565b9284019260e09290920191600101611b70565b60008060408385031215611ba957600080fd5b50508035926020909101359150565b600080600060608486031215611bcd57600080fd5b8335611bd881611a4e565b95602085013595506040909401359392505050565b60008060408385031215611c0057600080fd5b8235611c0b81611a4e565b91506020830135611ae981611a4e565b60008060408385031215611c2e57600080fd5b8235611c3981611a4e565b946020939093013593505050565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b600060018201611c8557611c85611c5d565b5060010190565b818103818111156115c7576115c7611c5d565b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052604160045260246000fd5b80820281158282048414176115c7576115c7611c5d565b600082611cff57634e487b7160e01b600052601260045260246000fd5b500490565b808201808211156115c7576115c7611c5d565b600060208284031215611d2957600080fd5b815180151581146118b057600080fd5b6000825160005b81811015611d5a5760208186018101518583015201611d40565b50600092019182525091905056fea26469706673582212206303da458ff1f59d346fb88a0b64ea3b08d6e85c708a7cbc6cc0c0fa1dcc472d64736f6c63430008140033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
00000000000000000000000078d4bc2aaac565e7b96ab6607563a1403e508b490000000000000000000000005568938bf4188bb868dbf31614091062c4a44b1e
-----Decoded View---------------
Arg [0] : _feeTo (address): 0x78D4BC2aaaC565E7b96aB6607563a1403e508B49
Arg [1] : _feeToSetter (address): 0x5568938Bf4188Bb868Dbf31614091062C4a44B1E
-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 00000000000000000000000078d4bc2aaac565e7b96ab6607563a1403e508b49
Arg [1] : 0000000000000000000000005568938bf4188bb868dbf31614091062c4a44b1e
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 35 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
Loading...
Loading
Loading...
Loading
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.