Source Code
Overview
ETH Balance
0 ETH
Eth Value
$0.00View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Loading...
Loading
Cross-Chain Transactions
Loading...
Loading
This contract may be a proxy contract. Click on More Options and select Is this a proxy? to confirm and enable the "Read as Proxy" & "Write as Proxy" tabs.
Contract Name:
Vesting
Compiler Version
v0.8.28+commit.7893614a
Optimization Enabled:
No with 200 runs
Other Settings:
prague EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.24;
import {UUPSUpgradeable} from "@openzeppelin/contracts/proxy/utils/UUPSUpgradeable.sol";
import {Initializable} from "@openzeppelin/contracts/proxy/utils/Initializable.sol";
import {IERC20} from "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import {SafeERC20} from "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol";
import {VestingStorage} from "./VestingStorage.sol";
contract Vesting is Initializable, UUPSUpgradeable {
using VestingStorage for VestingStorage.Layout;
using SafeERC20 for IERC20;
uint256 public constant OWNER_RESTRICTION_PERIOD = 180 days;
event PrimaryOwnerChanged(address indexed oldOwner, address indexed newOwner);
event SecondaryOwnerChanged(address indexed oldOwner, address indexed newOwner);
event StartTimeChanged(uint256 oldStartTime, uint256 newStartTime);
event TokenChanged(address indexed oldToken, address indexed newToken);
event LockedAmountChanged(uint256 oldAmount, uint256 newAmount);
event UnlockSchedulesChanged();
event EmergencyWithdraw(address indexed to, uint256 amount);
event Withdraw(address indexed to, uint256 amount);
error InvalidUnlockSchedule();
error Unauthorized();
error InvalidAddress();
error InvalidNumber();
error InsufficientBalance();
error NoUnlockAvailable();
constructor() {
_disableInitializers();
}
function initialize(
address _primaryOwner,
address _secondaryOwner,
uint256 _startTime,
address _token,
uint256 _lockedAmount,
VestingStorage.UnlockSchedule[] memory _unlockSchedules
) public initializer {
if (_primaryOwner == address(0)) {
revert InvalidAddress();
}
if (_startTime == 0) revert InvalidNumber();
if (_token == address(0)) revert InvalidAddress();
if (_lockedAmount == 0) revert InvalidNumber();
VestingStorage.Layout storage s = VestingStorage.layout();
s.primaryOwner = _primaryOwner;
s.secondaryOwner = _secondaryOwner;
s.startTime = _startTime;
s.token = _token;
s.lockedAmount = _lockedAmount;
_validateUnlockSchedules(_startTime, _lockedAmount, _unlockSchedules);
_setUnlockSchedules(_unlockSchedules);
}
modifier onlyAuthorized() {
_onlyAuthorized();
_;
}
modifier onlyPrimaryOwner() {
_onlyPrimaryOwner();
_;
}
modifier onlySecondaryOwner() {
_onlySecondaryOwner();
_;
}
function _onlyAuthorized() internal view {
VestingStorage.Layout storage s = VestingStorage.layout();
if (msg.sender != s.primaryOwner && msg.sender != s.secondaryOwner) {
revert Unauthorized();
}
if (block.timestamp < s.startTime + OWNER_RESTRICTION_PERIOD) {
if (msg.sender != s.primaryOwner) {
revert Unauthorized();
}
}
}
function _onlyPrimaryOwner() internal view {
VestingStorage.Layout storage s = VestingStorage.layout();
if (msg.sender != s.primaryOwner) {
revert Unauthorized();
}
}
function _onlySecondaryOwner() internal view {
VestingStorage.Layout storage s = VestingStorage.layout();
if (msg.sender != s.secondaryOwner) {
revert Unauthorized();
}
}
function _validateUnlockSchedules(
uint256 _startTime,
uint256 _lockedAmount,
VestingStorage.UnlockSchedule[] memory _unlockSchedules
) internal pure {
if (_unlockSchedules.length == 0) revert InvalidUnlockSchedule();
if (_unlockSchedules[0].timestamp <= _startTime) {
revert InvalidUnlockSchedule();
}
for (uint256 i = 1; i < _unlockSchedules.length; i++) {
if (_unlockSchedules[i].timestamp <= _unlockSchedules[i - 1].timestamp) {
revert InvalidUnlockSchedule();
}
if (_unlockSchedules[i].amount <= _unlockSchedules[i - 1].amount) {
revert InvalidUnlockSchedule();
}
}
if (_unlockSchedules[_unlockSchedules.length - 1].amount != _lockedAmount) {
revert InvalidUnlockSchedule();
}
}
function _setUnlockSchedules(VestingStorage.UnlockSchedule[] memory _unlockSchedules) internal {
VestingStorage.Layout storage s = VestingStorage.layout();
delete s.unlockSchedules;
for (uint256 i = 0; i < _unlockSchedules.length; i++) {
s.unlockSchedules.push(_unlockSchedules[i]);
}
}
function _convertToMemoryArray(VestingStorage.UnlockSchedule[] storage _storageArray)
internal
view
returns (VestingStorage.UnlockSchedule[] memory)
{
VestingStorage.UnlockSchedule[] memory memoryArray = new VestingStorage.UnlockSchedule[](_storageArray.length);
for (uint256 i = 0; i < _storageArray.length; i++) {
memoryArray[i] = _storageArray[i];
}
return memoryArray;
}
function primaryOwner() public view returns (address) {
return VestingStorage.layout().primaryOwner;
}
function secondaryOwner() public view returns (address) {
return VestingStorage.layout().secondaryOwner;
}
function startTime() public view returns (uint256) {
return VestingStorage.layout().startTime;
}
function token() public view returns (address) {
return VestingStorage.layout().token;
}
function lockedAmount() public view returns (uint256) {
return VestingStorage.layout().lockedAmount;
}
function withdrawnAmount() public view returns (uint256) {
return VestingStorage.layout().withdrawnAmount;
}
function getUnlockSchedulesCount() public view returns (uint256) {
return VestingStorage.layout().unlockSchedules.length;
}
function getUnlockSchedule(uint256 index) public view returns (uint256 timestamp, uint256 amount) {
VestingStorage.Layout storage s = VestingStorage.layout();
require(index < s.unlockSchedules.length, "Index out of bounds");
return (s.unlockSchedules[index].timestamp, s.unlockSchedules[index].amount);
}
function getUnlockSchedules() public view returns (VestingStorage.UnlockSchedule[] memory) {
return _convertToMemoryArray(VestingStorage.layout().unlockSchedules);
}
function getAvailableAmount() public view returns (uint256) {
VestingStorage.Layout storage s = VestingStorage.layout();
if (block.timestamp < s.startTime) {
return 0;
}
uint256 available = 0;
for (uint256 i = 0; i < s.unlockSchedules.length; i++) {
if (block.timestamp >= s.unlockSchedules[i].timestamp) {
available = s.unlockSchedules[i].amount;
}
}
return available > s.withdrawnAmount ? available - s.withdrawnAmount : 0;
}
function setPrimaryOwner(address _newPrimaryOwner) public onlyPrimaryOwner {
if (_newPrimaryOwner == address(0)) revert InvalidAddress();
VestingStorage.Layout storage s = VestingStorage.layout();
address oldOwner = s.primaryOwner;
s.primaryOwner = _newPrimaryOwner;
emit PrimaryOwnerChanged(oldOwner, _newPrimaryOwner);
}
function setSecondaryOwner(address _newSecondaryOwner) public onlyAuthorized {
VestingStorage.Layout storage s = VestingStorage.layout();
address oldOwner = s.secondaryOwner;
s.secondaryOwner = _newSecondaryOwner;
emit SecondaryOwnerChanged(oldOwner, _newSecondaryOwner);
}
function setStartTime(uint256 _newStartTime) public onlyAuthorized {
if (_newStartTime == 0) revert InvalidNumber();
VestingStorage.Layout storage s = VestingStorage.layout();
if (s.unlockSchedules.length > 0) {
_validateUnlockSchedules(_newStartTime, s.lockedAmount, _convertToMemoryArray(s.unlockSchedules));
}
uint256 oldStartTime = s.startTime;
s.startTime = _newStartTime;
emit StartTimeChanged(oldStartTime, _newStartTime);
}
function setToken(address _newToken) public onlyAuthorized {
if (_newToken == address(0)) revert InvalidAddress();
VestingStorage.Layout storage s = VestingStorage.layout();
address oldToken = s.token;
s.token = _newToken;
emit TokenChanged(oldToken, _newToken);
}
function setLockedAmount(uint256 _newLockedAmount, VestingStorage.UnlockSchedule[] memory _unlockSchedules)
public
onlyAuthorized
{
if (_newLockedAmount == 0) revert InvalidNumber();
VestingStorage.Layout storage s = VestingStorage.layout();
// 如果提供了新的解锁计划,使用新的解锁计划进行验证和设置
if (_unlockSchedules.length > 0) {
_validateUnlockSchedules(s.startTime, _newLockedAmount, _unlockSchedules);
_setUnlockSchedules(_unlockSchedules);
emit UnlockSchedulesChanged();
} else if (s.unlockSchedules.length > 0) {
// 如果没有提供新的解锁计划,验证现有解锁计划是否匹配新的锁定金额
_validateUnlockSchedules(s.startTime, _newLockedAmount, _convertToMemoryArray(s.unlockSchedules));
}
uint256 oldAmount = s.lockedAmount;
s.lockedAmount = _newLockedAmount;
emit LockedAmountChanged(oldAmount, _newLockedAmount);
}
function setUnlockSchedules(VestingStorage.UnlockSchedule[] memory _unlockSchedules) public onlyAuthorized {
VestingStorage.Layout storage s = VestingStorage.layout();
_validateUnlockSchedules(s.startTime, s.lockedAmount, _unlockSchedules);
_setUnlockSchedules(_unlockSchedules);
emit UnlockSchedulesChanged();
}
function withdraw() public onlySecondaryOwner {
uint256 available = getAvailableAmount();
if (available == 0) revert InsufficientBalance();
VestingStorage.Layout storage s = VestingStorage.layout();
s.withdrawnAmount += available;
IERC20(s.token).safeTransfer(s.secondaryOwner, available);
emit Withdraw(s.secondaryOwner, available);
}
function emergencyWithdraw(address _to, uint256 _amount) public onlyPrimaryOwner {
if (_to == address(0)) revert InvalidAddress();
VestingStorage.Layout storage s = VestingStorage.layout();
uint256 balance = IERC20(s.token).balanceOf(address(this));
if (balance < _amount) revert InsufficientBalance();
IERC20(s.token).safeTransfer(_to, _amount);
emit EmergencyWithdraw(_to, _amount);
}
function _authorizeUpgrade(address newImplementation) internal override onlyAuthorized {}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.5.0) (proxy/utils/UUPSUpgradeable.sol)
pragma solidity ^0.8.22;
import {IERC1822Proxiable} from "../../interfaces/draft-IERC1822.sol";
import {ERC1967Utils} from "../ERC1967/ERC1967Utils.sol";
/**
* @dev An upgradeability mechanism designed for UUPS proxies. The functions included here can perform an upgrade of an
* {ERC1967Proxy}, when this contract is set as the implementation behind such a proxy.
*
* A security mechanism ensures that an upgrade does not turn off upgradeability accidentally, although this risk is
* reinstated if the upgrade retains upgradeability but removes the security mechanism, e.g. by replacing
* `UUPSUpgradeable` with a custom implementation of upgrades.
*
* The {_authorizeUpgrade} function must be overridden to include access restriction to the upgrade mechanism.
*
* @custom:stateless
*/
abstract contract UUPSUpgradeable is IERC1822Proxiable {
/// @custom:oz-upgrades-unsafe-allow state-variable-immutable
address private immutable __self = address(this);
/**
* @dev The version of the upgrade interface of the contract. If this getter is missing, both `upgradeTo(address)`
* and `upgradeToAndCall(address,bytes)` are present, and `upgradeTo` must be used if no function should be called,
* while `upgradeToAndCall` will invoke the `receive` function if the second argument is the empty byte string.
* If the getter returns `"5.0.0"`, only `upgradeToAndCall(address,bytes)` is present, and the second argument must
* be the empty byte string if no function should be called, making it impossible to invoke the `receive` function
* during an upgrade.
*/
string public constant UPGRADE_INTERFACE_VERSION = "5.0.0";
/**
* @dev The call is from an unauthorized context.
*/
error UUPSUnauthorizedCallContext();
/**
* @dev The storage `slot` is unsupported as a UUID.
*/
error UUPSUnsupportedProxiableUUID(bytes32 slot);
/**
* @dev Check that the execution is being performed through a delegatecall call and that the execution context is
* a proxy contract with an implementation (as defined in ERC-1967) pointing to self. This should only be the case
* for UUPS and transparent proxies that are using the current contract as their implementation. Execution of a
* function through ERC-1167 minimal proxies (clones) would not normally pass this test, but is not guaranteed to
* fail.
*/
modifier onlyProxy() {
_checkProxy();
_;
}
/**
* @dev Check that the execution is not being performed through a delegate call. This allows a function to be
* callable on the implementing contract but not through proxies.
*/
modifier notDelegated() {
_checkNotDelegated();
_;
}
/**
* @dev Implementation of the ERC-1822 {proxiableUUID} function. This returns the storage slot used by the
* implementation. It is used to validate the implementation's compatibility when performing an upgrade.
*
* IMPORTANT: A proxy pointing at a proxiable contract should not be considered proxiable itself, because this risks
* bricking a proxy that upgrades to it, by delegating to itself until out of gas. Thus it is critical that this
* function revert if invoked through a proxy. This is guaranteed by the `notDelegated` modifier.
*/
function proxiableUUID() external view notDelegated returns (bytes32) {
return ERC1967Utils.IMPLEMENTATION_SLOT;
}
/**
* @dev Upgrade the implementation of the proxy to `newImplementation`, and subsequently execute the function call
* encoded in `data`.
*
* Calls {_authorizeUpgrade}.
*
* Emits an {Upgraded} event.
*
* @custom:oz-upgrades-unsafe-allow-reachable delegatecall
*/
function upgradeToAndCall(address newImplementation, bytes memory data) public payable virtual onlyProxy {
_authorizeUpgrade(newImplementation);
_upgradeToAndCallUUPS(newImplementation, data);
}
/**
* @dev Reverts if the execution is not performed via delegatecall or the execution
* context is not of a proxy with an ERC-1967 compliant implementation pointing to self.
*/
function _checkProxy() internal view virtual {
if (
address(this) == __self || // Must be called through delegatecall
ERC1967Utils.getImplementation() != __self // Must be called through an active proxy
) {
revert UUPSUnauthorizedCallContext();
}
}
/**
* @dev Reverts if the execution is performed via delegatecall.
* See {notDelegated}.
*/
function _checkNotDelegated() internal view virtual {
if (address(this) != __self) {
// Must not be called through delegatecall
revert UUPSUnauthorizedCallContext();
}
}
/**
* @dev Function that should revert when `msg.sender` is not authorized to upgrade the contract. Called by
* {upgradeToAndCall}.
*
* Normally, this function will use an xref:access.adoc[access control] modifier such as {Ownable-onlyOwner}.
*
* ```solidity
* function _authorizeUpgrade(address) internal onlyOwner {}
* ```
*/
function _authorizeUpgrade(address newImplementation) internal virtual;
/**
* @dev Performs an implementation upgrade with a security check for UUPS proxies, and additional setup call.
*
* As a security check, {proxiableUUID} is invoked in the new implementation, and the return value
* is expected to be the implementation slot in ERC-1967.
*
* Emits an {IERC1967-Upgraded} event.
*/
function _upgradeToAndCallUUPS(address newImplementation, bytes memory data) private {
try IERC1822Proxiable(newImplementation).proxiableUUID() returns (bytes32 slot) {
if (slot != ERC1967Utils.IMPLEMENTATION_SLOT) {
revert UUPSUnsupportedProxiableUUID(slot);
}
ERC1967Utils.upgradeToAndCall(newImplementation, data);
} catch {
// The implementation is not UUPS
revert ERC1967Utils.ERC1967InvalidImplementation(newImplementation);
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.3.0) (proxy/utils/Initializable.sol)
pragma solidity ^0.8.20;
/**
* @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed
* behind a proxy. Since proxied contracts do not make use of a constructor, it's common to move constructor logic to an
* external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer
* function so it can only be called once. The {initializer} modifier provided by this contract will have this effect.
*
* The initialization functions use a version number. Once a version number is used, it is consumed and cannot be
* reused. This mechanism prevents re-execution of each "step" but allows the creation of new initialization steps in
* case an upgrade adds a module that needs to be initialized.
*
* For example:
*
* [.hljs-theme-light.nopadding]
* ```solidity
* contract MyToken is ERC20Upgradeable {
* function initialize() initializer public {
* __ERC20_init("MyToken", "MTK");
* }
* }
*
* contract MyTokenV2 is MyToken, ERC20PermitUpgradeable {
* function initializeV2() reinitializer(2) public {
* __ERC20Permit_init("MyToken");
* }
* }
* ```
*
* TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as
* possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}.
*
* CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure
* that all initializers are idempotent. This is not verified automatically as constructors are by Solidity.
*
* [CAUTION]
* ====
* Avoid leaving a contract uninitialized.
*
* An uninitialized contract can be taken over by an attacker. This applies to both a proxy and its implementation
* contract, which may impact the proxy. To prevent the implementation contract from being used, you should invoke
* the {_disableInitializers} function in the constructor to automatically lock it when it is deployed:
*
* [.hljs-theme-light.nopadding]
* ```
* /// @custom:oz-upgrades-unsafe-allow constructor
* constructor() {
* _disableInitializers();
* }
* ```
* ====
*/
abstract contract Initializable {
/**
* @dev Storage of the initializable contract.
*
* It's implemented on a custom ERC-7201 namespace to reduce the risk of storage collisions
* when using with upgradeable contracts.
*
* @custom:storage-location erc7201:openzeppelin.storage.Initializable
*/
struct InitializableStorage {
/**
* @dev Indicates that the contract has been initialized.
*/
uint64 _initialized;
/**
* @dev Indicates that the contract is in the process of being initialized.
*/
bool _initializing;
}
// keccak256(abi.encode(uint256(keccak256("openzeppelin.storage.Initializable")) - 1)) & ~bytes32(uint256(0xff))
bytes32 private constant INITIALIZABLE_STORAGE = 0xf0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00;
/**
* @dev The contract is already initialized.
*/
error InvalidInitialization();
/**
* @dev The contract is not initializing.
*/
error NotInitializing();
/**
* @dev Triggered when the contract has been initialized or reinitialized.
*/
event Initialized(uint64 version);
/**
* @dev A modifier that defines a protected initializer function that can be invoked at most once. In its scope,
* `onlyInitializing` functions can be used to initialize parent contracts.
*
* Similar to `reinitializer(1)`, except that in the context of a constructor an `initializer` may be invoked any
* number of times. This behavior in the constructor can be useful during testing and is not expected to be used in
* production.
*
* Emits an {Initialized} event.
*/
modifier initializer() {
// solhint-disable-next-line var-name-mixedcase
InitializableStorage storage $ = _getInitializableStorage();
// Cache values to avoid duplicated sloads
bool isTopLevelCall = !$._initializing;
uint64 initialized = $._initialized;
// Allowed calls:
// - initialSetup: the contract is not in the initializing state and no previous version was
// initialized
// - construction: the contract is initialized at version 1 (no reinitialization) and the
// current contract is just being deployed
bool initialSetup = initialized == 0 && isTopLevelCall;
bool construction = initialized == 1 && address(this).code.length == 0;
if (!initialSetup && !construction) {
revert InvalidInitialization();
}
$._initialized = 1;
if (isTopLevelCall) {
$._initializing = true;
}
_;
if (isTopLevelCall) {
$._initializing = false;
emit Initialized(1);
}
}
/**
* @dev A modifier that defines a protected reinitializer function that can be invoked at most once, and only if the
* contract hasn't been initialized to a greater version before. In its scope, `onlyInitializing` functions can be
* used to initialize parent contracts.
*
* A reinitializer may be used after the original initialization step. This is essential to configure modules that
* are added through upgrades and that require initialization.
*
* When `version` is 1, this modifier is similar to `initializer`, except that functions marked with `reinitializer`
* cannot be nested. If one is invoked in the context of another, execution will revert.
*
* Note that versions can jump in increments greater than 1; this implies that if multiple reinitializers coexist in
* a contract, executing them in the right order is up to the developer or operator.
*
* WARNING: Setting the version to 2**64 - 1 will prevent any future reinitialization.
*
* Emits an {Initialized} event.
*/
modifier reinitializer(uint64 version) {
// solhint-disable-next-line var-name-mixedcase
InitializableStorage storage $ = _getInitializableStorage();
if ($._initializing || $._initialized >= version) {
revert InvalidInitialization();
}
$._initialized = version;
$._initializing = true;
_;
$._initializing = false;
emit Initialized(version);
}
/**
* @dev Modifier to protect an initialization function so that it can only be invoked by functions with the
* {initializer} and {reinitializer} modifiers, directly or indirectly.
*/
modifier onlyInitializing() {
_checkInitializing();
_;
}
/**
* @dev Reverts if the contract is not in an initializing state. See {onlyInitializing}.
*/
function _checkInitializing() internal view virtual {
if (!_isInitializing()) {
revert NotInitializing();
}
}
/**
* @dev Locks the contract, preventing any future reinitialization. This cannot be part of an initializer call.
* Calling this in the constructor of a contract will prevent that contract from being initialized or reinitialized
* to any version. It is recommended to use this to lock implementation contracts that are designed to be called
* through proxies.
*
* Emits an {Initialized} event the first time it is successfully executed.
*/
function _disableInitializers() internal virtual {
// solhint-disable-next-line var-name-mixedcase
InitializableStorage storage $ = _getInitializableStorage();
if ($._initializing) {
revert InvalidInitialization();
}
if ($._initialized != type(uint64).max) {
$._initialized = type(uint64).max;
emit Initialized(type(uint64).max);
}
}
/**
* @dev Returns the highest version that has been initialized. See {reinitializer}.
*/
function _getInitializedVersion() internal view returns (uint64) {
return _getInitializableStorage()._initialized;
}
/**
* @dev Returns `true` if the contract is currently initializing. See {onlyInitializing}.
*/
function _isInitializing() internal view returns (bool) {
return _getInitializableStorage()._initializing;
}
/**
* @dev Pointer to storage slot. Allows integrators to override it with a custom storage location.
*
* NOTE: Consider following the ERC-7201 formula to derive storage locations.
*/
function _initializableStorageSlot() internal pure virtual returns (bytes32) {
return INITIALIZABLE_STORAGE;
}
/**
* @dev Returns a pointer to the storage namespace.
*/
// solhint-disable-next-line var-name-mixedcase
function _getInitializableStorage() private pure returns (InitializableStorage storage $) {
bytes32 slot = _initializableStorageSlot();
assembly {
$.slot := slot
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.4.0) (token/ERC20/IERC20.sol)
pragma solidity >=0.4.16;
/**
* @dev Interface of the ERC-20 standard as defined in the ERC.
*/
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.5.0) (token/ERC20/utils/SafeERC20.sol)
pragma solidity ^0.8.20;
import {IERC20} from "../IERC20.sol";
import {IERC1363} from "../../../interfaces/IERC1363.sol";
/**
* @title SafeERC20
* @dev Wrappers around ERC-20 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 {
/**
* @dev An operation with an ERC-20 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 {
if (!_safeTransfer(token, to, value, true)) {
revert SafeERC20FailedOperation(address(token));
}
}
/**
* @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 {
if (!_safeTransferFrom(token, from, to, value, true)) {
revert SafeERC20FailedOperation(address(token));
}
}
/**
* @dev Variant of {safeTransfer} that returns a bool instead of reverting if the operation is not successful.
*/
function trySafeTransfer(IERC20 token, address to, uint256 value) internal returns (bool) {
return _safeTransfer(token, to, value, false);
}
/**
* @dev Variant of {safeTransferFrom} that returns a bool instead of reverting if the operation is not successful.
*/
function trySafeTransferFrom(IERC20 token, address from, address to, uint256 value) internal returns (bool) {
return _safeTransferFrom(token, from, to, value, false);
}
/**
* @dev Increase the calling contract's allowance toward `spender` by `value`. If `token` returns no value,
* non-reverting calls are assumed to be successful.
*
* IMPORTANT: If the token implements ERC-7674 (ERC-20 with temporary allowance), and if the "client"
* smart contract uses ERC-7674 to set temporary allowances, then the "client" smart contract should avoid using
* this function. Performing a {safeIncreaseAllowance} or {safeDecreaseAllowance} operation on a token contract
* that has a non-zero temporary allowance (for that particular owner-spender) will result in unexpected behavior.
*/
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.
*
* IMPORTANT: If the token implements ERC-7674 (ERC-20 with temporary allowance), and if the "client"
* smart contract uses ERC-7674 to set temporary allowances, then the "client" smart contract should avoid using
* this function. Performing a {safeIncreaseAllowance} or {safeDecreaseAllowance} operation on a token contract
* that has a non-zero temporary allowance (for that particular owner-spender) will result in unexpected behavior.
*/
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.
*
* NOTE: If the token implements ERC-7674, this function will not modify any temporary allowance. This function
* only sets the "standard" allowance. Any temporary allowance will remain active, in addition to the value being
* set here.
*/
function forceApprove(IERC20 token, address spender, uint256 value) internal {
if (!_safeApprove(token, spender, value, false)) {
if (!_safeApprove(token, spender, 0, true)) revert SafeERC20FailedOperation(address(token));
if (!_safeApprove(token, spender, value, true)) revert SafeERC20FailedOperation(address(token));
}
}
/**
* @dev Performs an {ERC1363} transferAndCall, with a fallback to the simple {ERC20} transfer if the target has no
* code. This can be used to implement an {ERC721}-like safe transfer that relies on {ERC1363} checks when
* targeting contracts.
*
* Reverts if the returned value is other than `true`.
*/
function transferAndCallRelaxed(IERC1363 token, address to, uint256 value, bytes memory data) internal {
if (to.code.length == 0) {
safeTransfer(token, to, value);
} else if (!token.transferAndCall(to, value, data)) {
revert SafeERC20FailedOperation(address(token));
}
}
/**
* @dev Performs an {ERC1363} transferFromAndCall, with a fallback to the simple {ERC20} transferFrom if the target
* has no code. This can be used to implement an {ERC721}-like safe transfer that relies on {ERC1363} checks when
* targeting contracts.
*
* Reverts if the returned value is other than `true`.
*/
function transferFromAndCallRelaxed(
IERC1363 token,
address from,
address to,
uint256 value,
bytes memory data
) internal {
if (to.code.length == 0) {
safeTransferFrom(token, from, to, value);
} else if (!token.transferFromAndCall(from, to, value, data)) {
revert SafeERC20FailedOperation(address(token));
}
}
/**
* @dev Performs an {ERC1363} approveAndCall, with a fallback to the simple {ERC20} approve if the target has no
* code. This can be used to implement an {ERC721}-like safe transfer that rely on {ERC1363} checks when
* targeting contracts.
*
* NOTE: When the recipient address (`to`) has no code (i.e. is an EOA), this function behaves as {forceApprove}.
* Oppositely, when the recipient address (`to`) has code, this function only attempts to call {ERC1363-approveAndCall}
* once without retrying, and relies on the returned value to be true.
*
* Reverts if the returned value is other than `true`.
*/
function approveAndCallRelaxed(IERC1363 token, address to, uint256 value, bytes memory data) internal {
if (to.code.length == 0) {
forceApprove(token, to, value);
} else if (!token.approveAndCall(to, value, data)) {
revert SafeERC20FailedOperation(address(token));
}
}
/**
* @dev Imitates a Solidity `token.transfer(to, value)` call, 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 to The recipient of the tokens
* @param value The amount of token to transfer
* @param bubble Behavior switch if the transfer call reverts: bubble the revert reason or return a false boolean.
*/
function _safeTransfer(IERC20 token, address to, uint256 value, bool bubble) private returns (bool success) {
bytes4 selector = IERC20.transfer.selector;
assembly ("memory-safe") {
let fmp := mload(0x40)
mstore(0x00, selector)
mstore(0x04, and(to, shr(96, not(0))))
mstore(0x24, value)
success := call(gas(), token, 0, 0x00, 0x44, 0x00, 0x20)
// if call success and return is true, all is good.
// otherwise (not success or return is not true), we need to perform further checks
if iszero(and(success, eq(mload(0x00), 1))) {
// if the call was a failure and bubble is enabled, bubble the error
if and(iszero(success), bubble) {
returndatacopy(fmp, 0x00, returndatasize())
revert(fmp, returndatasize())
}
// if the return value is not true, then the call is only successful if:
// - the token address has code
// - the returndata is empty
success := and(success, and(iszero(returndatasize()), gt(extcodesize(token), 0)))
}
mstore(0x40, fmp)
}
}
/**
* @dev Imitates a Solidity `token.transferFrom(from, to, value)` call, 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 from The sender of the tokens
* @param to The recipient of the tokens
* @param value The amount of token to transfer
* @param bubble Behavior switch if the transfer call reverts: bubble the revert reason or return a false boolean.
*/
function _safeTransferFrom(
IERC20 token,
address from,
address to,
uint256 value,
bool bubble
) private returns (bool success) {
bytes4 selector = IERC20.transferFrom.selector;
assembly ("memory-safe") {
let fmp := mload(0x40)
mstore(0x00, selector)
mstore(0x04, and(from, shr(96, not(0))))
mstore(0x24, and(to, shr(96, not(0))))
mstore(0x44, value)
success := call(gas(), token, 0, 0x00, 0x64, 0x00, 0x20)
// if call success and return is true, all is good.
// otherwise (not success or return is not true), we need to perform further checks
if iszero(and(success, eq(mload(0x00), 1))) {
// if the call was a failure and bubble is enabled, bubble the error
if and(iszero(success), bubble) {
returndatacopy(fmp, 0x00, returndatasize())
revert(fmp, returndatasize())
}
// if the return value is not true, then the call is only successful if:
// - the token address has code
// - the returndata is empty
success := and(success, and(iszero(returndatasize()), gt(extcodesize(token), 0)))
}
mstore(0x40, fmp)
mstore(0x60, 0)
}
}
/**
* @dev Imitates a Solidity `token.approve(spender, value)` call, 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 spender The spender of the tokens
* @param value The amount of token to transfer
* @param bubble Behavior switch if the transfer call reverts: bubble the revert reason or return a false boolean.
*/
function _safeApprove(IERC20 token, address spender, uint256 value, bool bubble) private returns (bool success) {
bytes4 selector = IERC20.approve.selector;
assembly ("memory-safe") {
let fmp := mload(0x40)
mstore(0x00, selector)
mstore(0x04, and(spender, shr(96, not(0))))
mstore(0x24, value)
success := call(gas(), token, 0, 0x00, 0x44, 0x00, 0x20)
// if call success and return is true, all is good.
// otherwise (not success or return is not true), we need to perform further checks
if iszero(and(success, eq(mload(0x00), 1))) {
// if the call was a failure and bubble is enabled, bubble the error
if and(iszero(success), bubble) {
returndatacopy(fmp, 0x00, returndatasize())
revert(fmp, returndatasize())
}
// if the return value is not true, then the call is only successful if:
// - the token address has code
// - the returndata is empty
success := and(success, and(iszero(returndatasize()), gt(extcodesize(token), 0)))
}
mstore(0x40, fmp)
}
}
}// SPDX-License-Identifier: MIT
pragma solidity ^0.8.24;
library VestingStorage {
bytes32 private constant STORAGE_SLOT = keccak256("Vesting.storage.v1");
struct UnlockSchedule {
uint256 timestamp;
uint256 amount;
}
struct Layout {
address primaryOwner;
address secondaryOwner;
uint256 startTime;
address token;
uint256 lockedAmount;
UnlockSchedule[] unlockSchedules;
uint256 withdrawnAmount;
}
function layout() internal pure returns (Layout storage l) {
bytes32 slot = STORAGE_SLOT;
assembly {
l.slot := slot
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.4.0) (interfaces/draft-IERC1822.sol)
pragma solidity >=0.4.16;
/**
* @dev ERC-1822: Universal Upgradeable Proxy Standard (UUPS) documents a method for upgradeability through a simplified
* proxy whose upgrades are fully controlled by the current implementation.
*/
interface IERC1822Proxiable {
/**
* @dev Returns the storage slot that the proxiable contract assumes is being used to store the implementation
* address.
*
* IMPORTANT: A proxy pointing at a proxiable contract should not be considered proxiable itself, because this risks
* bricking a proxy that upgrades to it, by delegating to itself until out of gas. Thus it is critical that this
* function revert if invoked through a proxy.
*/
function proxiableUUID() external view returns (bytes32);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.4.0) (proxy/ERC1967/ERC1967Utils.sol)
pragma solidity ^0.8.21;
import {IBeacon} from "../beacon/IBeacon.sol";
import {IERC1967} from "../../interfaces/IERC1967.sol";
import {Address} from "../../utils/Address.sol";
import {StorageSlot} from "../../utils/StorageSlot.sol";
/**
* @dev This library provides getters and event emitting update functions for
* https://eips.ethereum.org/EIPS/eip-1967[ERC-1967] slots.
*/
library ERC1967Utils {
/**
* @dev Storage slot with the address of the current implementation.
* This is the keccak-256 hash of "eip1967.proxy.implementation" subtracted by 1.
*/
// solhint-disable-next-line private-vars-leading-underscore
bytes32 internal constant IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;
/**
* @dev The `implementation` of the proxy is invalid.
*/
error ERC1967InvalidImplementation(address implementation);
/**
* @dev The `admin` of the proxy is invalid.
*/
error ERC1967InvalidAdmin(address admin);
/**
* @dev The `beacon` of the proxy is invalid.
*/
error ERC1967InvalidBeacon(address beacon);
/**
* @dev An upgrade function sees `msg.value > 0` that may be lost.
*/
error ERC1967NonPayable();
/**
* @dev Returns the current implementation address.
*/
function getImplementation() internal view returns (address) {
return StorageSlot.getAddressSlot(IMPLEMENTATION_SLOT).value;
}
/**
* @dev Stores a new address in the ERC-1967 implementation slot.
*/
function _setImplementation(address newImplementation) private {
if (newImplementation.code.length == 0) {
revert ERC1967InvalidImplementation(newImplementation);
}
StorageSlot.getAddressSlot(IMPLEMENTATION_SLOT).value = newImplementation;
}
/**
* @dev Performs implementation upgrade with additional setup call if data is nonempty.
* This function is payable only if the setup call is performed, otherwise `msg.value` is rejected
* to avoid stuck value in the contract.
*
* Emits an {IERC1967-Upgraded} event.
*/
function upgradeToAndCall(address newImplementation, bytes memory data) internal {
_setImplementation(newImplementation);
emit IERC1967.Upgraded(newImplementation);
if (data.length > 0) {
Address.functionDelegateCall(newImplementation, data);
} else {
_checkNonPayable();
}
}
/**
* @dev Storage slot with the admin of the contract.
* This is the keccak-256 hash of "eip1967.proxy.admin" subtracted by 1.
*/
// solhint-disable-next-line private-vars-leading-underscore
bytes32 internal constant ADMIN_SLOT = 0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103;
/**
* @dev Returns the current admin.
*
* TIP: To get this value clients can read directly from the storage slot shown below (specified by ERC-1967) using
* the https://eth.wiki/json-rpc/API#eth_getstorageat[`eth_getStorageAt`] RPC call.
* `0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103`
*/
function getAdmin() internal view returns (address) {
return StorageSlot.getAddressSlot(ADMIN_SLOT).value;
}
/**
* @dev Stores a new address in the ERC-1967 admin slot.
*/
function _setAdmin(address newAdmin) private {
if (newAdmin == address(0)) {
revert ERC1967InvalidAdmin(address(0));
}
StorageSlot.getAddressSlot(ADMIN_SLOT).value = newAdmin;
}
/**
* @dev Changes the admin of the proxy.
*
* Emits an {IERC1967-AdminChanged} event.
*/
function changeAdmin(address newAdmin) internal {
emit IERC1967.AdminChanged(getAdmin(), newAdmin);
_setAdmin(newAdmin);
}
/**
* @dev The storage slot of the UpgradeableBeacon contract which defines the implementation for this proxy.
* This is the keccak-256 hash of "eip1967.proxy.beacon" subtracted by 1.
*/
// solhint-disable-next-line private-vars-leading-underscore
bytes32 internal constant BEACON_SLOT = 0xa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d50;
/**
* @dev Returns the current beacon.
*/
function getBeacon() internal view returns (address) {
return StorageSlot.getAddressSlot(BEACON_SLOT).value;
}
/**
* @dev Stores a new beacon in the ERC-1967 beacon slot.
*/
function _setBeacon(address newBeacon) private {
if (newBeacon.code.length == 0) {
revert ERC1967InvalidBeacon(newBeacon);
}
StorageSlot.getAddressSlot(BEACON_SLOT).value = newBeacon;
address beaconImplementation = IBeacon(newBeacon).implementation();
if (beaconImplementation.code.length == 0) {
revert ERC1967InvalidImplementation(beaconImplementation);
}
}
/**
* @dev Change the beacon and trigger a setup call if data is nonempty.
* This function is payable only if the setup call is performed, otherwise `msg.value` is rejected
* to avoid stuck value in the contract.
*
* Emits an {IERC1967-BeaconUpgraded} event.
*
* CAUTION: Invoking this function has no effect on an instance of {BeaconProxy} since v5, since
* it uses an immutable beacon without looking at the value of the ERC-1967 beacon slot for
* efficiency.
*/
function upgradeBeaconToAndCall(address newBeacon, bytes memory data) internal {
_setBeacon(newBeacon);
emit IERC1967.BeaconUpgraded(newBeacon);
if (data.length > 0) {
Address.functionDelegateCall(IBeacon(newBeacon).implementation(), data);
} else {
_checkNonPayable();
}
}
/**
* @dev Reverts if `msg.value` is not zero. It can be used to avoid `msg.value` stuck in the contract
* if an upgrade doesn't perform an initialization call.
*/
function _checkNonPayable() private {
if (msg.value > 0) {
revert ERC1967NonPayable();
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.4.0) (interfaces/IERC1363.sol)
pragma solidity >=0.6.2;
import {IERC20} from "./IERC20.sol";
import {IERC165} from "./IERC165.sol";
/**
* @title IERC1363
* @dev Interface of the ERC-1363 standard as defined in the https://eips.ethereum.org/EIPS/eip-1363[ERC-1363].
*
* Defines an extension interface for ERC-20 tokens that supports executing code on a recipient contract
* after `transfer` or `transferFrom`, or code on a spender contract after `approve`, in a single transaction.
*/
interface IERC1363 is IERC20, IERC165 {
/*
* Note: the ERC-165 identifier for this interface is 0xb0202a11.
* 0xb0202a11 ===
* bytes4(keccak256('transferAndCall(address,uint256)')) ^
* bytes4(keccak256('transferAndCall(address,uint256,bytes)')) ^
* bytes4(keccak256('transferFromAndCall(address,address,uint256)')) ^
* bytes4(keccak256('transferFromAndCall(address,address,uint256,bytes)')) ^
* bytes4(keccak256('approveAndCall(address,uint256)')) ^
* bytes4(keccak256('approveAndCall(address,uint256,bytes)'))
*/
/**
* @dev Moves a `value` amount of tokens from the caller's account to `to`
* and then calls {IERC1363Receiver-onTransferReceived} on `to`.
* @param to The address which you want to transfer to.
* @param value The amount of tokens to be transferred.
* @return A boolean value indicating whether the operation succeeded unless throwing.
*/
function transferAndCall(address to, uint256 value) external returns (bool);
/**
* @dev Moves a `value` amount of tokens from the caller's account to `to`
* and then calls {IERC1363Receiver-onTransferReceived} on `to`.
* @param to The address which you want to transfer to.
* @param value The amount of tokens to be transferred.
* @param data Additional data with no specified format, sent in call to `to`.
* @return A boolean value indicating whether the operation succeeded unless throwing.
*/
function transferAndCall(address to, uint256 value, bytes calldata data) external returns (bool);
/**
* @dev Moves a `value` amount of tokens from `from` to `to` using the allowance mechanism
* and then calls {IERC1363Receiver-onTransferReceived} on `to`.
* @param from The address which you want to send tokens from.
* @param to The address which you want to transfer to.
* @param value The amount of tokens to be transferred.
* @return A boolean value indicating whether the operation succeeded unless throwing.
*/
function transferFromAndCall(address from, address to, uint256 value) external returns (bool);
/**
* @dev Moves a `value` amount of tokens from `from` to `to` using the allowance mechanism
* and then calls {IERC1363Receiver-onTransferReceived} on `to`.
* @param from The address which you want to send tokens from.
* @param to The address which you want to transfer to.
* @param value The amount of tokens to be transferred.
* @param data Additional data with no specified format, sent in call to `to`.
* @return A boolean value indicating whether the operation succeeded unless throwing.
*/
function transferFromAndCall(address from, address to, uint256 value, bytes calldata data) external returns (bool);
/**
* @dev Sets a `value` amount of tokens as the allowance of `spender` over the
* caller's tokens and then calls {IERC1363Spender-onApprovalReceived} on `spender`.
* @param spender The address which will spend the funds.
* @param value The amount of tokens to be spent.
* @return A boolean value indicating whether the operation succeeded unless throwing.
*/
function approveAndCall(address spender, uint256 value) external returns (bool);
/**
* @dev Sets a `value` amount of tokens as the allowance of `spender` over the
* caller's tokens and then calls {IERC1363Spender-onApprovalReceived} on `spender`.
* @param spender The address which will spend the funds.
* @param value The amount of tokens to be spent.
* @param data Additional data with no specified format, sent in call to `spender`.
* @return A boolean value indicating whether the operation succeeded unless throwing.
*/
function approveAndCall(address spender, uint256 value, bytes calldata data) external returns (bool);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.4.0) (proxy/beacon/IBeacon.sol)
pragma solidity >=0.4.16;
/**
* @dev This is the interface that {BeaconProxy} expects of its beacon.
*/
interface IBeacon {
/**
* @dev Must return an address that can be used as a delegate call target.
*
* {UpgradeableBeacon} will check that this address is a contract.
*/
function implementation() external view returns (address);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.4.0) (interfaces/IERC1967.sol)
pragma solidity >=0.4.11;
/**
* @dev ERC-1967: Proxy Storage Slots. This interface contains the events defined in the ERC.
*/
interface IERC1967 {
/**
* @dev Emitted when the implementation is upgraded.
*/
event Upgraded(address indexed implementation);
/**
* @dev Emitted when the admin account has changed.
*/
event AdminChanged(address previousAdmin, address newAdmin);
/**
* @dev Emitted when the beacon is changed.
*/
event BeaconUpgraded(address indexed beacon);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.5.0) (utils/Address.sol)
pragma solidity ^0.8.20;
import {Errors} from "./Errors.sol";
import {LowLevelCall} from "./LowLevelCall.sol";
/**
* @dev Collection of functions related to the address type
*/
library Address {
/**
* @dev There's no code at `target` (it is not a contract).
*/
error AddressEmptyCode(address target);
/**
* @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 Errors.InsufficientBalance(address(this).balance, amount);
}
if (LowLevelCall.callNoReturn(recipient, amount, "")) {
// call successful, nothing to do
return;
} else if (LowLevelCall.returnDataSize() > 0) {
LowLevelCall.bubbleRevert();
} else {
revert Errors.FailedCall();
}
}
/**
* @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
* {Errors.FailedCall} 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 Errors.InsufficientBalance(address(this).balance, value);
}
bool success = LowLevelCall.callNoReturn(target, value, data);
if (success && (LowLevelCall.returnDataSize() > 0 || target.code.length > 0)) {
return LowLevelCall.returnData();
} else if (success) {
revert AddressEmptyCode(target);
} else if (LowLevelCall.returnDataSize() > 0) {
LowLevelCall.bubbleRevert();
} else {
revert Errors.FailedCall();
}
}
/**
* @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 = LowLevelCall.staticcallNoReturn(target, data);
if (success && (LowLevelCall.returnDataSize() > 0 || target.code.length > 0)) {
return LowLevelCall.returnData();
} else if (success) {
revert AddressEmptyCode(target);
} else if (LowLevelCall.returnDataSize() > 0) {
LowLevelCall.bubbleRevert();
} else {
revert Errors.FailedCall();
}
}
/**
* @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 = LowLevelCall.delegatecallNoReturn(target, data);
if (success && (LowLevelCall.returnDataSize() > 0 || target.code.length > 0)) {
return LowLevelCall.returnData();
} else if (success) {
revert AddressEmptyCode(target);
} else if (LowLevelCall.returnDataSize() > 0) {
LowLevelCall.bubbleRevert();
} else {
revert Errors.FailedCall();
}
}
/**
* @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 {Errors.FailedCall}) in case
* of an unsuccessful call.
*
* NOTE: This function is DEPRECATED and may be removed in the next major release.
*/
function verifyCallResultFromTarget(
address target,
bool success,
bytes memory returndata
) internal view returns (bytes memory) {
// 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 (success && (returndata.length > 0 || target.code.length > 0)) {
return returndata;
} else if (success) {
revert AddressEmptyCode(target);
} else if (returndata.length > 0) {
LowLevelCall.bubbleRevert(returndata);
} else {
revert Errors.FailedCall();
}
}
/**
* @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 {Errors.FailedCall} error.
*/
function verifyCallResult(bool success, bytes memory returndata) internal pure returns (bytes memory) {
if (success) {
return returndata;
} else if (returndata.length > 0) {
LowLevelCall.bubbleRevert(returndata);
} else {
revert Errors.FailedCall();
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (utils/StorageSlot.sol)
// This file was procedurally generated from scripts/generate/templates/StorageSlot.js.
pragma solidity ^0.8.20;
/**
* @dev Library for reading and writing primitive types to specific storage slots.
*
* Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts.
* This library helps with reading and writing to such slots without the need for inline assembly.
*
* The functions in this library return Slot structs that contain a `value` member that can be used to read or write.
*
* Example usage to set ERC-1967 implementation slot:
* ```solidity
* contract ERC1967 {
* // Define the slot. Alternatively, use the SlotDerivation library to derive the slot.
* bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;
*
* function _getImplementation() internal view returns (address) {
* return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value;
* }
*
* function _setImplementation(address newImplementation) internal {
* require(newImplementation.code.length > 0);
* StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation;
* }
* }
* ```
*
* TIP: Consider using this library along with {SlotDerivation}.
*/
library StorageSlot {
struct AddressSlot {
address value;
}
struct BooleanSlot {
bool value;
}
struct Bytes32Slot {
bytes32 value;
}
struct Uint256Slot {
uint256 value;
}
struct Int256Slot {
int256 value;
}
struct StringSlot {
string value;
}
struct BytesSlot {
bytes value;
}
/**
* @dev Returns an `AddressSlot` with member `value` located at `slot`.
*/
function getAddressSlot(bytes32 slot) internal pure returns (AddressSlot storage r) {
assembly ("memory-safe") {
r.slot := slot
}
}
/**
* @dev Returns a `BooleanSlot` with member `value` located at `slot`.
*/
function getBooleanSlot(bytes32 slot) internal pure returns (BooleanSlot storage r) {
assembly ("memory-safe") {
r.slot := slot
}
}
/**
* @dev Returns a `Bytes32Slot` with member `value` located at `slot`.
*/
function getBytes32Slot(bytes32 slot) internal pure returns (Bytes32Slot storage r) {
assembly ("memory-safe") {
r.slot := slot
}
}
/**
* @dev Returns a `Uint256Slot` with member `value` located at `slot`.
*/
function getUint256Slot(bytes32 slot) internal pure returns (Uint256Slot storage r) {
assembly ("memory-safe") {
r.slot := slot
}
}
/**
* @dev Returns a `Int256Slot` with member `value` located at `slot`.
*/
function getInt256Slot(bytes32 slot) internal pure returns (Int256Slot storage r) {
assembly ("memory-safe") {
r.slot := slot
}
}
/**
* @dev Returns a `StringSlot` with member `value` located at `slot`.
*/
function getStringSlot(bytes32 slot) internal pure returns (StringSlot storage r) {
assembly ("memory-safe") {
r.slot := slot
}
}
/**
* @dev Returns an `StringSlot` representation of the string storage pointer `store`.
*/
function getStringSlot(string storage store) internal pure returns (StringSlot storage r) {
assembly ("memory-safe") {
r.slot := store.slot
}
}
/**
* @dev Returns a `BytesSlot` with member `value` located at `slot`.
*/
function getBytesSlot(bytes32 slot) internal pure returns (BytesSlot storage r) {
assembly ("memory-safe") {
r.slot := slot
}
}
/**
* @dev Returns an `BytesSlot` representation of the bytes storage pointer `store`.
*/
function getBytesSlot(bytes storage store) internal pure returns (BytesSlot storage r) {
assembly ("memory-safe") {
r.slot := store.slot
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.4.0) (interfaces/IERC20.sol)
pragma solidity >=0.4.16;
import {IERC20} from "../token/ERC20/IERC20.sol";// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.4.0) (interfaces/IERC165.sol)
pragma solidity >=0.4.16;
import {IERC165} from "../utils/introspection/IERC165.sol";// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (utils/Errors.sol)
pragma solidity ^0.8.20;
/**
* @dev Collection of common custom errors used in multiple contracts
*
* IMPORTANT: Backwards compatibility is not guaranteed in future versions of the library.
* It is recommended to avoid relying on the error API for critical functionality.
*
* _Available since v5.1._
*/
library Errors {
/**
* @dev The ETH balance of the account is not enough to perform the operation.
*/
error InsufficientBalance(uint256 balance, uint256 needed);
/**
* @dev A call to an address target failed. The target may have reverted.
*/
error FailedCall();
/**
* @dev The deployment failed.
*/
error FailedDeployment();
/**
* @dev A necessary precompile is missing.
*/
error MissingPrecompile(address);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.5.0) (utils/LowLevelCall.sol)
pragma solidity ^0.8.20;
/**
* @dev Library of low level call functions that implement different calling strategies to deal with the return data.
*
* WARNING: Using this library requires an advanced understanding of Solidity and how the EVM works. It is recommended
* to use the {Address} library instead.
*/
library LowLevelCall {
/// @dev Performs a Solidity function call using a low level `call` and ignoring the return data.
function callNoReturn(address target, bytes memory data) internal returns (bool success) {
return callNoReturn(target, 0, data);
}
/// @dev Same as {callNoReturn}, but allows to specify the value to be sent in the call.
function callNoReturn(address target, uint256 value, bytes memory data) internal returns (bool success) {
assembly ("memory-safe") {
success := call(gas(), target, value, add(data, 0x20), mload(data), 0x00, 0x00)
}
}
/// @dev Performs a Solidity function call using a low level `call` and returns the first 64 bytes of the result
/// in the scratch space of memory. Useful for functions that return a tuple of single-word values.
///
/// WARNING: Do not assume that the results are zero if `success` is false. Memory can be already allocated
/// and this function doesn't zero it out.
function callReturn64Bytes(
address target,
bytes memory data
) internal returns (bool success, bytes32 result1, bytes32 result2) {
return callReturn64Bytes(target, 0, data);
}
/// @dev Same as {callReturnBytes32Pair}, but allows to specify the value to be sent in the call.
function callReturn64Bytes(
address target,
uint256 value,
bytes memory data
) internal returns (bool success, bytes32 result1, bytes32 result2) {
assembly ("memory-safe") {
success := call(gas(), target, value, add(data, 0x20), mload(data), 0x00, 0x40)
result1 := mload(0x00)
result2 := mload(0x20)
}
}
/// @dev Performs a Solidity function call using a low level `staticcall` and ignoring the return data.
function staticcallNoReturn(address target, bytes memory data) internal view returns (bool success) {
assembly ("memory-safe") {
success := staticcall(gas(), target, add(data, 0x20), mload(data), 0x00, 0x00)
}
}
/// @dev Performs a Solidity function call using a low level `staticcall` and returns the first 64 bytes of the result
/// in the scratch space of memory. Useful for functions that return a tuple of single-word values.
///
/// WARNING: Do not assume that the results are zero if `success` is false. Memory can be already allocated
/// and this function doesn't zero it out.
function staticcallReturn64Bytes(
address target,
bytes memory data
) internal view returns (bool success, bytes32 result1, bytes32 result2) {
assembly ("memory-safe") {
success := staticcall(gas(), target, add(data, 0x20), mload(data), 0x00, 0x40)
result1 := mload(0x00)
result2 := mload(0x20)
}
}
/// @dev Performs a Solidity function call using a low level `delegatecall` and ignoring the return data.
function delegatecallNoReturn(address target, bytes memory data) internal returns (bool success) {
assembly ("memory-safe") {
success := delegatecall(gas(), target, add(data, 0x20), mload(data), 0x00, 0x00)
}
}
/// @dev Performs a Solidity function call using a low level `delegatecall` and returns the first 64 bytes of the result
/// in the scratch space of memory. Useful for functions that return a tuple of single-word values.
///
/// WARNING: Do not assume that the results are zero if `success` is false. Memory can be already allocated
/// and this function doesn't zero it out.
function delegatecallReturn64Bytes(
address target,
bytes memory data
) internal returns (bool success, bytes32 result1, bytes32 result2) {
assembly ("memory-safe") {
success := delegatecall(gas(), target, add(data, 0x20), mload(data), 0x00, 0x40)
result1 := mload(0x00)
result2 := mload(0x20)
}
}
/// @dev Returns the size of the return data buffer.
function returnDataSize() internal pure returns (uint256 size) {
assembly ("memory-safe") {
size := returndatasize()
}
}
/// @dev Returns a buffer containing the return data from the last call.
function returnData() internal pure returns (bytes memory result) {
assembly ("memory-safe") {
result := mload(0x40)
mstore(result, returndatasize())
returndatacopy(add(result, 0x20), 0x00, returndatasize())
mstore(0x40, add(result, add(0x20, returndatasize())))
}
}
/// @dev Revert with the return data from the last call.
function bubbleRevert() internal pure {
assembly ("memory-safe") {
let fmp := mload(0x40)
returndatacopy(fmp, 0x00, returndatasize())
revert(fmp, returndatasize())
}
}
function bubbleRevert(bytes memory returndata) internal pure {
assembly ("memory-safe") {
revert(add(returndata, 0x20), mload(returndata))
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.4.0) (utils/introspection/IERC165.sol)
pragma solidity >=0.4.16;
/**
* @dev Interface of the ERC-165 standard, as defined in the
* https://eips.ethereum.org/EIPS/eip-165[ERC].
*
* 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[ERC 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);
}{
"remappings": [
"@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts/",
"@openzeppelin/contracts/=lib/openzeppelin-contracts-upgradeable/lib/openzeppelin-contracts/contracts/",
"erc4626-tests/=lib/openzeppelin-contracts-upgradeable/lib/erc4626-tests/",
"forge-std/=lib/forge-std/src/",
"halmos-cheatcodes/=lib/openzeppelin-contracts-upgradeable/lib/halmos-cheatcodes/src/",
"openzeppelin-contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/",
"openzeppelin-contracts/=lib/openzeppelin-contracts-upgradeable/lib/openzeppelin-contracts/"
],
"optimizer": {
"enabled": false,
"runs": 200
},
"metadata": {
"useLiteralContent": false,
"bytecodeHash": "ipfs",
"appendCBOR": true
},
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
},
"evmVersion": "prague",
"viaIR": false
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"target","type":"address"}],"name":"AddressEmptyCode","type":"error"},{"inputs":[{"internalType":"address","name":"implementation","type":"address"}],"name":"ERC1967InvalidImplementation","type":"error"},{"inputs":[],"name":"ERC1967NonPayable","type":"error"},{"inputs":[],"name":"FailedCall","type":"error"},{"inputs":[],"name":"InsufficientBalance","type":"error"},{"inputs":[],"name":"InvalidAddress","type":"error"},{"inputs":[],"name":"InvalidInitialization","type":"error"},{"inputs":[],"name":"InvalidNumber","type":"error"},{"inputs":[],"name":"InvalidUnlockSchedule","type":"error"},{"inputs":[],"name":"NoUnlockAvailable","type":"error"},{"inputs":[],"name":"NotInitializing","type":"error"},{"inputs":[{"internalType":"address","name":"token","type":"address"}],"name":"SafeERC20FailedOperation","type":"error"},{"inputs":[],"name":"UUPSUnauthorizedCallContext","type":"error"},{"inputs":[{"internalType":"bytes32","name":"slot","type":"bytes32"}],"name":"UUPSUnsupportedProxiableUUID","type":"error"},{"inputs":[],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"EmergencyWithdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint64","name":"version","type":"uint64"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"oldAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newAmount","type":"uint256"}],"name":"LockedAmountChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"oldOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"PrimaryOwnerChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"oldOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"SecondaryOwnerChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"oldStartTime","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newStartTime","type":"uint256"}],"name":"StartTimeChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"oldToken","type":"address"},{"indexed":true,"internalType":"address","name":"newToken","type":"address"}],"name":"TokenChanged","type":"event"},{"anonymous":false,"inputs":[],"name":"UnlockSchedulesChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"implementation","type":"address"}],"name":"Upgraded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Withdraw","type":"event"},{"inputs":[],"name":"OWNER_RESTRICTION_PERIOD","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"UPGRADE_INTERFACE_VERSION","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"emergencyWithdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"getAvailableAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"getUnlockSchedule","outputs":[{"internalType":"uint256","name":"timestamp","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getUnlockSchedules","outputs":[{"components":[{"internalType":"uint256","name":"timestamp","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"internalType":"struct VestingStorage.UnlockSchedule[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getUnlockSchedulesCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_primaryOwner","type":"address"},{"internalType":"address","name":"_secondaryOwner","type":"address"},{"internalType":"uint256","name":"_startTime","type":"uint256"},{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_lockedAmount","type":"uint256"},{"components":[{"internalType":"uint256","name":"timestamp","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"internalType":"struct VestingStorage.UnlockSchedule[]","name":"_unlockSchedules","type":"tuple[]"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"lockedAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"primaryOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"proxiableUUID","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"secondaryOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_newLockedAmount","type":"uint256"},{"components":[{"internalType":"uint256","name":"timestamp","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"internalType":"struct VestingStorage.UnlockSchedule[]","name":"_unlockSchedules","type":"tuple[]"}],"name":"setLockedAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_newPrimaryOwner","type":"address"}],"name":"setPrimaryOwner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_newSecondaryOwner","type":"address"}],"name":"setSecondaryOwner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_newStartTime","type":"uint256"}],"name":"setStartTime","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_newToken","type":"address"}],"name":"setToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"timestamp","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"internalType":"struct VestingStorage.UnlockSchedule[]","name":"_unlockSchedules","type":"tuple[]"}],"name":"setUnlockSchedules","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"startTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"token","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newImplementation","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"upgradeToAndCall","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawnAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}]Contract Creation Code
60a06040523073ffffffffffffffffffffffffffffffffffffffff1660809073ffffffffffffffffffffffffffffffffffffffff16815250348015610042575f5ffd5b5061005161005660201b60201c565b6101d1565b5f61006561015460201b60201c565b9050805f0160089054906101000a900460ff16156100af576040517ff92ee8a900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8016815f015f9054906101000a900467ffffffffffffffff1667ffffffffffffffff16146101515767ffffffffffffffff815f015f6101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055507fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d267ffffffffffffffff60405161014891906101b8565b60405180910390a15b50565b5f5f61016461016d60201b60201c565b90508091505090565b5f7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a005f1b905090565b5f67ffffffffffffffff82169050919050565b6101b281610196565b82525050565b5f6020820190506101cb5f8301846101a9565b92915050565b608051612b7e6101f75f395f8181611b4c01528181611ba10152611d5b0152612b7e5ff3fe60806040526004361061013f575f3560e01c80634f1ef286116100b55780638e10be331161006e5780638e10be33146103f457806395ccea671461041e578063ad3cb1cc14610446578063c2bd89b914610470578063d52e7f9314610498578063fc0c546a146104c05761013f565b80634f1ef2861461030657806352d1902d146103225780636ab28bc81461034c57806378e97925146103765780637bb476f5146103a0578063830de4b1146103ca5761013f565b80632972659111610107578063297265911461021157806336a5a231146102395780633ccfd60b146102635780633e0a322d146102795780633f586e2c146102a157806343bad081146102de5761013f565b8063028575791461014357806303b92ce81461016d57806313fb282714610197578063144fa6d7146101bf5780631c4f88d3146101e7575b5f5ffd5b34801561014e575f5ffd5b506101576104ea565b60405161016491906122bc565b60405180910390f35b348015610178575f5ffd5b50610181610504565b60405161018e91906122eb565b60405180910390f35b3480156101a2575f5ffd5b506101bd60048036038101906101b8919061253a565b61050b565b005b3480156101ca575f5ffd5b506101e560048036038101906101e091906125df565b6108bb565b005b3480156101f2575f5ffd5b506101fb6109fb565b60405161020891906122eb565b60405180910390f35b34801561021c575f5ffd5b506102376004803603810190610232919061260a565b610a10565b005b348015610244575f5ffd5b5061024d610a6f565b60405161025a9190612660565b60405180910390f35b34801561026e575f5ffd5b50610277610aa0565b005b348015610284575f5ffd5b5061029f600480360381019061029a9190612679565b610bf7565b005b3480156102ac575f5ffd5b506102c760048036038101906102c29190612679565b610cbc565b6040516102d59291906126a4565b60405180910390f35b3480156102e9575f5ffd5b5061030460048036038101906102ff91906125df565b610d67565b005b610320600480360381019061031b919061277b565b610ea5565b005b34801561032d575f5ffd5b50610336610ec4565b60405161034391906127ed565b60405180910390f35b348015610357575f5ffd5b50610360610ef5565b60405161036d91906122eb565b60405180910390f35b348015610381575f5ffd5b5061038a610f07565b60405161039791906122eb565b60405180910390f35b3480156103ab575f5ffd5b506103b4610f19565b6040516103c191906122eb565b60405180910390f35b3480156103d5575f5ffd5b506103de610fde565b6040516103eb91906122eb565b60405180910390f35b3480156103ff575f5ffd5b50610408610ff0565b6040516104159190612660565b60405180910390f35b348015610429575f5ffd5b50610444600480360381019061043f9190612806565b611020565b005b348015610451575f5ffd5b5061045a611212565b60405161046791906128a4565b60405180910390f35b34801561047b575f5ffd5b50610496600480360381019061049191906128c4565b61124b565b005b3480156104a3575f5ffd5b506104be60048036038101906104b991906125df565b611364565b005b3480156104cb575f5ffd5b506104d461143f565b6040516104e19190612660565b60405180910390f35b60606104ff6104f7611470565b60050161149c565b905090565b62ed4e0081565b5f61051461157c565b90505f815f0160089054906101000a900460ff161590505f825f015f9054906101000a900467ffffffffffffffff1690505f5f8267ffffffffffffffff1614801561055c5750825b90505f60018367ffffffffffffffff1614801561058f57505f3073ffffffffffffffffffffffffffffffffffffffff163b145b90508115801561059d575080155b156105d4576040517ff92ee8a900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001855f015f6101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055508315610621576001855f0160086101000a81548160ff0219169083151502179055505b5f73ffffffffffffffffffffffffffffffffffffffff168b73ffffffffffffffffffffffffffffffffffffffff1603610686576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f89036106bf576040517f74cbd35f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff1603610724576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f870361075d576040517f74cbd35f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f610766611470565b90508b815f015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508a816001015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555089816002018190555088816003015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555087816004018190555061084a8a898961158f565b610853876117a5565b5083156108ae575f855f0160086101000a81548160ff0219169083151502179055507fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d260016040516108a59190612973565b60405180910390a15b5050505050505050505050565b6108c3611838565b5f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610928576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f610931611470565b90505f816003015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905082826003015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508273ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167fec507b76e4056f09193394a4361b44129ec561809ddee312c7f97121f93bb58b60405160405180910390a3505050565b5f610a04611470565b60050180549050905090565b610a18611838565b5f610a21611470565b9050610a36816002015482600401548461158f565b610a3f826117a5565b7ff5eac85b9813f7323fee9dacb49b96f1a12f3e288a63ed64f46ff3f9b12db35060405160405180910390a15050565b5f610a78611470565b6001015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b610aa86119cc565b5f610ab1610f19565b90505f8103610aec576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f610af5611470565b905081816006015f828254610b0a91906129b9565b92505081905550610b82816001015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1683836003015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16611a629092919063ffffffff16565b806001015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f884edad9ce6fa2440d8a54cc123490eb96d2768479d49ff9c7366125a942436483604051610beb91906122eb565b60405180910390a25050565b610bff611838565b5f8103610c38576040517f74cbd35f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f610c41611470565b90505f81600501805490501115610c6d57610c6c828260040154610c678460050161149c565b61158f565b5b5f816002015490508282600201819055507fbefe8e3983c0dc663c4ba451fc82d4ff7eb2e4ccc4b944874abea1ecc841feae8184604051610caf9291906126a4565b60405180910390a1505050565b5f5f5f610cc7611470565b905080600501805490508410610d12576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610d0990612a36565b60405180910390fd5b806005018481548110610d2857610d27612a54565b5b905f5260205f2090600202015f0154816005018581548110610d4d57610d4c612a54565b5b905f5260205f209060020201600101549250925050915091565b610d6f611ab5565b5f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610dd4576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f610ddd611470565b90505f815f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905082825f015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508273ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167fcacb62ef00d7d057af8a730953836c1302cc0ff75775992cab69ebb0861ed9ef60405160405180910390a3505050565b610ead611b4a565b610eb682611c30565b610ec08282611c3b565b5050565b5f610ecd611d59565b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5f1b905090565b5f610efe611470565b60040154905090565b5f610f10611470565b60020154905090565b5f5f610f23611470565b90508060020154421015610f3a575f915050610fdb565b5f5f90505f5f90505b8260050180549050811015610fb357826005018181548110610f6857610f67612a54565b5b905f5260205f2090600202015f01544210610fa657826005018181548110610f9357610f92612a54565b5b905f5260205f2090600202016001015491505b8080600101915050610f43565b5081600601548111610fc5575f610fd6565b816006015481610fd59190612a81565b5b925050505b90565b5f610fe7611470565b60060154905090565b5f610ff9611470565b5f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b611028611ab5565b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff160361108d576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f611096611470565b90505f816003015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166370a08231306040518263ffffffff1660e01b81526004016110f59190612660565b602060405180830381865afa158015611110573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906111349190612ac8565b905082811015611170576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6111be8484846003015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16611a629092919063ffffffff16565b8373ffffffffffffffffffffffffffffffffffffffff167f5fafa99d0643513820be26656b45130b01e1c03062e1266bf36f88cbd3bd96958460405161120491906122eb565b60405180910390a250505050565b6040518060400160405280600581526020017f352e302e3000000000000000000000000000000000000000000000000000000081525081565b611253611838565b5f820361128c576040517f74cbd35f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f611295611470565b90505f825111156112e9576112af8160020154848461158f565b6112b8826117a5565b7ff5eac85b9813f7323fee9dacb49b96f1a12f3e288a63ed64f46ff3f9b12db35060405160405180910390a1611314565b5f816005018054905011156113135761131281600201548461130d8460050161149c565b61158f565b5b5b5f816004015490508382600401819055507fbe7472397f55be64a29d6c8e3344ad1f90e5d2a975f021cd0e1520b3f116739881856040516113569291906126a4565b60405180910390a150505050565b61136c611838565b5f611375611470565b90505f816001015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905082826001015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508273ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167fd3fe68f35104d9b97c46bd44222e5d30c699bee11fb150050de9a497698a1d4c60405160405180910390a3505050565b5f611448611470565b6003015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b5f5f7fd661bcbe54f9423e8b1f55685e3864844de5500f265b3ea5deef75b4f674f92f90508091505090565b60605f828054905067ffffffffffffffff8111156114bd576114bc6123ad565b5b6040519080825280602002602001820160405280156114f657816020015b6114e3612172565b8152602001906001900390816114db5790505b5090505f5f90505b83805490508110156115725783818154811061151d5761151c612a54565b5b905f5260205f2090600202016040518060400160405290815f820154815260200160018201548152505082828151811061155a57611559612a54565b5b602002602001018190525080806001019150506114fe565b5080915050919050565b5f5f611586611de0565b90508091505090565b5f8151036115c9576040517f040c7a4700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82815f815181106115dd576115dc612a54565b5b60200260200101515f01511161161f576040517f040c7a4700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f600190505b815181101561173b578160018261163c9190612a81565b8151811061164d5761164c612a54565b5b60200260200101515f015182828151811061166b5761166a612a54565b5b60200260200101515f0151116116ad576040517f040c7a4700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b816001826116bb9190612a81565b815181106116cc576116cb612a54565b5b6020026020010151602001518282815181106116eb576116ea612a54565b5b6020026020010151602001511161172e576040517f040c7a4700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050611625565b5081816001835161174c9190612a81565b8151811061175d5761175c612a54565b5b602002602001015160200151146117a0576040517f040c7a4700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b5f6117ae611470565b9050806005015f6117bf919061218a565b5f5f90505b825181101561183357816005018382815181106117e4576117e3612a54565b5b6020026020010151908060018154018082558091505060019003905f5260205f2090600202015f909190919091505f820151815f015560208201518160010155505080806001019150506117c4565b505050565b5f611841611470565b9050805f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141580156118f05750806001015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614155b15611927576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b62ed4e00816002015461193a91906129b9565b4210156119c957805f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146119c8576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b50565b5f6119d5611470565b9050806001015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614611a5f576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50565b611a6f8383836001611e09565b611ab057826040517f5274afe7000000000000000000000000000000000000000000000000000000008152600401611aa79190612660565b60405180910390fd5b505050565b5f611abe611470565b9050805f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614611b47576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff163073ffffffffffffffffffffffffffffffffffffffff161480611bf757507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16611bde611e6b565b73ffffffffffffffffffffffffffffffffffffffff1614155b15611c2e576040517fe07c8dba00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b611c38611838565b50565b8173ffffffffffffffffffffffffffffffffffffffff166352d1902d6040518163ffffffff1660e01b8152600401602060405180830381865afa925050508015611ca357506040513d601f19601f82011682018060405250810190611ca09190612b1d565b60015b611ce457816040517f4c9c8ce3000000000000000000000000000000000000000000000000000000008152600401611cdb9190612660565b60405180910390fd5b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5f1b8114611d4a57806040517faa1d49a4000000000000000000000000000000000000000000000000000000008152600401611d4191906127ed565b60405180910390fd5b611d548383611ebe565b505050565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff163073ffffffffffffffffffffffffffffffffffffffff1614611dde576040517fe07c8dba00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b5f7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a005f1b905090565b5f5f63a9059cbb60e01b9050604051815f525f1960601c86166004528460245260205f60445f5f8b5af1925060015f51148316611e5d578383151615611e51573d5f823e3d81fd5b5f873b113d1516831692505b806040525050949350505050565b5f611e977f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5f1b611f30565b5f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b611ec782611f39565b8173ffffffffffffffffffffffffffffffffffffffff167fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b60405160405180910390a25f81511115611f2357611f1d8282612002565b50611f2c565b611f2b6120f3565b5b5050565b5f819050919050565b5f8173ffffffffffffffffffffffffffffffffffffffff163b03611f9457806040517f4c9c8ce3000000000000000000000000000000000000000000000000000000008152600401611f8b9190612660565b60405180910390fd5b80611fc07f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5f1b611f30565b5f015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b60605f61200f848461212f565b905080801561204557505f612022612143565b118061204457505f8473ffffffffffffffffffffffffffffffffffffffff163b115b5b1561205a5761205261214a565b9150506120ed565b801561209d57836040517f9996b3150000000000000000000000000000000000000000000000000000000081526004016120949190612660565b60405180910390fd5b5f6120a6612143565b11156120b9576120b4612167565b6120eb565b6040517fd6bda27500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505b92915050565b5f34111561212d576040517fb398979f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b5f5f5f835160208501865af4905092915050565b5f3d905090565b606060405190503d81523d5f602083013e3d602001810160405290565b6040513d5f823e3d81fd5b60405180604001604052805f81526020015f81525090565b5080545f8255600202905f5260205f20908101906121a891906121ab565b50565b5b808211156121cb575f5f82015f9055600182015f9055506002016121ac565b5090565b5f81519050919050565b5f82825260208201905092915050565b5f819050602082019050919050565b5f819050919050565b61220a816121f8565b82525050565b604082015f8201516122245f850182612201565b5060208201516122376020850182612201565b50505050565b5f6122488383612210565b60408301905092915050565b5f602082019050919050565b5f61226a826121cf565b61227481856121d9565b935061227f836121e9565b805f5b838110156122af578151612296888261223d565b97506122a183612254565b925050600181019050612282565b5085935050505092915050565b5f6020820190508181035f8301526122d48184612260565b905092915050565b6122e5816121f8565b82525050565b5f6020820190506122fe5f8301846122dc565b92915050565b5f604051905090565b5f5ffd5b5f5ffd5b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f61233e82612315565b9050919050565b61234e81612334565b8114612358575f5ffd5b50565b5f8135905061236981612345565b92915050565b612378816121f8565b8114612382575f5ffd5b50565b5f813590506123938161236f565b92915050565b5f5ffd5b5f601f19601f8301169050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b6123e38261239d565b810181811067ffffffffffffffff82111715612402576124016123ad565b5b80604052505050565b5f612414612304565b905061242082826123da565b919050565b5f67ffffffffffffffff82111561243f5761243e6123ad565b5b602082029050602081019050919050565b5f5ffd5b5f5ffd5b5f6040828403121561246d5761246c612454565b5b612477604061240b565b90505f61248684828501612385565b5f83015250602061249984828501612385565b60208301525092915050565b5f6124b76124b284612425565b61240b565b905080838252602082019050604084028301858111156124da576124d9612450565b5b835b8181101561250357806124ef8882612458565b8452602084019350506040810190506124dc565b5050509392505050565b5f82601f83011261252157612520612399565b5b81356125318482602086016124a5565b91505092915050565b5f5f5f5f5f5f60c087890312156125545761255361230d565b5b5f61256189828a0161235b565b965050602061257289828a0161235b565b955050604061258389828a01612385565b945050606061259489828a0161235b565b93505060806125a589828a01612385565b92505060a087013567ffffffffffffffff8111156125c6576125c5612311565b5b6125d289828a0161250d565b9150509295509295509295565b5f602082840312156125f4576125f361230d565b5b5f6126018482850161235b565b91505092915050565b5f6020828403121561261f5761261e61230d565b5b5f82013567ffffffffffffffff81111561263c5761263b612311565b5b6126488482850161250d565b91505092915050565b61265a81612334565b82525050565b5f6020820190506126735f830184612651565b92915050565b5f6020828403121561268e5761268d61230d565b5b5f61269b84828501612385565b91505092915050565b5f6040820190506126b75f8301856122dc565b6126c460208301846122dc565b9392505050565b5f5ffd5b5f67ffffffffffffffff8211156126e9576126e86123ad565b5b6126f28261239d565b9050602081019050919050565b828183375f83830152505050565b5f61271f61271a846126cf565b61240b565b90508281526020810184848401111561273b5761273a6126cb565b5b6127468482856126ff565b509392505050565b5f82601f83011261276257612761612399565b5b813561277284826020860161270d565b91505092915050565b5f5f604083850312156127915761279061230d565b5b5f61279e8582860161235b565b925050602083013567ffffffffffffffff8111156127bf576127be612311565b5b6127cb8582860161274e565b9150509250929050565b5f819050919050565b6127e7816127d5565b82525050565b5f6020820190506128005f8301846127de565b92915050565b5f5f6040838503121561281c5761281b61230d565b5b5f6128298582860161235b565b925050602061283a85828601612385565b9150509250929050565b5f81519050919050565b5f82825260208201905092915050565b8281835e5f83830152505050565b5f61287682612844565b612880818561284e565b935061289081856020860161285e565b6128998161239d565b840191505092915050565b5f6020820190508181035f8301526128bc818461286c565b905092915050565b5f5f604083850312156128da576128d961230d565b5b5f6128e785828601612385565b925050602083013567ffffffffffffffff81111561290857612907612311565b5b6129148582860161250d565b9150509250929050565b5f819050919050565b5f67ffffffffffffffff82169050919050565b5f819050919050565b5f61295d6129586129538461291e565b61293a565b612927565b9050919050565b61296d81612943565b82525050565b5f6020820190506129865f830184612964565b92915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f6129c3826121f8565b91506129ce836121f8565b92508282019050808211156129e6576129e561298c565b5b92915050565b7f496e646578206f7574206f6620626f756e6473000000000000000000000000005f82015250565b5f612a2060138361284e565b9150612a2b826129ec565b602082019050919050565b5f6020820190508181035f830152612a4d81612a14565b9050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b5f612a8b826121f8565b9150612a96836121f8565b9250828203905081811115612aae57612aad61298c565b5b92915050565b5f81519050612ac28161236f565b92915050565b5f60208284031215612add57612adc61230d565b5b5f612aea84828501612ab4565b91505092915050565b612afc816127d5565b8114612b06575f5ffd5b50565b5f81519050612b1781612af3565b92915050565b5f60208284031215612b3257612b3161230d565b5b5f612b3f84828501612b09565b9150509291505056fea2646970667358221220f62fe0f54274366a6fe82c61dc9066decb1705e7fbe4cb4e3db45c0115eed36464736f6c634300081c0033
Deployed Bytecode
0x60806040526004361061013f575f3560e01c80634f1ef286116100b55780638e10be331161006e5780638e10be33146103f457806395ccea671461041e578063ad3cb1cc14610446578063c2bd89b914610470578063d52e7f9314610498578063fc0c546a146104c05761013f565b80634f1ef2861461030657806352d1902d146103225780636ab28bc81461034c57806378e97925146103765780637bb476f5146103a0578063830de4b1146103ca5761013f565b80632972659111610107578063297265911461021157806336a5a231146102395780633ccfd60b146102635780633e0a322d146102795780633f586e2c146102a157806343bad081146102de5761013f565b8063028575791461014357806303b92ce81461016d57806313fb282714610197578063144fa6d7146101bf5780631c4f88d3146101e7575b5f5ffd5b34801561014e575f5ffd5b506101576104ea565b60405161016491906122bc565b60405180910390f35b348015610178575f5ffd5b50610181610504565b60405161018e91906122eb565b60405180910390f35b3480156101a2575f5ffd5b506101bd60048036038101906101b8919061253a565b61050b565b005b3480156101ca575f5ffd5b506101e560048036038101906101e091906125df565b6108bb565b005b3480156101f2575f5ffd5b506101fb6109fb565b60405161020891906122eb565b60405180910390f35b34801561021c575f5ffd5b506102376004803603810190610232919061260a565b610a10565b005b348015610244575f5ffd5b5061024d610a6f565b60405161025a9190612660565b60405180910390f35b34801561026e575f5ffd5b50610277610aa0565b005b348015610284575f5ffd5b5061029f600480360381019061029a9190612679565b610bf7565b005b3480156102ac575f5ffd5b506102c760048036038101906102c29190612679565b610cbc565b6040516102d59291906126a4565b60405180910390f35b3480156102e9575f5ffd5b5061030460048036038101906102ff91906125df565b610d67565b005b610320600480360381019061031b919061277b565b610ea5565b005b34801561032d575f5ffd5b50610336610ec4565b60405161034391906127ed565b60405180910390f35b348015610357575f5ffd5b50610360610ef5565b60405161036d91906122eb565b60405180910390f35b348015610381575f5ffd5b5061038a610f07565b60405161039791906122eb565b60405180910390f35b3480156103ab575f5ffd5b506103b4610f19565b6040516103c191906122eb565b60405180910390f35b3480156103d5575f5ffd5b506103de610fde565b6040516103eb91906122eb565b60405180910390f35b3480156103ff575f5ffd5b50610408610ff0565b6040516104159190612660565b60405180910390f35b348015610429575f5ffd5b50610444600480360381019061043f9190612806565b611020565b005b348015610451575f5ffd5b5061045a611212565b60405161046791906128a4565b60405180910390f35b34801561047b575f5ffd5b50610496600480360381019061049191906128c4565b61124b565b005b3480156104a3575f5ffd5b506104be60048036038101906104b991906125df565b611364565b005b3480156104cb575f5ffd5b506104d461143f565b6040516104e19190612660565b60405180910390f35b60606104ff6104f7611470565b60050161149c565b905090565b62ed4e0081565b5f61051461157c565b90505f815f0160089054906101000a900460ff161590505f825f015f9054906101000a900467ffffffffffffffff1690505f5f8267ffffffffffffffff1614801561055c5750825b90505f60018367ffffffffffffffff1614801561058f57505f3073ffffffffffffffffffffffffffffffffffffffff163b145b90508115801561059d575080155b156105d4576040517ff92ee8a900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001855f015f6101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055508315610621576001855f0160086101000a81548160ff0219169083151502179055505b5f73ffffffffffffffffffffffffffffffffffffffff168b73ffffffffffffffffffffffffffffffffffffffff1603610686576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f89036106bf576040517f74cbd35f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff1603610724576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f870361075d576040517f74cbd35f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f610766611470565b90508b815f015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508a816001015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555089816002018190555088816003015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555087816004018190555061084a8a898961158f565b610853876117a5565b5083156108ae575f855f0160086101000a81548160ff0219169083151502179055507fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d260016040516108a59190612973565b60405180910390a15b5050505050505050505050565b6108c3611838565b5f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610928576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f610931611470565b90505f816003015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905082826003015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508273ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167fec507b76e4056f09193394a4361b44129ec561809ddee312c7f97121f93bb58b60405160405180910390a3505050565b5f610a04611470565b60050180549050905090565b610a18611838565b5f610a21611470565b9050610a36816002015482600401548461158f565b610a3f826117a5565b7ff5eac85b9813f7323fee9dacb49b96f1a12f3e288a63ed64f46ff3f9b12db35060405160405180910390a15050565b5f610a78611470565b6001015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b610aa86119cc565b5f610ab1610f19565b90505f8103610aec576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f610af5611470565b905081816006015f828254610b0a91906129b9565b92505081905550610b82816001015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1683836003015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16611a629092919063ffffffff16565b806001015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f884edad9ce6fa2440d8a54cc123490eb96d2768479d49ff9c7366125a942436483604051610beb91906122eb565b60405180910390a25050565b610bff611838565b5f8103610c38576040517f74cbd35f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f610c41611470565b90505f81600501805490501115610c6d57610c6c828260040154610c678460050161149c565b61158f565b5b5f816002015490508282600201819055507fbefe8e3983c0dc663c4ba451fc82d4ff7eb2e4ccc4b944874abea1ecc841feae8184604051610caf9291906126a4565b60405180910390a1505050565b5f5f5f610cc7611470565b905080600501805490508410610d12576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610d0990612a36565b60405180910390fd5b806005018481548110610d2857610d27612a54565b5b905f5260205f2090600202015f0154816005018581548110610d4d57610d4c612a54565b5b905f5260205f209060020201600101549250925050915091565b610d6f611ab5565b5f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610dd4576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f610ddd611470565b90505f815f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905082825f015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508273ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167fcacb62ef00d7d057af8a730953836c1302cc0ff75775992cab69ebb0861ed9ef60405160405180910390a3505050565b610ead611b4a565b610eb682611c30565b610ec08282611c3b565b5050565b5f610ecd611d59565b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5f1b905090565b5f610efe611470565b60040154905090565b5f610f10611470565b60020154905090565b5f5f610f23611470565b90508060020154421015610f3a575f915050610fdb565b5f5f90505f5f90505b8260050180549050811015610fb357826005018181548110610f6857610f67612a54565b5b905f5260205f2090600202015f01544210610fa657826005018181548110610f9357610f92612a54565b5b905f5260205f2090600202016001015491505b8080600101915050610f43565b5081600601548111610fc5575f610fd6565b816006015481610fd59190612a81565b5b925050505b90565b5f610fe7611470565b60060154905090565b5f610ff9611470565b5f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b611028611ab5565b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff160361108d576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f611096611470565b90505f816003015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166370a08231306040518263ffffffff1660e01b81526004016110f59190612660565b602060405180830381865afa158015611110573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906111349190612ac8565b905082811015611170576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6111be8484846003015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16611a629092919063ffffffff16565b8373ffffffffffffffffffffffffffffffffffffffff167f5fafa99d0643513820be26656b45130b01e1c03062e1266bf36f88cbd3bd96958460405161120491906122eb565b60405180910390a250505050565b6040518060400160405280600581526020017f352e302e3000000000000000000000000000000000000000000000000000000081525081565b611253611838565b5f820361128c576040517f74cbd35f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f611295611470565b90505f825111156112e9576112af8160020154848461158f565b6112b8826117a5565b7ff5eac85b9813f7323fee9dacb49b96f1a12f3e288a63ed64f46ff3f9b12db35060405160405180910390a1611314565b5f816005018054905011156113135761131281600201548461130d8460050161149c565b61158f565b5b5b5f816004015490508382600401819055507fbe7472397f55be64a29d6c8e3344ad1f90e5d2a975f021cd0e1520b3f116739881856040516113569291906126a4565b60405180910390a150505050565b61136c611838565b5f611375611470565b90505f816001015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905082826001015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508273ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167fd3fe68f35104d9b97c46bd44222e5d30c699bee11fb150050de9a497698a1d4c60405160405180910390a3505050565b5f611448611470565b6003015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b5f5f7fd661bcbe54f9423e8b1f55685e3864844de5500f265b3ea5deef75b4f674f92f90508091505090565b60605f828054905067ffffffffffffffff8111156114bd576114bc6123ad565b5b6040519080825280602002602001820160405280156114f657816020015b6114e3612172565b8152602001906001900390816114db5790505b5090505f5f90505b83805490508110156115725783818154811061151d5761151c612a54565b5b905f5260205f2090600202016040518060400160405290815f820154815260200160018201548152505082828151811061155a57611559612a54565b5b602002602001018190525080806001019150506114fe565b5080915050919050565b5f5f611586611de0565b90508091505090565b5f8151036115c9576040517f040c7a4700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82815f815181106115dd576115dc612a54565b5b60200260200101515f01511161161f576040517f040c7a4700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f600190505b815181101561173b578160018261163c9190612a81565b8151811061164d5761164c612a54565b5b60200260200101515f015182828151811061166b5761166a612a54565b5b60200260200101515f0151116116ad576040517f040c7a4700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b816001826116bb9190612a81565b815181106116cc576116cb612a54565b5b6020026020010151602001518282815181106116eb576116ea612a54565b5b6020026020010151602001511161172e576040517f040c7a4700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050611625565b5081816001835161174c9190612a81565b8151811061175d5761175c612a54565b5b602002602001015160200151146117a0576040517f040c7a4700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b5f6117ae611470565b9050806005015f6117bf919061218a565b5f5f90505b825181101561183357816005018382815181106117e4576117e3612a54565b5b6020026020010151908060018154018082558091505060019003905f5260205f2090600202015f909190919091505f820151815f015560208201518160010155505080806001019150506117c4565b505050565b5f611841611470565b9050805f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141580156118f05750806001015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614155b15611927576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b62ed4e00816002015461193a91906129b9565b4210156119c957805f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146119c8576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b50565b5f6119d5611470565b9050806001015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614611a5f576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50565b611a6f8383836001611e09565b611ab057826040517f5274afe7000000000000000000000000000000000000000000000000000000008152600401611aa79190612660565b60405180910390fd5b505050565b5f611abe611470565b9050805f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614611b47576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50565b7f0000000000000000000000003df6167c6f11e989bb4e59c5796a5ba00f59c39b73ffffffffffffffffffffffffffffffffffffffff163073ffffffffffffffffffffffffffffffffffffffff161480611bf757507f0000000000000000000000003df6167c6f11e989bb4e59c5796a5ba00f59c39b73ffffffffffffffffffffffffffffffffffffffff16611bde611e6b565b73ffffffffffffffffffffffffffffffffffffffff1614155b15611c2e576040517fe07c8dba00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b611c38611838565b50565b8173ffffffffffffffffffffffffffffffffffffffff166352d1902d6040518163ffffffff1660e01b8152600401602060405180830381865afa925050508015611ca357506040513d601f19601f82011682018060405250810190611ca09190612b1d565b60015b611ce457816040517f4c9c8ce3000000000000000000000000000000000000000000000000000000008152600401611cdb9190612660565b60405180910390fd5b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5f1b8114611d4a57806040517faa1d49a4000000000000000000000000000000000000000000000000000000008152600401611d4191906127ed565b60405180910390fd5b611d548383611ebe565b505050565b7f0000000000000000000000003df6167c6f11e989bb4e59c5796a5ba00f59c39b73ffffffffffffffffffffffffffffffffffffffff163073ffffffffffffffffffffffffffffffffffffffff1614611dde576040517fe07c8dba00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b5f7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a005f1b905090565b5f5f63a9059cbb60e01b9050604051815f525f1960601c86166004528460245260205f60445f5f8b5af1925060015f51148316611e5d578383151615611e51573d5f823e3d81fd5b5f873b113d1516831692505b806040525050949350505050565b5f611e977f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5f1b611f30565b5f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b611ec782611f39565b8173ffffffffffffffffffffffffffffffffffffffff167fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b60405160405180910390a25f81511115611f2357611f1d8282612002565b50611f2c565b611f2b6120f3565b5b5050565b5f819050919050565b5f8173ffffffffffffffffffffffffffffffffffffffff163b03611f9457806040517f4c9c8ce3000000000000000000000000000000000000000000000000000000008152600401611f8b9190612660565b60405180910390fd5b80611fc07f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5f1b611f30565b5f015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b60605f61200f848461212f565b905080801561204557505f612022612143565b118061204457505f8473ffffffffffffffffffffffffffffffffffffffff163b115b5b1561205a5761205261214a565b9150506120ed565b801561209d57836040517f9996b3150000000000000000000000000000000000000000000000000000000081526004016120949190612660565b60405180910390fd5b5f6120a6612143565b11156120b9576120b4612167565b6120eb565b6040517fd6bda27500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505b92915050565b5f34111561212d576040517fb398979f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b5f5f5f835160208501865af4905092915050565b5f3d905090565b606060405190503d81523d5f602083013e3d602001810160405290565b6040513d5f823e3d81fd5b60405180604001604052805f81526020015f81525090565b5080545f8255600202905f5260205f20908101906121a891906121ab565b50565b5b808211156121cb575f5f82015f9055600182015f9055506002016121ac565b5090565b5f81519050919050565b5f82825260208201905092915050565b5f819050602082019050919050565b5f819050919050565b61220a816121f8565b82525050565b604082015f8201516122245f850182612201565b5060208201516122376020850182612201565b50505050565b5f6122488383612210565b60408301905092915050565b5f602082019050919050565b5f61226a826121cf565b61227481856121d9565b935061227f836121e9565b805f5b838110156122af578151612296888261223d565b97506122a183612254565b925050600181019050612282565b5085935050505092915050565b5f6020820190508181035f8301526122d48184612260565b905092915050565b6122e5816121f8565b82525050565b5f6020820190506122fe5f8301846122dc565b92915050565b5f604051905090565b5f5ffd5b5f5ffd5b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f61233e82612315565b9050919050565b61234e81612334565b8114612358575f5ffd5b50565b5f8135905061236981612345565b92915050565b612378816121f8565b8114612382575f5ffd5b50565b5f813590506123938161236f565b92915050565b5f5ffd5b5f601f19601f8301169050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b6123e38261239d565b810181811067ffffffffffffffff82111715612402576124016123ad565b5b80604052505050565b5f612414612304565b905061242082826123da565b919050565b5f67ffffffffffffffff82111561243f5761243e6123ad565b5b602082029050602081019050919050565b5f5ffd5b5f5ffd5b5f6040828403121561246d5761246c612454565b5b612477604061240b565b90505f61248684828501612385565b5f83015250602061249984828501612385565b60208301525092915050565b5f6124b76124b284612425565b61240b565b905080838252602082019050604084028301858111156124da576124d9612450565b5b835b8181101561250357806124ef8882612458565b8452602084019350506040810190506124dc565b5050509392505050565b5f82601f83011261252157612520612399565b5b81356125318482602086016124a5565b91505092915050565b5f5f5f5f5f5f60c087890312156125545761255361230d565b5b5f61256189828a0161235b565b965050602061257289828a0161235b565b955050604061258389828a01612385565b945050606061259489828a0161235b565b93505060806125a589828a01612385565b92505060a087013567ffffffffffffffff8111156125c6576125c5612311565b5b6125d289828a0161250d565b9150509295509295509295565b5f602082840312156125f4576125f361230d565b5b5f6126018482850161235b565b91505092915050565b5f6020828403121561261f5761261e61230d565b5b5f82013567ffffffffffffffff81111561263c5761263b612311565b5b6126488482850161250d565b91505092915050565b61265a81612334565b82525050565b5f6020820190506126735f830184612651565b92915050565b5f6020828403121561268e5761268d61230d565b5b5f61269b84828501612385565b91505092915050565b5f6040820190506126b75f8301856122dc565b6126c460208301846122dc565b9392505050565b5f5ffd5b5f67ffffffffffffffff8211156126e9576126e86123ad565b5b6126f28261239d565b9050602081019050919050565b828183375f83830152505050565b5f61271f61271a846126cf565b61240b565b90508281526020810184848401111561273b5761273a6126cb565b5b6127468482856126ff565b509392505050565b5f82601f83011261276257612761612399565b5b813561277284826020860161270d565b91505092915050565b5f5f604083850312156127915761279061230d565b5b5f61279e8582860161235b565b925050602083013567ffffffffffffffff8111156127bf576127be612311565b5b6127cb8582860161274e565b9150509250929050565b5f819050919050565b6127e7816127d5565b82525050565b5f6020820190506128005f8301846127de565b92915050565b5f5f6040838503121561281c5761281b61230d565b5b5f6128298582860161235b565b925050602061283a85828601612385565b9150509250929050565b5f81519050919050565b5f82825260208201905092915050565b8281835e5f83830152505050565b5f61287682612844565b612880818561284e565b935061289081856020860161285e565b6128998161239d565b840191505092915050565b5f6020820190508181035f8301526128bc818461286c565b905092915050565b5f5f604083850312156128da576128d961230d565b5b5f6128e785828601612385565b925050602083013567ffffffffffffffff81111561290857612907612311565b5b6129148582860161250d565b9150509250929050565b5f819050919050565b5f67ffffffffffffffff82169050919050565b5f819050919050565b5f61295d6129586129538461291e565b61293a565b612927565b9050919050565b61296d81612943565b82525050565b5f6020820190506129865f830184612964565b92915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f6129c3826121f8565b91506129ce836121f8565b92508282019050808211156129e6576129e561298c565b5b92915050565b7f496e646578206f7574206f6620626f756e6473000000000000000000000000005f82015250565b5f612a2060138361284e565b9150612a2b826129ec565b602082019050919050565b5f6020820190508181035f830152612a4d81612a14565b9050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b5f612a8b826121f8565b9150612a96836121f8565b9250828203905081811115612aae57612aad61298c565b5b92915050565b5f81519050612ac28161236f565b92915050565b5f60208284031215612add57612adc61230d565b5b5f612aea84828501612ab4565b91505092915050565b612afc816127d5565b8114612b06575f5ffd5b50565b5f81519050612b1781612af3565b92915050565b5f60208284031215612b3257612b3161230d565b5b5f612b3f84828501612b09565b9150509291505056fea2646970667358221220f62fe0f54274366a6fe82c61dc9066decb1705e7fbe4cb4e3db45c0115eed36464736f6c634300081c0033
Loading...
Loading
Loading...
Loading
Net Worth in USD
$0.00
Net Worth in ETH
0
Multichain Portfolio | 33 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|
Loading...
Loading
Loading...
Loading
Loading...
Loading
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.