More Info
Private Name Tags
ContractCreator
Latest 25 from a total of 116 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
Value | ||||
---|---|---|---|---|---|---|---|---|---|
Deposit To Broke... | 19170456 | 149 days ago | IN | 0 ETH | 0.00378286 | ||||
Deposit To Broke... | 18965297 | 177 days ago | IN | 0 ETH | 0.00185591 | ||||
Deposit To Broke... | 18965293 | 177 days ago | IN | 0 ETH | 0.00165993 | ||||
Deposit To Broke... | 18965255 | 177 days ago | IN | 0 ETH | 0.00211034 | ||||
Deposit To Broke... | 18965247 | 177 days ago | IN | 0 ETH | 0.00148674 | ||||
Deposit To Broke... | 18965210 | 177 days ago | IN | 0 ETH | 0.0018488 | ||||
Deposit To Broke... | 18965196 | 177 days ago | IN | 0 ETH | 0.00169113 | ||||
Purchase Bank | 18958487 | 178 days ago | IN | 0 ETH | 0.00847823 | ||||
Deposit To Broke... | 18937401 | 181 days ago | IN | 0 ETH | 0.00124981 | ||||
Purchase Bank | 18768293 | 205 days ago | IN | 0 ETH | 0.00769348 | ||||
Cover Reserve | 18764135 | 206 days ago | IN | 0 ETH | 0.02247436 | ||||
Claim Rewards | 18756365 | 207 days ago | IN | 0 ETH | 0.01034086 | ||||
Purchase Bank | 18751747 | 207 days ago | IN | 0 ETH | 0.00711119 | ||||
Purchase Bank | 18749431 | 208 days ago | IN | 0 ETH | 0.01364578 | ||||
Claim Rewards | 18749409 | 208 days ago | IN | 0 ETH | 0.02356928 | ||||
Purchase Bank | 18742816 | 209 days ago | IN | 0 ETH | 0.01417251 | ||||
Purchase Bank | 18723913 | 211 days ago | IN | 0 ETH | 0.01420215 | ||||
Purchase Bank | 18719266 | 212 days ago | IN | 0 ETH | 0.01334139 | ||||
Purchase Bank | 18710428 | 213 days ago | IN | 0 ETH | 0.00994236 | ||||
Cover Reserve | 18684675 | 217 days ago | IN | 0 ETH | 0.01637111 | ||||
Cover Reserve | 18655869 | 221 days ago | IN | 0 ETH | 0.0122734 | ||||
Purchase Bank | 18626439 | 225 days ago | IN | 0 ETH | 0.00617506 | ||||
Purchase Bank | 18615948 | 226 days ago | IN | 0 ETH | 0.00870074 | ||||
Set | 18615856 | 226 days ago | IN | 0 ETH | 0.01219524 | ||||
Add | 18615850 | 226 days ago | IN | 0 ETH | 0.01321145 |
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Name:
ReserveV2
Compiler Version
v0.8.19+commit.7dd6d404
Optimization Enabled:
No with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity =0.8.19; /* Reserve ($RSRV) https://www.reserveth.com/ https://t.me/rsrv_eth https://twitter.com/rsrv_eth */ import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/math/SafeMath.sol"; import "@openzeppelin/contracts/security/ReentrancyGuard.sol"; import "./interfaces/IRSRV.sol"; import "./interfaces/IReserveBrokerage.sol"; import "./interfaces/IReserveOracle.sol"; import "./interfaces/IReserve.sol"; contract ReserveV2 is IReserve, Ownable, ReentrancyGuard { using SafeMath for uint; using SafeERC20 for IERC20; struct UserBankInfo { uint count; uint pendingRewards; uint rewardDebt; } struct BankInfo { uint id; uint cost; uint bonusMultiplier; uint reserveAmount; uint lastRewardTimestamp; uint accRsrvPerShare; uint nextUpgradeId; bool isReset; uint aprOnReset; } IRSRV public immutable rsrv; address public constant deadAddress = address(0xdead); IReserveBrokerage public brokerage; IReserveOracle public oracle; uint public baseApr = 10000; // 100% uint private constant _DENOMINATOR = 10000; uint private slippage = 50; // 0.50% BankInfo[] public bankInfo; mapping (uint => mapping (address => UserBankInfo)) public userBankInfo; mapping (address => uint) public userReserve; mapping (address => uint) public withdrawableRewards; mapping (uint => uint) public totalBankCountPerType; uint public totalBankCount; uint public startTimestamp; mapping (address => bool) private _isWhitelisted; mapping (address => bool) private _userMigrated; /** EVENTS **/ event Purchased( address indexed account, uint indexed id, uint count ); event Upgraded( address indexed account, uint indexed id, uint indexed upgradeId, uint count ); event Claimed( address indexed account, uint amount ); constructor ( address _rsrv, uint _startTimestamp ) { rsrv = IRSRV(_rsrv); startTimestamp = _startTimestamp; // retail bankInfo.push(BankInfo({ id: 0, cost: uint(100).mul(1e18), bonusMultiplier: 20000, // 200.00% reserveAmount: 5, lastRewardTimestamp: _startTimestamp, accRsrvPerShare: 0, nextUpgradeId: 1, isReset: false, aprOnReset: 800 // 8.00 % })); // commercial bankInfo.push(BankInfo({ id: 1, cost: uint(500).mul(1e18), bonusMultiplier: 40000, // 400.00 % reserveAmount: 50, lastRewardTimestamp: _startTimestamp, accRsrvPerShare: 0, nextUpgradeId: 2, isReset: false, aprOnReset: 1200 // 12.00 % })); // investment bankInfo.push(BankInfo({ id: 2, cost: uint(2000).mul(1e18), bonusMultiplier: 100000, // 1000.00 % reserveAmount: 250, lastRewardTimestamp: _startTimestamp, accRsrvPerShare: 0, nextUpgradeId: 0, isReset: false, aprOnReset: 2000 // 20.00 % })); _isWhitelisted[_msgSender()] = true; } /** RESTRICTED FUNCTIONS **/ function setBrokerage(address _brokerage) external onlyOwner { require (_brokerage != address(0), "!ADDRESS"); brokerage = IReserveBrokerage(_brokerage); } function setOracle(address _oracle) external onlyOwner { require (_oracle != address(0), "!ADDRESS"); oracle = IReserveOracle(_oracle); } function depositToBrokerage(uint _amount) external onlyOwner { require (address(brokerage) != address(0), "!SET"); rsrv.mint(_amount); rsrv.approve(address(brokerage), _amount); brokerage.depositTokens(_amount); } function triggerAprUpdate() external onlyOwner { massUpdate(true); } function add(uint _id, uint _cost) external onlyOwner { require (_id == totalBankTypes(), "!ID"); massUpdate(true); uint lastRewardTimestamp = block.timestamp > startTimestamp ? block.timestamp : startTimestamp; bankInfo.push(BankInfo({ id: _id, cost: _cost.mul(1e18), bonusMultiplier: 10000, reserveAmount: 0, lastRewardTimestamp: lastRewardTimestamp, accRsrvPerShare: 0, nextUpgradeId: 0, isReset: false, aprOnReset: 0 })); } function set(uint _id, uint _cost, uint _multiplier, uint _reserveAmount, uint _nextUpgradeId, uint _aprOnReset) external onlyOwner { require (_id < totalBankTypes(), "!ID"); massUpdate(true); bankInfo[_id].cost = _cost.mul(1e18); bankInfo[_id].bonusMultiplier = _multiplier; bankInfo[_id].reserveAmount = _reserveAmount; bankInfo[_id].nextUpgradeId = _nextUpgradeId; bankInfo[_id].aprOnReset = _aprOnReset; } /** VIEW FUNCTIONS **/ function getRewardRate(address _account) external view returns (uint rewardRate) { for (uint id = 0; id < totalBankTypes(); id++) { rewardRate = rewardRate.add(getRewardRate(_account, id)); } } function getRewardRate(address _account, uint _id) public view returns (uint rewardRate) { BankInfo memory bank = bankInfo[_id]; UserBankInfo memory user = userBankInfo[_id][_account]; uint bankCount = totalBankCountPerType[_id]; if (bankCount != 0) { uint multiplier = getMultiplier(block.timestamp, block.timestamp.add(1), bank.bonusMultiplier, bank.isReset, bank.aprOnReset); uint rewardRatePerBank = multiplier.mul(bank.cost).div(1e18); rewardRate = user.count.mul(rewardRatePerBank); } } function getRewards(address _account) external view returns (uint rewards) { rewards = withdrawableRewards[_account].add(getPendingRewards(_account)); } function getPendingRewards(address _account) public view returns (uint rewards) { for (uint id = 0; id < totalBankTypes(); id++) { rewards = rewards.add(getPendingRewards(_account, id)); } } function getPendingRewards(address _account, uint _id) public view returns (uint rewards) { BankInfo memory bank = bankInfo[_id]; UserBankInfo memory user = userBankInfo[_id][_account]; uint accRsrvPerShare = bank.accRsrvPerShare; uint bankCount = totalBankCountPerType[_id]; if (block.timestamp > bank.lastRewardTimestamp && bankCount != 0) { uint multiplier = getMultiplier(bank.lastRewardTimestamp, block.timestamp, bank.bonusMultiplier, bank.isReset, bank.aprOnReset); uint reward = multiplier.mul(bank.cost).mul(bankCount); accRsrvPerShare = accRsrvPerShare.add(reward.div(bankCount)); } rewards = user.pendingRewards.add(user.count.mul(accRsrvPerShare).div(1e18).sub(user.rewardDebt)); } function getBankCount(address _account) external view returns (uint[] memory count) { count = new uint[](bankInfo.length); for (uint id = 0; id < totalBankTypes(); id++) { count[id] = getBankCountForType(_account, id); } } function getBankCountForType(address _account, uint _id) public view returns (uint count) { return userBankInfo[_id][_account].count; } function isAboveReserve(address _account) public view returns (bool passed, uint amountNedeed) { uint currentPrice = oracle.getCurrentPrice(); uint amountRequired; for (uint id = 0; id < totalBankTypes(); id++) { amountRequired = amountRequired.add(getRequiredReserveForType(_account, id, currentPrice)); } uint slippageAmount = amountRequired.mul(slippage).div(_DENOMINATOR); uint minimumAmountRequired = amountRequired.sub(slippageAmount); if (userReserve[_account] >= minimumAmountRequired) { passed = true; amountNedeed = 0; } else { passed = false; amountNedeed = amountRequired.sub(userReserve[_account]); } } function getCurrentReserveInUsd(address _account) external view returns (uint reserveInUsd) { return userReserve[_account].mul(oracle.getCurrentPrice()).div(1e18); } function getRequiredReserveForType(address _account, uint _id, uint _currentPrice) public view returns (uint amountRequired) { uint requiredReserveInUsd = getRequiredReserveInUsdForType(_account, _id).mul(1e18); amountRequired = requiredReserveInUsd.mul(1e18).div(_currentPrice); } function getRequiredReserveInUsd(address _account) public view returns (uint reserveAmount) { for (uint id = 0; id < totalBankTypes(); id++) { reserveAmount = reserveAmount.add(getRequiredReserveInUsdForType(_account, id)); } } function getRequiredReserveInUsdForType(address _account, uint _id) public view returns (uint reserveAmount) { uint count = getBankCountForType(_account, _id); reserveAmount = bankInfo[_id].reserveAmount.mul(count); } function totalBankTypes() public view returns (uint) { return bankInfo.length; } function hasUserMigrated(address _account) external view returns (bool) { return _userMigrated[_account]; } /** INTERNAL FUNCTIONS **/ function getMultiplier(uint _from, uint _to, uint _bonusMultiplier, bool _isReset, uint _aprOnReset) internal view returns (uint) { if (_to < _from) return 0; uint base; if (_isReset) { base = _aprOnReset.mul(1e18).div(_DENOMINATOR).div(365 days); return _to.sub(_from).mul(base); } else { base = baseApr.mul(1e18).div(_DENOMINATOR).div(365 days); return _to.sub(_from).mul(base).mul(_bonusMultiplier).div(_DENOMINATOR); } } function massUpdate(bool _updateApr) internal { for (uint id = 0; id < totalBankTypes(); id++) { updateBankType(id, false); } if (_updateApr) _setApr(); } function updateBankType(uint _id, bool _updateApr) internal { BankInfo storage bank = bankInfo[_id]; if (block.timestamp <= bank.lastRewardTimestamp) { if (_updateApr) _setApr(); return; } uint bankCount = totalBankCountPerType[_id]; if (bankCount == 0) { bank.lastRewardTimestamp = block.timestamp; if (_updateApr) _setApr(); return; } uint multiplier = getMultiplier(bank.lastRewardTimestamp, block.timestamp, bank.bonusMultiplier, bank.isReset, bank.aprOnReset); if (multiplier > 0) { uint reward = multiplier.mul(bank.cost).mul(bankCount); rsrv.mint(reward.div(1e18)); bank.accRsrvPerShare = bank.accRsrvPerShare.add(reward.div(bankCount)); } bank.lastRewardTimestamp = block.timestamp; if (_updateApr) _setApr(); } function safeRsrvTransfer(address _recipient, uint _amount) internal { uint balance = rsrv.balanceOf(address(this)); if (_amount > balance) { _amount = balance; } SafeERC20.safeTransfer(rsrv, _recipient, _amount); } function _setApr() internal { uint _baseApr = oracle.setCurrentMultiplier(); if (_baseApr == 1) { for (uint id = 0; id < totalBankTypes(); id++) { bankInfo[id].isReset = true; } baseApr = _DENOMINATOR; } else { baseApr = _baseApr; } } function _purchase(address _account, uint _id, uint _count) internal returns (uint _cost) { require (_id < totalBankTypes(), "!ID"); require (_count > 0, "!ZERO"); updateBankType(_id, true); BankInfo memory bank = bankInfo[_id]; require(!bank.isReset, "!DIS"); UserBankInfo storage user = userBankInfo[_id][_account]; _cost = _count.mul(bank.cost); if (user.count > 0) { uint pendingRewards = user.count.mul(bank.accRsrvPerShare).div(1e18).sub(user.rewardDebt); if (pendingRewards > 0) { user.pendingRewards = user.pendingRewards.add(pendingRewards); } } if (_count > 0) { uint currentPrice = oracle.getCurrentPrice(); userReserve[_account] = userReserve[_account].add(_count.mul(bank.reserveAmount).mul(1e36).div(currentPrice)); user.count = user.count.add(_count); totalBankCountPerType[_id] = totalBankCountPerType[_id].add(_count); totalBankCount = totalBankCount.add(_count); } user.rewardDebt = user.count.mul(bank.accRsrvPerShare).div(1e18); emit Purchased(_account, _id, _count); } function _upgrade(address _account, uint _id, uint _count) internal returns (uint _nextUpgradeId) { require (_id < totalBankTypes(), "!ID"); require (_count > 0, "!ZERO"); updateBankType(_id, false); BankInfo memory bank = bankInfo[_id]; require (bank.nextUpgradeId != 0, "!NONE"); UserBankInfo storage user = userBankInfo[_id][_account]; require (user.count >= _count, "!CNT"); if (user.count > 0) { uint pendingRewards = user.count.mul(bank.accRsrvPerShare).div(1e18).sub(user.rewardDebt); if (pendingRewards > 0) { user.pendingRewards = user.pendingRewards.add(pendingRewards); } } _nextUpgradeId = bank.nextUpgradeId; updateBankType(_nextUpgradeId, true); BankInfo memory _upgradeBank = bankInfo[_nextUpgradeId]; UserBankInfo storage _upgradeUser = userBankInfo[_nextUpgradeId][_account]; if (_upgradeUser.count > 0) { uint pendingRewards = _upgradeUser.count.mul(_upgradeBank.accRsrvPerShare).div(1e18).sub(_upgradeUser.rewardDebt); if (pendingRewards > 0) { _upgradeUser.pendingRewards = _upgradeUser.pendingRewards.add(pendingRewards); } } user.count = user.count.sub(_count); totalBankCountPerType[_id] = totalBankCountPerType[_id].sub(_count); user.rewardDebt = user.count.mul(bank.accRsrvPerShare).div(1e18); uint currentPrice = oracle.getCurrentPrice(); uint reserveToRemove = _count.mul(bank.reserveAmount).mul(1e36).div(currentPrice); if (reserveToRemove > userReserve[_account]) { userReserve[_account] = 0; } else { userReserve[_account] = userReserve[_account].sub(reserveToRemove); } userReserve[_account] = userReserve[_account].add(_count.mul(_upgradeBank.reserveAmount).mul(1e36).div(currentPrice)); _upgradeUser.count = _upgradeUser.count.add(_count); totalBankCountPerType[_nextUpgradeId] = totalBankCountPerType[_nextUpgradeId].add(_count); _upgradeUser.rewardDebt = _upgradeUser.count.mul(_upgradeBank.accRsrvPerShare).div(1e18); emit Upgraded(_account, _id, _nextUpgradeId, _count); } function _processRewards(address _account, uint _id) internal { require (_id < totalBankTypes(), "!ID"); BankInfo memory bank = bankInfo[_id]; UserBankInfo storage user = userBankInfo[_id][_account]; if (user.count > 0) { uint pendingRewards = user.count.mul(bank.accRsrvPerShare).div(1e18).sub(user.rewardDebt); if (pendingRewards > 0) { user.pendingRewards = user.pendingRewards.add(pendingRewards); } } user.rewardDebt = user.count.mul(bank.accRsrvPerShare).div(1e18); } function _claim(address _account) internal { massUpdate(true); uint totalRewards; for (uint id = 0; id < totalBankTypes(); id++) { _processRewards(_account, id); totalRewards = totalRewards.add(userBankInfo[id][_account].pendingRewards); userBankInfo[id][_account].pendingRewards = 0; } withdrawableRewards[_account] = withdrawableRewards[_account].add(totalRewards); } /** PUBLIC FUNCTIONS **/ function purchaseBank(uint _id, uint _count) external nonReentrant { uint cost = _purchase(_msgSender(), _id, _count); SafeERC20.safeTransferFrom(rsrv, _msgSender(), deadAddress, cost); } function claimBank(address _account, uint _id, uint _count) external returns (uint cost) { require (_msgSender() == address(brokerage) || _isWhitelisted[_msgSender()], "!WL"); cost = _purchase(_account, _id, _count); } function upgradeBank(uint _id, uint _count) external nonReentrant { uint nextUpgradeId = _upgrade(_msgSender(), _id, _count); uint cost = _count.mul(bankInfo[nextUpgradeId].cost.sub(bankInfo[_id].cost)); SafeERC20.safeTransferFrom(rsrv, _msgSender(), deadAddress, cost); } function claimUpgrade(address _account, uint _id, uint _count) external returns (uint cost) { require (_msgSender() == address(brokerage) || _isWhitelisted[_msgSender()], "!WL"); uint nextUpgradeId = _upgrade(_account, _id, _count); cost = _count.mul(bankInfo[nextUpgradeId].cost.sub(bankInfo[_id].cost)); } function coverReserve(bool _fromRewards, bool _claimRest) external { (bool passed, uint amountNeeded) = isAboveReserve(_msgSender()); _claim(_msgSender()); if (!passed) { if (_fromRewards) { require (withdrawableRewards[_msgSender()] > amountNeeded, "!NE"); withdrawableRewards[_msgSender()] = withdrawableRewards[_msgSender()].sub(amountNeeded); userReserve[_msgSender()] = userReserve[_msgSender()].add(amountNeeded); if (_claimRest) { uint amount = withdrawableRewards[_msgSender()]; safeRsrvTransfer(_msgSender(), amount); withdrawableRewards[_msgSender()] = 0; emit Claimed(_msgSender(), amount); } } else { SafeERC20.safeTransferFrom(rsrv, _msgSender(), deadAddress, amountNeeded); userReserve[_msgSender()] = userReserve[_msgSender()].add(amountNeeded); if (_claimRest) { uint amount = withdrawableRewards[_msgSender()]; safeRsrvTransfer(_msgSender(), amount); withdrawableRewards[_msgSender()] = 0; emit Claimed(_msgSender(), amount); } } } } function claimRewards() external nonReentrant { (bool passed, ) = isAboveReserve(_msgSender()); require (passed, "!RSRV"); _claim(_msgSender()); uint amount = withdrawableRewards[_msgSender()]; safeRsrvTransfer(_msgSender(), amount); withdrawableRewards[_msgSender()] = 0; emit Claimed(_msgSender(), amount); } function compoundRewards(uint _id, uint _count, bool _claimRest) external nonReentrant { (bool passed, ) = isAboveReserve(_msgSender()); require (passed, "!RSRV"); _claim(_msgSender()); uint cost = _purchase(_msgSender(), _id, _count); require (withdrawableRewards[_msgSender()] >= cost, "!NE"); uint left = withdrawableRewards[_msgSender()].sub(cost); withdrawableRewards[_msgSender()] = left; if (left > 0 && _claimRest) { safeRsrvTransfer(_msgSender(), left); withdrawableRewards[_msgSender()] = 0; emit Claimed(_msgSender(), left); } } function burnAndVestRewards(uint _amount, uint _period, bool _claimRest) external nonReentrant { require (address(brokerage) != address(0), "!ADDRESS"); (bool passed, ) = isAboveReserve(_msgSender()); require (passed, "!RSRV"); _claim(_msgSender()); require (withdrawableRewards[_msgSender()] >= _amount, "!NE"); brokerage.burnAndVest(_amount, _period, _msgSender()); SafeERC20.safeTransfer(rsrv, deadAddress, _amount); uint left = withdrawableRewards[_msgSender()].sub(_amount); withdrawableRewards[_msgSender()] = left; if (left > 0 && _claimRest) { safeRsrvTransfer(_msgSender(), left); withdrawableRewards[_msgSender()] = 0; emit Claimed(_msgSender(), left); } } /** MIGRATION FROM V1 **/ function migrate() external nonReentrant { require (!_userMigrated[_msgSender()], "MIG"); IReserve reserveV1 = IReserve(0xD6b5BfCfa8D012b2C4Db0Ae3f912CC9fa6ed5B8D); uint rewards = reserveV1.getRewards(_msgSender()); if (rewards > 0) { rsrv.mint(rewards); withdrawableRewards[_msgSender()] = withdrawableRewards[_msgSender()].add(rewards); } for (uint id = 0; id < reserveV1.totalBankTypes(); id++) { uint count = reserveV1.getBankCountForType(_msgSender(), id); if (count > 0) _purchase(_msgSender(), id, count); } userReserve[_msgSender()] = reserveV1.userReserve(_msgSender()); _userMigrated[_msgSender()] = true; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.9.0) (access/Ownable.sol) pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _transferOwnership(_msgSender()); } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { _checkOwner(); _; } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { require(owner() == _msgSender(), "Ownable: caller is not the owner"); } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby disabling any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.9.0) (security/ReentrancyGuard.sol) pragma solidity ^0.8.0; /** * @dev Contract module that helps prevent reentrant calls to a function. * * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier * available, which can be applied to functions to make sure there are no nested * (reentrant) calls to them. * * Note that because there is a single `nonReentrant` guard, functions marked as * `nonReentrant` may not call one another. This can be worked around by making * those functions `private`, and then adding `external` `nonReentrant` entry * points to them. * * TIP: If you would like to learn more about reentrancy and alternative ways * to protect against it, check out our blog post * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul]. */ abstract contract ReentrancyGuard { // Booleans are more expensive than uint256 or any type that takes up a full // word because each write operation emits an extra SLOAD to first read the // slot's contents, replace the bits taken up by the boolean, and then write // back. This is the compiler's defense against contract upgrades and // pointer aliasing, and it cannot be disabled. // The values being non-zero value makes deployment a bit more expensive, // but in exchange the refund on every call to nonReentrant will be lower in // amount. Since refunds are capped to a percentage of the total // transaction's gas, it is best to keep them low in cases like this one, to // increase the likelihood of the full refund coming into effect. uint256 private constant _NOT_ENTERED = 1; uint256 private constant _ENTERED = 2; uint256 private _status; constructor() { _status = _NOT_ENTERED; } /** * @dev Prevents a contract from calling itself, directly or indirectly. * Calling a `nonReentrant` function from another `nonReentrant` * function is not supported. It is possible to prevent this from happening * by making the `nonReentrant` function external, and making it call a * `private` function that does the actual work. */ modifier nonReentrant() { _nonReentrantBefore(); _; _nonReentrantAfter(); } function _nonReentrantBefore() private { // On the first call to nonReentrant, _status will be _NOT_ENTERED require(_status != _ENTERED, "ReentrancyGuard: reentrant call"); // Any calls to nonReentrant after this point will fail _status = _ENTERED; } function _nonReentrantAfter() private { // By storing the original value once again, a refund is triggered (see // https://eips.ethereum.org/EIPS/eip-2200) _status = _NOT_ENTERED; } /** * @dev Returns true if the reentrancy guard is currently set to "entered", which indicates there is a * `nonReentrant` function in the call stack. */ function _reentrancyGuardEntered() internal view returns (bool) { return _status == _ENTERED; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/extensions/IERC20Permit.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612]. * * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by * presenting a message signed by the account. By not relying on {IERC20-approve}, the token holder account doesn't * need to send a transaction, and thus is not required to hold Ether at all. */ interface IERC20Permit { /** * @dev Sets `value` as the allowance of `spender` over ``owner``'s tokens, * given ``owner``'s signed approval. * * IMPORTANT: The same issues {IERC20-approve} has related to transaction * ordering also apply here. * * Emits an {Approval} event. * * Requirements: * * - `spender` cannot be the zero address. * - `deadline` must be a timestamp in the future. * - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner` * over the EIP712-formatted function arguments. * - the signature must use ``owner``'s current nonce (see {nonces}). * * For more information on the signature format, see the * https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP * section]. */ function permit( address owner, address spender, uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s ) external; /** * @dev Returns the current nonce for `owner`. This value must be * included whenever a signature is generated for {permit}. * * Every successful call to {permit} increases ``owner``'s nonce by one. This * prevents a signature from being used multiple times. */ function nonces(address owner) external view returns (uint256); /** * @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}. */ // solhint-disable-next-line func-name-mixedcase function DOMAIN_SEPARATOR() external view returns (bytes32); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/IERC20.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `to`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address to, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an {Approval} event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `from` to `to` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom(address from, address to, uint256 amount) external returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/utils/SafeERC20.sol) pragma solidity ^0.8.0; import "../IERC20.sol"; import "../extensions/IERC20Permit.sol"; import "../../../utils/Address.sol"; /** * @title SafeERC20 * @dev Wrappers around ERC20 operations that throw on failure (when the token * contract returns false). Tokens that return no value (and instead revert or * throw on failure) are also supported, non-reverting calls are assumed to be * successful. * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract, * which allows you to call the safe operations as `token.safeTransfer(...)`, etc. */ library SafeERC20 { using Address for address; /** * @dev Transfer `value` amount of `token` from the calling contract to `to`. If `token` returns no value, * non-reverting calls are assumed to be successful. */ function safeTransfer(IERC20 token, address to, uint256 value) internal { _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value)); } /** * @dev Transfer `value` amount of `token` from `from` to `to`, spending the approval given by `from` to the * calling contract. If `token` returns no value, non-reverting calls are assumed to be successful. */ function safeTransferFrom(IERC20 token, address from, address to, uint256 value) internal { _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value)); } /** * @dev Deprecated. This function has issues similar to the ones found in * {IERC20-approve}, and its usage is discouraged. * * Whenever possible, use {safeIncreaseAllowance} and * {safeDecreaseAllowance} instead. */ function safeApprove(IERC20 token, address spender, uint256 value) internal { // safeApprove should only be called when setting an initial allowance, // or when resetting it to zero. To increase and decrease it, use // 'safeIncreaseAllowance' and 'safeDecreaseAllowance' require( (value == 0) || (token.allowance(address(this), spender) == 0), "SafeERC20: approve from non-zero to non-zero allowance" ); _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value)); } /** * @dev Increase the calling contract's allowance toward `spender` by `value`. If `token` returns no value, * non-reverting calls are assumed to be successful. */ function safeIncreaseAllowance(IERC20 token, address spender, uint256 value) internal { uint256 oldAllowance = token.allowance(address(this), spender); _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, oldAllowance + value)); } /** * @dev Decrease the calling contract's allowance toward `spender` by `value`. If `token` returns no value, * non-reverting calls are assumed to be successful. */ function safeDecreaseAllowance(IERC20 token, address spender, uint256 value) internal { unchecked { uint256 oldAllowance = token.allowance(address(this), spender); require(oldAllowance >= value, "SafeERC20: decreased allowance below zero"); _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, oldAllowance - value)); } } /** * @dev Set the calling contract's allowance toward `spender` to `value`. If `token` returns no value, * non-reverting calls are assumed to be successful. Compatible with tokens that require the approval to be set to * 0 before setting it to a non-zero value. */ function forceApprove(IERC20 token, address spender, uint256 value) internal { bytes memory approvalCall = abi.encodeWithSelector(token.approve.selector, spender, value); if (!_callOptionalReturnBool(token, approvalCall)) { _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, 0)); _callOptionalReturn(token, approvalCall); } } /** * @dev Use a ERC-2612 signature to set the `owner` approval toward `spender` on `token`. * Revert on invalid signature. */ function safePermit( IERC20Permit token, address owner, address spender, uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s ) internal { uint256 nonceBefore = token.nonces(owner); token.permit(owner, spender, value, deadline, v, r, s); uint256 nonceAfter = token.nonces(owner); require(nonceAfter == nonceBefore + 1, "SafeERC20: permit did not succeed"); } /** * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement * on the return value: the return value is optional (but if data is returned, it must not be false). * @param token The token targeted by the call. * @param data The call data (encoded using abi.encode or one of its variants). */ function _callOptionalReturn(IERC20 token, bytes memory data) private { // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since // we're implementing it ourselves. We use {Address-functionCall} to perform this call, which verifies that // the target address contains contract code and also asserts for success in the low-level call. bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed"); require(returndata.length == 0 || abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed"); } /** * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement * on the return value: the return value is optional (but if data is returned, it must not be false). * @param token The token targeted by the call. * @param data The call data (encoded using abi.encode or one of its variants). * * This is a variant of {_callOptionalReturn} that silents catches all reverts and returns a bool instead. */ function _callOptionalReturnBool(IERC20 token, bytes memory data) private returns (bool) { // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since // we're implementing it ourselves. We cannot use {Address-functionCall} here since this should return false // and not revert is the subcall reverts. (bool success, bytes memory returndata) = address(token).call(data); return success && (returndata.length == 0 || abi.decode(returndata, (bool))) && Address.isContract(address(token)); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.9.0) (utils/Address.sol) pragma solidity ^0.8.1; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * * Furthermore, `isContract` will also return true if the target contract within * the same transaction is already scheduled for destruction by `SELFDESTRUCT`, * which only has an effect at the end of a transaction. * ==== * * [IMPORTANT] * ==== * You shouldn't rely on `isContract` to protect against flash loan attacks! * * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract * constructor. * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize/address.code.length, which returns 0 // for contracts in construction, since the code is only stored at the end // of the constructor execution. return account.code.length > 0; } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://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.0/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ */ function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResultFromTarget(target, success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResultFromTarget(target, success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResultFromTarget(target, success, returndata, errorMessage); } /** * @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling * the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract. * * _Available since v4.8._ */ function verifyCallResultFromTarget( address target, bool success, bytes memory returndata, string memory errorMessage ) internal view returns (bytes memory) { if (success) { if (returndata.length == 0) { // only check isContract if the call was successful and the return data is empty // otherwise we already know that it was a contract require(isContract(target), "Address: call to non-contract"); } return returndata; } else { _revert(returndata, errorMessage); } } /** * @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason or using the provided one. * * _Available since v4.3._ */ function verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) internal pure returns (bytes memory) { if (success) { return returndata; } else { _revert(returndata, errorMessage); } } function _revert(bytes memory returndata, string memory errorMessage) private pure { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly /// @solidity memory-safe-assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.9.0) (utils/math/SafeMath.sol) pragma solidity ^0.8.0; // CAUTION // This version of SafeMath should only be used with Solidity 0.8 or later, // because it relies on the compiler's built in overflow checks. /** * @dev Wrappers over Solidity's arithmetic operations. * * NOTE: `SafeMath` is generally not needed starting with Solidity 0.8, since the compiler * now has built in overflow checking. */ library SafeMath { /** * @dev Returns the addition of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { uint256 c = a + b; if (c < a) return (false, 0); return (true, c); } } /** * @dev Returns the subtraction of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b > a) return (false, 0); return (true, a - b); } } /** * @dev Returns the multiplication of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == 0) return (true, 0); uint256 c = a * b; if (c / a != b) return (false, 0); return (true, c); } } /** * @dev Returns the division of two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a / b); } } /** * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a % b); } } /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { return a + b; } /** * @dev Returns the subtraction of two unsigned integers, reverting on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { return a - b; } /** * @dev Returns the multiplication of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * * - Multiplication cannot overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { return a * b; } /** * @dev Returns the integer division of two unsigned integers, reverting on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. * * Requirements: * * - The divisor cannot be zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { return a / b; } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { return a % b; } /** * @dev Returns the subtraction of two unsigned integers, reverting with custom message on * overflow (when the result is negative). * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {trySub}. * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { unchecked { require(b <= a, errorMessage); return a - b; } } /** * @dev Returns the integer division of two unsigned integers, reverting with custom message on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a / b; } } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting with custom message when dividing by zero. * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {tryMod}. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a % b; } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; interface IReserve { function userReserve(address _account) external view returns (uint); function totalBankTypes() external view returns (uint); function getBankCountForType(address _account, uint _id) external view returns (uint count); function getRewards(address _account) external view returns (uint rewards); function claimBank(address _account, uint _id, uint _count) external returns (uint cost); function claimUpgrade(address _account, uint _id, uint _count) external returns (uint cost); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; interface IReserveBrokerage { function burnAndVest(uint amount, uint period, address account) external; function depositTokens(uint amount) external; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; interface IReserveOracle { function activeMultiplier() external view returns (uint); function getCurrentPrice() external view returns (uint); function getCurrentMarketCap() external view returns (uint); function getCirculatingSupply() external view returns (uint); function getPercentageFromAth() external view returns (uint percentage); function setCurrentMultiplier() external returns (uint); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; interface IRSRV is IERC20 { function uniswapV2Router() external view returns (address); function uniswapV2Pair() external view returns (address); function mint(uint amount) external; }
{ "optimizer": { "enabled": false, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address","name":"_rsrv","type":"address"},{"internalType":"uint256","name":"_startTimestamp","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Claimed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"count","type":"uint256"}],"name":"Purchased","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"upgradeId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"count","type":"uint256"}],"name":"Upgraded","type":"event"},{"inputs":[{"internalType":"uint256","name":"_id","type":"uint256"},{"internalType":"uint256","name":"_cost","type":"uint256"}],"name":"add","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"bankInfo","outputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"cost","type":"uint256"},{"internalType":"uint256","name":"bonusMultiplier","type":"uint256"},{"internalType":"uint256","name":"reserveAmount","type":"uint256"},{"internalType":"uint256","name":"lastRewardTimestamp","type":"uint256"},{"internalType":"uint256","name":"accRsrvPerShare","type":"uint256"},{"internalType":"uint256","name":"nextUpgradeId","type":"uint256"},{"internalType":"bool","name":"isReset","type":"bool"},{"internalType":"uint256","name":"aprOnReset","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"baseApr","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"brokerage","outputs":[{"internalType":"contract IReserveBrokerage","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"uint256","name":"_period","type":"uint256"},{"internalType":"bool","name":"_claimRest","type":"bool"}],"name":"burnAndVestRewards","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"uint256","name":"_id","type":"uint256"},{"internalType":"uint256","name":"_count","type":"uint256"}],"name":"claimBank","outputs":[{"internalType":"uint256","name":"cost","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"claimRewards","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"uint256","name":"_id","type":"uint256"},{"internalType":"uint256","name":"_count","type":"uint256"}],"name":"claimUpgrade","outputs":[{"internalType":"uint256","name":"cost","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_id","type":"uint256"},{"internalType":"uint256","name":"_count","type":"uint256"},{"internalType":"bool","name":"_claimRest","type":"bool"}],"name":"compoundRewards","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_fromRewards","type":"bool"},{"internalType":"bool","name":"_claimRest","type":"bool"}],"name":"coverReserve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"deadAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"depositToBrokerage","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"getBankCount","outputs":[{"internalType":"uint256[]","name":"count","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"uint256","name":"_id","type":"uint256"}],"name":"getBankCountForType","outputs":[{"internalType":"uint256","name":"count","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"getCurrentReserveInUsd","outputs":[{"internalType":"uint256","name":"reserveInUsd","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"uint256","name":"_id","type":"uint256"}],"name":"getPendingRewards","outputs":[{"internalType":"uint256","name":"rewards","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"getPendingRewards","outputs":[{"internalType":"uint256","name":"rewards","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"uint256","name":"_id","type":"uint256"},{"internalType":"uint256","name":"_currentPrice","type":"uint256"}],"name":"getRequiredReserveForType","outputs":[{"internalType":"uint256","name":"amountRequired","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"getRequiredReserveInUsd","outputs":[{"internalType":"uint256","name":"reserveAmount","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"uint256","name":"_id","type":"uint256"}],"name":"getRequiredReserveInUsdForType","outputs":[{"internalType":"uint256","name":"reserveAmount","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"uint256","name":"_id","type":"uint256"}],"name":"getRewardRate","outputs":[{"internalType":"uint256","name":"rewardRate","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"getRewardRate","outputs":[{"internalType":"uint256","name":"rewardRate","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"getRewards","outputs":[{"internalType":"uint256","name":"rewards","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"hasUserMigrated","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"isAboveReserve","outputs":[{"internalType":"bool","name":"passed","type":"bool"},{"internalType":"uint256","name":"amountNedeed","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"migrate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"oracle","outputs":[{"internalType":"contract IReserveOracle","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_id","type":"uint256"},{"internalType":"uint256","name":"_count","type":"uint256"}],"name":"purchaseBank","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rsrv","outputs":[{"internalType":"contract IRSRV","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_id","type":"uint256"},{"internalType":"uint256","name":"_cost","type":"uint256"},{"internalType":"uint256","name":"_multiplier","type":"uint256"},{"internalType":"uint256","name":"_reserveAmount","type":"uint256"},{"internalType":"uint256","name":"_nextUpgradeId","type":"uint256"},{"internalType":"uint256","name":"_aprOnReset","type":"uint256"}],"name":"set","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_brokerage","type":"address"}],"name":"setBrokerage","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_oracle","type":"address"}],"name":"setOracle","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"startTimestamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalBankCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"totalBankCountPerType","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalBankTypes","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"triggerAprUpdate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_id","type":"uint256"},{"internalType":"uint256","name":"_count","type":"uint256"}],"name":"upgradeBank","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"","type":"address"}],"name":"userBankInfo","outputs":[{"internalType":"uint256","name":"count","type":"uint256"},{"internalType":"uint256","name":"pendingRewards","type":"uint256"},{"internalType":"uint256","name":"rewardDebt","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"userReserve","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"withdrawableRewards","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
60a060405261271060045560326005553480156200001c57600080fd5b506040516200669a3803806200669a8339818101604052810190620000429190620005b1565b62000062620000566200042860201b60201c565b6200043060201b60201c565b600180819055508173ffffffffffffffffffffffffffffffffffffffff1660808173ffffffffffffffffffffffffffffffffffffffff168152505080600c81905550600660405180610120016040528060008152602001620000d7670de0b6b3a76400006064620004f460201b90919060201c565b8152602001614e2081526020016005815260200183815260200160008152602001600181526020016000151581526020016103208152509080600181540180825580915050600190039060005260206000209060090201600090919091909150600082015181600001556020820151816001015560408201518160020155606082015181600301556080820151816004015560a0820151816005015560c0820151816006015560e08201518160070160006101000a81548160ff02191690831515021790555061010082015181600801555050600660405180610120016040528060018152602001620001de670de0b6b3a76400006101f4620004f460201b90919060201c565b8152602001619c4081526020016032815260200183815260200160008152602001600281526020016000151581526020016104b08152509080600181540180825580915050600190039060005260206000209060090201600090919091909150600082015181600001556020820151816001015560408201518160020155606082015181600301556080820151816004015560a0820151816005015560c0820151816006015560e08201518160070160006101000a81548160ff02191690831515021790555061010082015181600801555050600660405180610120016040528060028152602001620002e5670de0b6b3a76400006107d0620004f460201b90919060201c565b8152602001620186a0815260200160fa815260200183815260200160008152602001600081526020016000151581526020016107d08152509080600181540180825580915050600190039060005260206000209060090201600090919091909150600082015181600001556020820151816001015560408201518160020155606082015181600301556080820151816004015560a0820151816005015560c0820151816006015560e08201518160070160006101000a81548160ff021916908315150217905550610100820151816008015550506001600d6000620003cf6200042860201b60201c565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff021916908315150217905550505062000672565b600033905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b6000818362000504919062000627565b905092915050565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006200053e8262000511565b9050919050565b620005508162000531565b81146200055c57600080fd5b50565b600081519050620005708162000545565b92915050565b6000819050919050565b6200058b8162000576565b81146200059757600080fd5b50565b600081519050620005ab8162000580565b92915050565b60008060408385031215620005cb57620005ca6200050c565b5b6000620005db858286016200055f565b9250506020620005ee858286016200059a565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000620006348262000576565b9150620006418362000576565b9250828202620006518162000576565b915082820484148315176200066b576200066a620005f8565b5b5092915050565b608051615fc6620006d460003960008181610cc801528181611727015281816118000152818161188b01528181611e680152818161269b015281816128ee015281816130f20152818161332c015281816133d7015261496e0152615fc66000f3fe608060405234801561001057600080fd5b50600436106102745760003560e01c80637adbf97311610151578063b8d94d7d116100c3578063ea7cbff111610087578063ea7cbff1146107b6578063f2fde38b146107e6578063f50edc8614610802578063f69f408014610832578063f6ed201714610862578063f7023ac51461089257610274565b8063b8d94d7d146106fd578063dfa7e6b11461071b578063e05916d614610737578063e4e7c6b414610768578063e6fd48bc1461079857610274565b8063940973d911610115578063940973d91461062157806399c6f7e214610659578063a2908e2b14610689578063b334e88314610693578063b71cdc7d146106c3578063b80cd14e146106df57610274565b80637adbf9731461058f5780637dc0d1d0146105ab578063806672b3146105c95780638da5cb5b146105f95780638fd3ab801461061757610274565b806336dbef04116101ea57806340cb7660116101ae57806340cb7660146104e55780634aa116ec146105015780635d7555541461051d578063715018a614610539578063771602f71461054357806379ee54f71461055f57610274565b806336dbef041461043f578063372500ab1461046f5780633c2a27f2146104795780633fbf444e146104955780633fed8b15146104b357610274565b806317deeccb1161023c57806317deeccb146103435780631922cd3a146103735780631942a1a0146103a357806323ba4644146103c157806327c8f835146103f15780632c0bb50c1461040f57610274565b8063034c1a921461027957806304506c2e146102a95780630c57ac26146102c75780630d64b2c0146102e35780630f14b4d614610313575b600080fd5b610293600480360381019061028e9190614db0565b6108ae565b6040516102a09190614df6565b60405180910390f35b6102b16109b3565b6040516102be9190614df6565b60405180910390f35b6102e160048036038101906102dc9190614e49565b6109b9565b005b6102fd60048036038101906102f89190614eb5565b610ea8565b60405161030a9190614df6565b60405180910390f35b61032d60048036038101906103289190614db0565b610ec0565b60405161033a9190614df6565b60405180910390f35b61035d60048036038101906103589190614ee2565b610ed8565b60405161036a9190614df6565b60405180910390f35b61038d60048036038101906103889190614f22565b610f36565b60405161039a9190614df6565b60405180910390f35b6103ab61103e565b6040516103b89190614df6565b60405180910390f35b6103db60048036038101906103d69190614db0565b611044565b6040516103e89190614f84565b60405180910390f35b6103f961109a565b6040516104069190614fae565b60405180910390f35b61042960048036038101906104249190614ee2565b6110a0565b6040516104369190614df6565b60405180910390f35b61045960048036038101906104549190614db0565b611266565b6040516104669190614df6565b60405180910390f35b6104776112b4565b005b610493600480360381019061048e9190614db0565b61142a565b005b61049d6114e5565b6040516104aa9190615028565b60405180910390f35b6104cd60048036038101906104c89190615043565b61150b565b6040516104dc93929190615083565b60405180910390f35b6104ff60048036038101906104fa91906150ba565b611542565b005b61051b60048036038101906105169190615147565b611691565b005b61053760048036038101906105329190614eb5565b611765565b005b6105416119da565b005b61055d60048036038101906105589190615147565b6119ee565b005b61057960048036038101906105749190614db0565b611b66565b6040516105869190614df6565b60405180910390f35b6105a960048036038101906105a49190614db0565b611bc9565b005b6105b3611c84565b6040516105c091906151a8565b60405180910390f35b6105e360048036038101906105de9190614ee2565b611caa565b6040516105f09190614df6565b60405180910390f35b610601611cfa565b60405161060e9190614fae565b60405180910390f35b61061f611d23565b005b61063b60048036038101906106369190614eb5565b6121fd565b604051610650999897969594939291906151c3565b60405180910390f35b610673600480360381019061066e9190614f22565b612268565b6040516106809190614df6565b60405180910390f35b6106916123e4565b005b6106ad60048036038101906106a89190614db0565b6123f8565b6040516106ba9190614df6565b60405180910390f35b6106dd60048036038101906106d89190615250565b612410565b005b6106e7612699565b6040516106f491906152c4565b60405180910390f35b6107056126bd565b6040516107129190614df6565b60405180910390f35b61073560048036038101906107309190615250565b6126ca565b005b610751600480360381019061074c9190614db0565b612a92565b60405161075f9291906152df565b60405180910390f35b610782600480360381019061077d9190614ee2565b612c6d565b60405161078f9190614df6565b60405180910390f35b6107a0612ea4565b6040516107ad9190614df6565b60405180910390f35b6107d060048036038101906107cb9190614db0565b612eaa565b6040516107dd9190614df6565b60405180910390f35b61080060048036038101906107fb9190614db0565b612ef8565b005b61081c60048036038101906108179190614f22565b612f7b565b6040516108299190614df6565b60405180910390f35b61084c60048036038101906108479190614db0565b612fdb565b60405161085991906153c6565b60405180910390f35b61087c60048036038101906108779190614db0565b613081565b6040516108899190614df6565b60405180910390f35b6108ac60048036038101906108a79190615147565b6130cf565b005b60006109ac670de0b6b3a764000061099e600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663eb91d37e6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561092c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061095091906153fd565b600860008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461312f90919063ffffffff16565b61314590919063ffffffff16565b9050919050565b600b5481565b6000806109cc6109c761315b565b612a92565b915091506109e06109db61315b565b613163565b81610ea2578315610cc35780600960006109f861315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205411610a73576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610a6a90615487565b60405180910390fd5b610acc8160096000610a8361315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020546132fc90919063ffffffff16565b60096000610ad861315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610b6f8160086000610b2661315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461331290919063ffffffff16565b60086000610b7b61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508215610cbe57600060096000610bcd61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050610c1b610c1561315b565b82613328565b600060096000610c2961315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610c6f61315b565b73ffffffffffffffffffffffffffffffffffffffff167fd8138f8a3f377c5259ca548e70e4c2de94f129f5a11036a15b69513cba2b426a82604051610cb49190614df6565b60405180910390a2505b610ea1565b610cf87f0000000000000000000000000000000000000000000000000000000000000000610cef61315b565b61dead84613402565b610d518160086000610d0861315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461331290919063ffffffff16565b60086000610d5d61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508215610ea057600060096000610daf61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050610dfd610df761315b565b82613328565b600060096000610e0b61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610e5161315b565b73ffffffffffffffffffffffffffffffffffffffff167fd8138f8a3f377c5259ca548e70e4c2de94f129f5a11036a15b69513cba2b426a82604051610e969190614df6565b60405180910390a2505b5b5b50505050565b600a6020528060005260406000206000915090505481565b60096020528060005260406000206000915090505481565b60006007600083815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060000154905092915050565b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16610f7961315b565b73ffffffffffffffffffffffffffffffffffffffff161480610feb5750600d6000610fa261315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff165b61102a576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611021906154f3565b60405180910390fd5b61103584848461348b565b90509392505050565b60045481565b6000600e60008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff169050919050565b61dead81565b600080600683815481106110b7576110b6615513565b5b906000526020600020906009020160405180610120016040529081600082015481526020016001820154815260200160028201548152602001600382015481526020016004820154815260200160058201548152602001600682015481526020016007820160009054906101000a900460ff16151515158152602001600882015481525050905060006007600085815260200190815260200160002060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020604051806060016040529081600082015481526020016001820154815260200160028201548152505090506000600a60008681526020019081526020016000205490506000811461125d57600061120a426111f560014261331290919063ffffffff16565b86604001518760e00151886101000151613984565b9050600061123f670de0b6b3a764000061123187602001518561312f90919063ffffffff16565b61314590919063ffffffff16565b905061125881856000015161312f90919063ffffffff16565b955050505b50505092915050565b600080600090505b6112766126bd565b8110156112ae5761129961128a8483611caa565b8361331290919063ffffffff16565b915080806112a690615571565b91505061126e565b50919050565b6112bc613ab4565b60006112ce6112c961315b565b612a92565b50905080611311576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161130890615605565b60405180910390fd5b61132161131c61315b565b613163565b60006009600061132f61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905061137d61137761315b565b82613328565b60006009600061138b61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506113d161315b565b73ffffffffffffffffffffffffffffffffffffffff167fd8138f8a3f377c5259ca548e70e4c2de94f129f5a11036a15b69513cba2b426a826040516114169190614df6565b60405180910390a25050611428613b03565b565b611432613b0c565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16036114a1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161149890615671565b60405180910390fd5b80600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6007602052816000526040600020602052806000526040600020600091509150508060000154908060010154908060020154905083565b61154a613b0c565b6115526126bd565b8610611593576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161158a906156dd565b60405180910390fd5b61159d6001613b8a565b6115b8670de0b6b3a76400008661312f90919063ffffffff16565b600687815481106115cc576115cb615513565b5b90600052602060002090600902016001018190555083600687815481106115f6576115f5615513565b5b90600052602060002090600902016002018190555082600687815481106116205761161f615513565b5b906000526020600020906009020160030181905550816006878154811061164a57611649615513565b5b906000526020600020906009020160060181905550806006878154811061167457611673615513565b5b906000526020600020906009020160080181905550505050505050565b611699613ab4565b60006116ad6116a661315b565b8484613bcd565b90506000611720611711600686815481106116cb576116ca615513565b5b906000526020600020906009020160010154600685815481106116f1576116f0615513565b5b9060005260206000209060090201600101546132fc90919063ffffffff16565b8461312f90919063ffffffff16565b90506117577f000000000000000000000000000000000000000000000000000000000000000061174e61315b565b61dead84613402565b5050611761613b03565b5050565b61176d613b0c565b600073ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16036117fe576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016117f590615749565b60405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a0712d68826040518263ffffffff1660e01b81526004016118579190614df6565b600060405180830381600087803b15801561187157600080fd5b505af1158015611885573d6000803e3d6000fd5b505050507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663095ea7b3600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16836040518363ffffffff1660e01b8152600401611906929190615769565b6020604051808303816000875af1158015611925573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061194991906157a7565b50600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd49756e826040518263ffffffff1660e01b81526004016119a59190614df6565b600060405180830381600087803b1580156119bf57600080fd5b505af11580156119d3573d6000803e3d6000fd5b5050505050565b6119e2613b0c565b6119ec600061446d565b565b6119f6613b0c565b6119fe6126bd565b8214611a3f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611a36906156dd565b60405180910390fd5b611a496001613b8a565b6000600c544211611a5c57600c54611a5e565b425b90506006604051806101200160405280858152602001611a8f670de0b6b3a76400008661312f90919063ffffffff16565b8152602001612710815260200160008152602001838152602001600081526020016000815260200160001515815260200160008152509080600181540180825580915050600190039060005260206000209060090201600090919091909150600082015181600001556020820151816001015560408201518160020155606082015181600301556080820151816004015560a0820151816005015560c0820151816006015560e08201518160070160006101000a81548160ff02191690831515021790555061010082015181600801555050505050565b6000611bc2611b7483613081565b600960008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461331290919063ffffffff16565b9050919050565b611bd1613b0c565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603611c40576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611c3790615671565b60405180910390fd5b80600360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080611cb78484610ed8565b9050611cf18160068581548110611cd157611cd0615513565b5b90600052602060002090600902016003015461312f90919063ffffffff16565b91505092915050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b611d2b613ab4565b600e6000611d3761315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff1615611dbf576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611db690615820565b60405180910390fd5b600073d6b5bfcfa8d012b2c4db0ae3f912cc9fa6ed5b8d905060008173ffffffffffffffffffffffffffffffffffffffff166379ee54f7611dfe61315b565b6040518263ffffffff1660e01b8152600401611e1a9190614fae565b602060405180830381865afa158015611e37573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e5b91906153fd565b90506000811115611f95577f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a0712d68826040518263ffffffff1660e01b8152600401611ebf9190614df6565b600060405180830381600087803b158015611ed957600080fd5b505af1158015611eed573d6000803e3d6000fd5b50505050611f4a8160096000611f0161315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461331290919063ffffffff16565b60096000611f5661315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505b60005b8273ffffffffffffffffffffffffffffffffffffffff1663b8d94d7d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015611fe3573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061200791906153fd565b8110156120c65760008373ffffffffffffffffffffffffffffffffffffffff166317deeccb61203461315b565b846040518363ffffffff1660e01b8152600401612052929190615769565b602060405180830381865afa15801561206f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061209391906153fd565b905060008111156120b2576120b06120a961315b565b838361348b565b505b5080806120be90615571565b915050611f98565b508173ffffffffffffffffffffffffffffffffffffffff1663b334e8836120eb61315b565b6040518263ffffffff1660e01b81526004016121079190614fae565b602060405180830381865afa158015612124573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061214891906153fd565b6008600061215461315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506001600e60006121a061315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff02191690831515021790555050506121fb613b03565b565b6006818154811061220d57600080fd5b90600052602060002090600902016000915090508060000154908060010154908060020154908060030154908060040154908060050154908060060154908060070160009054906101000a900460ff16908060080154905089565b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166122ab61315b565b73ffffffffffffffffffffffffffffffffffffffff16148061231d5750600d60006122d461315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff165b61235c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612353906154f3565b60405180910390fd5b6000612369858585613bcd565b90506123da6123cb6006868154811061238557612384615513565b5b906000526020600020906009020160010154600684815481106123ab576123aa615513565b5b9060005260206000209060090201600101546132fc90919063ffffffff16565b8461312f90919063ffffffff16565b9150509392505050565b6123ec613b0c565b6123f66001613b8a565b565b60086020528060005260406000206000915090505481565b612418613ab4565b600061242a61242561315b565b612a92565b5090508061246d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161246490615605565b60405180910390fd5b61247d61247861315b565b613163565b600061249161248a61315b565b868661348b565b905080600960006124a061315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054101561251c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161251390615487565b60405180910390fd5b6000612577826009600061252e61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020546132fc90919063ffffffff16565b9050806009600061258661315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506000811180156125d15750835b15612689576125e76125e161315b565b82613328565b6000600960006125f561315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208190555061263b61315b565b73ffffffffffffffffffffffffffffffffffffffff167fd8138f8a3f377c5259ca548e70e4c2de94f129f5a11036a15b69513cba2b426a826040516126809190614df6565b60405180910390a25b505050612694613b03565b505050565b7f000000000000000000000000000000000000000000000000000000000000000081565b6000600680549050905090565b6126d2613ab4565b600073ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1603612763576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161275a90615671565b60405180910390fd5b600061277561277061315b565b612a92565b509050806127b8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016127af90615605565b60405180910390fd5b6127c86127c361315b565b613163565b83600960006127d561315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020541015612851576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161284890615487565b60405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630a6060e4858561289961315b565b6040518463ffffffff1660e01b81526004016128b793929190615840565b600060405180830381600087803b1580156128d157600080fd5b505af11580156128e5573d6000803e3d6000fd5b505050506129167f000000000000000000000000000000000000000000000000000000000000000061dead86614531565b6000612971856009600061292861315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020546132fc90919063ffffffff16565b9050806009600061298061315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506000811180156129cb5750825b15612a83576129e16129db61315b565b82613328565b6000600960006129ef61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550612a3561315b565b73ffffffffffffffffffffffffffffffffffffffff167fd8138f8a3f377c5259ca548e70e4c2de94f129f5a11036a15b69513cba2b426a82604051612a7a9190614df6565b60405180910390a25b5050612a8d613b03565b505050565b6000806000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663eb91d37e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612b04573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612b2891906153fd565b9050600080600090505b612b3a6126bd565b811015612b7357612b5e612b4f878386612f7b565b8361331290919063ffffffff16565b91508080612b6b90615571565b915050612b32565b506000612b9f612710612b916005548561312f90919063ffffffff16565b61314590919063ffffffff16565b90506000612bb682846132fc90919063ffffffff16565b905080600860008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205410612c0b576001955060009450612c64565b60009550612c61600860008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054846132fc90919063ffffffff16565b94505b50505050915091565b60008060068381548110612c8457612c83615513565b5b906000526020600020906009020160405180610120016040529081600082015481526020016001820154815260200160028201548152602001600382015481526020016004820154815260200160058201548152602001600682015481526020016007820160009054906101000a900460ff16151515158152602001600882015481525050905060006007600085815260200190815260200160002060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206040518060600160405290816000820154815260200160018201548152602001600282015481525050905060008260a0015190506000600a6000878152602001908152602001600020549050836080015142118015612dbd575060008114155b15612e3b576000612de285608001514287604001518860e00151896101000151613984565b90506000612e0f83612e0188602001518561312f90919063ffffffff16565b61312f90919063ffffffff16565b9050612e36612e27848361314590919063ffffffff16565b8561331290919063ffffffff16565b935050505b612e98612e858460400151612e77670de0b6b3a7640000612e6987896000015161312f90919063ffffffff16565b61314590919063ffffffff16565b6132fc90919063ffffffff16565b846020015161331290919063ffffffff16565b94505050505092915050565b600c5481565b600080600090505b612eba6126bd565b811015612ef257612edd612ece84836110a0565b8361331290919063ffffffff16565b91508080612eea90615571565b915050612eb2565b50919050565b612f00613b0c565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603612f6f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612f66906158e9565b60405180910390fd5b612f788161446d565b50565b600080612fa2670de0b6b3a7640000612f948787611caa565b61312f90919063ffffffff16565b9050612fd183612fc3670de0b6b3a76400008461312f90919063ffffffff16565b61314590919063ffffffff16565b9150509392505050565b606060068054905067ffffffffffffffff811115612ffc57612ffb615909565b5b60405190808252806020026020018201604052801561302a5781602001602082028036833780820191505090505b50905060005b6130386126bd565b81101561307b576130498382610ed8565b82828151811061305c5761305b615513565b5b602002602001018181525050808061307390615571565b915050613030565b50919050565b600080600090505b6130916126bd565b8110156130c9576130b46130a58483612c6d565b8361331290919063ffffffff16565b915080806130c190615571565b915050613089565b50919050565b6130d7613ab4565b60006130eb6130e461315b565b848461348b565b90506131227f000000000000000000000000000000000000000000000000000000000000000061311961315b565b61dead84613402565b5061312b613b03565b5050565b6000818361313d9190615938565b905092915050565b6000818361315391906159a9565b905092915050565b600033905090565b61316d6001613b8a565b600080600090505b61317d6126bd565b8110156132625761318e83826145b7565b6131f46007600083815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600101548361331290919063ffffffff16565b915060006007600083815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060010181905550808061325a90615571565b915050613175565b506132b581600960008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461331290919063ffffffff16565b600960008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505050565b6000818361330a91906159da565b905092915050565b600081836133209190615a0e565b905092915050565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166370a08231306040518263ffffffff1660e01b81526004016133839190614fae565b602060405180830381865afa1580156133a0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133c491906153fd565b9050808211156133d2578091505b6133fd7f00000000000000000000000000000000000000000000000000000000000000008484614531565b505050565b613485846323b872dd60e01b85858560405160240161342393929190615a42565b604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050506147bb565b50505050565b60006134956126bd565b83106134d6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016134cd906156dd565b60405180910390fd5b60008211613519576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161351090615ac5565b60405180910390fd5b613524836001614883565b60006006848154811061353a57613539615513565b5b906000526020600020906009020160405180610120016040529081600082015481526020016001820154815260200160028201548152602001600382015481526020016004820154815260200160058201548152602001600682015481526020016007820160009054906101000a900460ff1615151515815260200160088201548152505090508060e0015115613606576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016135fd90615b31565b60405180910390fd5b60006007600086815260200190815260200160002060008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905061367182602001518561312f90919063ffffffff16565b92506000816000015411156136fa5760006136cd82600201546136bf670de0b6b3a76400006136b18760a00151876000015461312f90919063ffffffff16565b61314590919063ffffffff16565b6132fc90919063ffffffff16565b905060008111156136f8576136ef81836001015461331290919063ffffffff16565b82600101819055505b505b60008411156138ef576000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663eb91d37e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613772573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061379691906153fd565b90506138336137e5826137d76ec097ce7bc90715b34b9f10000000006137c988606001518b61312f90919063ffffffff16565b61312f90919063ffffffff16565b61314590919063ffffffff16565b600860008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461331290919063ffffffff16565b600860008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208190555061388d85836000015461331290919063ffffffff16565b82600001819055506138bb85600a60008981526020019081526020016000205461331290919063ffffffff16565b600a6000888152602001908152602001600020819055506138e785600b5461331290919063ffffffff16565b600b81905550505b613924670de0b6b3a76400006139168460a00151846000015461312f90919063ffffffff16565b61314590919063ffffffff16565b8160020181905550848673ffffffffffffffffffffffffffffffffffffffff167ff761777482b4b40d2bcc0d050cfba6829900a2d8b3484bd0244ec0feeb3db504866040516139739190614df6565b60405180910390a350509392505050565b6000858510156139975760009050613aab565b60008315613a13576139e46301e133806139d66127106139c8670de0b6b3a76400008861312f90919063ffffffff16565b61314590919063ffffffff16565b61314590919063ffffffff16565b9050613a0b816139fd89896132fc90919063ffffffff16565b61312f90919063ffffffff16565b915050613aab565b613a5a6301e13380613a4c612710613a3e670de0b6b3a764000060045461312f90919063ffffffff16565b61314590919063ffffffff16565b61314590919063ffffffff16565b9050613aa7612710613a9987613a8b85613a7d8d8d6132fc90919063ffffffff16565b61312f90919063ffffffff16565b61312f90919063ffffffff16565b61314590919063ffffffff16565b9150505b95945050505050565b600260015403613af9576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613af090615b9d565b60405180910390fd5b6002600181905550565b60018081905550565b613b1461315b565b73ffffffffffffffffffffffffffffffffffffffff16613b32611cfa565b73ffffffffffffffffffffffffffffffffffffffff1614613b88576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613b7f90615c09565b60405180910390fd5b565b60005b613b956126bd565b811015613bba57613ba7816000614883565b8080613bb290615571565b915050613b8d565b508015613bca57613bc9614a64565b5b50565b6000613bd76126bd565b8310613c18576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613c0f906156dd565b60405180910390fd5b60008211613c5b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613c5290615ac5565b60405180910390fd5b613c66836000614883565b600060068481548110613c7c57613c7b615513565b5b906000526020600020906009020160405180610120016040529081600082015481526020016001820154815260200160028201548152602001600382015481526020016004820154815260200160058201548152602001600682015481526020016007820160009054906101000a900460ff16151515158152602001600882015481525050905060008160c0015103613d4a576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613d4190615c75565b60405180910390fd5b60006007600086815260200190815260200160002060008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508381600001541015613de5576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613ddc90615ce1565b60405180910390fd5b600081600001541115613e6c576000613e3f8260020154613e31670de0b6b3a7640000613e238760a00151876000015461312f90919063ffffffff16565b61314590919063ffffffff16565b6132fc90919063ffffffff16565b90506000811115613e6a57613e6181836001015461331290919063ffffffff16565b82600101819055505b505b8160c001519250613e7e836001614883565b600060068481548110613e9457613e93615513565b5b906000526020600020906009020160405180610120016040529081600082015481526020016001820154815260200160028201548152602001600382015481526020016004820154815260200160058201548152602001600682015481526020016007820160009054906101000a900460ff16151515158152602001600882015481525050905060006007600086815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050600081600001541115613ff6576000613fc98260020154613fbb670de0b6b3a7640000613fad8760a00151876000015461312f90919063ffffffff16565b61314590919063ffffffff16565b6132fc90919063ffffffff16565b90506000811115613ff457613feb81836001015461331290919063ffffffff16565b82600101819055505b505b61400d8684600001546132fc90919063ffffffff16565b836000018190555061403b86600a60008a8152602001908152602001600020546132fc90919063ffffffff16565b600a600089815260200190815260200160002081905550614087670de0b6b3a76400006140798660a00151866000015461312f90919063ffffffff16565b61314590919063ffffffff16565b83600201819055506000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663eb91d37e6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156140fe573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061412291906153fd565b90506000614170826141626ec097ce7bc90715b34b9f10000000006141548a606001518d61312f90919063ffffffff16565b61312f90919063ffffffff16565b61314590919063ffffffff16565b9050600860008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054811115614203576000600860008c73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550614299565b61425581600860008d73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020546132fc90919063ffffffff16565b600860008c73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505b6143346142e6836142d86ec097ce7bc90715b34b9f10000000006142ca89606001518e61312f90919063ffffffff16565b61312f90919063ffffffff16565b61314590919063ffffffff16565b600860008d73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461331290919063ffffffff16565b600860008c73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208190555061438e88846000015461331290919063ffffffff16565b83600001819055506143bc88600a60008a81526020019081526020016000205461331290919063ffffffff16565b600a600089815260200190815260200160002081905550614408670de0b6b3a76400006143fa8660a00151866000015461312f90919063ffffffff16565b61314590919063ffffffff16565b836002018190555086898b73ffffffffffffffffffffffffffffffffffffffff167f9c1ccdc91bf8cfe9ff410fa78f489a2cfd882132809cf9779293003b043a9e308b6040516144589190614df6565b60405180910390a45050505050509392505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b6145b28363a9059cbb60e01b8484604051602401614550929190615769565b604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050506147bb565b505050565b6145bf6126bd565b8110614600576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016145f7906156dd565b60405180910390fd5b60006006828154811061461657614615615513565b5b906000526020600020906009020160405180610120016040529081600082015481526020016001820154815260200160028201548152602001600382015481526020016004820154815260200160058201548152602001600682015481526020016007820160009054906101000a900460ff16151515158152602001600882015481525050905060006007600084815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905060008160000154111561477857600061474b826002015461473d670de0b6b3a764000061472f8760a00151876000015461312f90919063ffffffff16565b61314590919063ffffffff16565b6132fc90919063ffffffff16565b905060008111156147765761476d81836001015461331290919063ffffffff16565b82600101819055505b505b6147ad670de0b6b3a764000061479f8460a00151846000015461312f90919063ffffffff16565b61314590919063ffffffff16565b816002018190555050505050565b600061481d826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff16614b809092919063ffffffff16565b905060008151148061483f57508080602001905181019061483e91906157a7565b5b61487e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161487590615d73565b60405180910390fd5b505050565b60006006838154811061489957614898615513565b5b90600052602060002090600902019050806004015442116148c95781156148c3576148c2614a64565b5b50614a60565b6000600a60008581526020019081526020016000205490506000810361490857428260040181905550821561490157614900614a64565b5b5050614a60565b600061493483600401544285600201548660070160009054906101000a900460ff168760080154613984565b90506000811115614a4457600061496a8361495c86600101548561312f90919063ffffffff16565b61312f90919063ffffffff16565b90507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a0712d686149c3670de0b6b3a76400008461314590919063ffffffff16565b6040518263ffffffff1660e01b81526004016149df9190614df6565b600060405180830381600087803b1580156149f957600080fd5b505af1158015614a0d573d6000803e3d6000fd5b50505050614a3a614a27848361314590919063ffffffff16565b856005015461331290919063ffffffff16565b8460050181905550505b4283600401819055508315614a5c57614a5b614a64565b5b5050505b5050565b6000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630616c4ed6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015614ad5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190614af991906153fd565b905060018103614b755760005b614b0e6126bd565b811015614b6657600160068281548110614b2b57614b2a615513565b5b906000526020600020906009020160070160006101000a81548160ff0219169083151502179055508080614b5e90615571565b915050614b06565b50612710600481905550614b7d565b806004819055505b50565b6060614b8f8484600085614b98565b90509392505050565b606082471015614bdd576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401614bd490615e05565b60405180910390fd5b6000808673ffffffffffffffffffffffffffffffffffffffff168587604051614c069190615e96565b60006040518083038185875af1925050503d8060008114614c43576040519150601f19603f3d011682016040523d82523d6000602084013e614c48565b606091505b5091509150614c5987838387614c65565b92505050949350505050565b60608315614cc7576000835103614cbf57614c7f85614cda565b614cbe576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401614cb590615ef9565b60405180910390fd5b5b829050614cd2565b614cd18383614cfd565b5b949350505050565b6000808273ffffffffffffffffffffffffffffffffffffffff163b119050919050565b600082511115614d105781518083602001fd5b806040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401614d449190615f6e565b60405180910390fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000614d7d82614d52565b9050919050565b614d8d81614d72565b8114614d9857600080fd5b50565b600081359050614daa81614d84565b92915050565b600060208284031215614dc657614dc5614d4d565b5b6000614dd484828501614d9b565b91505092915050565b6000819050919050565b614df081614ddd565b82525050565b6000602082019050614e0b6000830184614de7565b92915050565b60008115159050919050565b614e2681614e11565b8114614e3157600080fd5b50565b600081359050614e4381614e1d565b92915050565b60008060408385031215614e6057614e5f614d4d565b5b6000614e6e85828601614e34565b9250506020614e7f85828601614e34565b9150509250929050565b614e9281614ddd565b8114614e9d57600080fd5b50565b600081359050614eaf81614e89565b92915050565b600060208284031215614ecb57614eca614d4d565b5b6000614ed984828501614ea0565b91505092915050565b60008060408385031215614ef957614ef8614d4d565b5b6000614f0785828601614d9b565b9250506020614f1885828601614ea0565b9150509250929050565b600080600060608486031215614f3b57614f3a614d4d565b5b6000614f4986828701614d9b565b9350506020614f5a86828701614ea0565b9250506040614f6b86828701614ea0565b9150509250925092565b614f7e81614e11565b82525050565b6000602082019050614f996000830184614f75565b92915050565b614fa881614d72565b82525050565b6000602082019050614fc36000830184614f9f565b92915050565b6000819050919050565b6000614fee614fe9614fe484614d52565b614fc9565b614d52565b9050919050565b600061500082614fd3565b9050919050565b600061501282614ff5565b9050919050565b61502281615007565b82525050565b600060208201905061503d6000830184615019565b92915050565b6000806040838503121561505a57615059614d4d565b5b600061506885828601614ea0565b925050602061507985828601614d9b565b9150509250929050565b60006060820190506150986000830186614de7565b6150a56020830185614de7565b6150b26040830184614de7565b949350505050565b60008060008060008060c087890312156150d7576150d6614d4d565b5b60006150e589828a01614ea0565b96505060206150f689828a01614ea0565b955050604061510789828a01614ea0565b945050606061511889828a01614ea0565b935050608061512989828a01614ea0565b92505060a061513a89828a01614ea0565b9150509295509295509295565b6000806040838503121561515e5761515d614d4d565b5b600061516c85828601614ea0565b925050602061517d85828601614ea0565b9150509250929050565b600061519282614ff5565b9050919050565b6151a281615187565b82525050565b60006020820190506151bd6000830184615199565b92915050565b6000610120820190506151d9600083018c614de7565b6151e6602083018b614de7565b6151f3604083018a614de7565b6152006060830189614de7565b61520d6080830188614de7565b61521a60a0830187614de7565b61522760c0830186614de7565b61523460e0830185614f75565b615242610100830184614de7565b9a9950505050505050505050565b60008060006060848603121561526957615268614d4d565b5b600061527786828701614ea0565b935050602061528886828701614ea0565b925050604061529986828701614e34565b9150509250925092565b60006152ae82614ff5565b9050919050565b6152be816152a3565b82525050565b60006020820190506152d960008301846152b5565b92915050565b60006040820190506152f46000830185614f75565b6153016020830184614de7565b9392505050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b61533d81614ddd565b82525050565b600061534f8383615334565b60208301905092915050565b6000602082019050919050565b600061537382615308565b61537d8185615313565b935061538883615324565b8060005b838110156153b95781516153a08882615343565b97506153ab8361535b565b92505060018101905061538c565b5085935050505092915050565b600060208201905081810360008301526153e08184615368565b905092915050565b6000815190506153f781614e89565b92915050565b60006020828403121561541357615412614d4d565b5b6000615421848285016153e8565b91505092915050565b600082825260208201905092915050565b7f214e450000000000000000000000000000000000000000000000000000000000600082015250565b600061547160038361542a565b915061547c8261543b565b602082019050919050565b600060208201905081810360008301526154a081615464565b9050919050565b7f21574c0000000000000000000000000000000000000000000000000000000000600082015250565b60006154dd60038361542a565b91506154e8826154a7565b602082019050919050565b6000602082019050818103600083015261550c816154d0565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061557c82614ddd565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036155ae576155ad615542565b5b600182019050919050565b7f2152535256000000000000000000000000000000000000000000000000000000600082015250565b60006155ef60058361542a565b91506155fa826155b9565b602082019050919050565b6000602082019050818103600083015261561e816155e2565b9050919050565b7f2141444452455353000000000000000000000000000000000000000000000000600082015250565b600061565b60088361542a565b915061566682615625565b602082019050919050565b6000602082019050818103600083015261568a8161564e565b9050919050565b7f2149440000000000000000000000000000000000000000000000000000000000600082015250565b60006156c760038361542a565b91506156d282615691565b602082019050919050565b600060208201905081810360008301526156f6816156ba565b9050919050565b7f2153455400000000000000000000000000000000000000000000000000000000600082015250565b600061573360048361542a565b915061573e826156fd565b602082019050919050565b6000602082019050818103600083015261576281615726565b9050919050565b600060408201905061577e6000830185614f9f565b61578b6020830184614de7565b9392505050565b6000815190506157a181614e1d565b92915050565b6000602082840312156157bd576157bc614d4d565b5b60006157cb84828501615792565b91505092915050565b7f4d49470000000000000000000000000000000000000000000000000000000000600082015250565b600061580a60038361542a565b9150615815826157d4565b602082019050919050565b60006020820190508181036000830152615839816157fd565b9050919050565b60006060820190506158556000830186614de7565b6158626020830185614de7565b61586f6040830184614f9f565b949350505050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b60006158d360268361542a565b91506158de82615877565b604082019050919050565b60006020820190508181036000830152615902816158c6565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600061594382614ddd565b915061594e83614ddd565b925082820261595c81614ddd565b9150828204841483151761597357615972615542565b5b5092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60006159b482614ddd565b91506159bf83614ddd565b9250826159cf576159ce61597a565b5b828204905092915050565b60006159e582614ddd565b91506159f083614ddd565b9250828203905081811115615a0857615a07615542565b5b92915050565b6000615a1982614ddd565b9150615a2483614ddd565b9250828201905080821115615a3c57615a3b615542565b5b92915050565b6000606082019050615a576000830186614f9f565b615a646020830185614f9f565b615a716040830184614de7565b949350505050565b7f215a45524f000000000000000000000000000000000000000000000000000000600082015250565b6000615aaf60058361542a565b9150615aba82615a79565b602082019050919050565b60006020820190508181036000830152615ade81615aa2565b9050919050565b7f2144495300000000000000000000000000000000000000000000000000000000600082015250565b6000615b1b60048361542a565b9150615b2682615ae5565b602082019050919050565b60006020820190508181036000830152615b4a81615b0e565b9050919050565b7f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00600082015250565b6000615b87601f8361542a565b9150615b9282615b51565b602082019050919050565b60006020820190508181036000830152615bb681615b7a565b9050919050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b6000615bf360208361542a565b9150615bfe82615bbd565b602082019050919050565b60006020820190508181036000830152615c2281615be6565b9050919050565b7f214e4f4e45000000000000000000000000000000000000000000000000000000600082015250565b6000615c5f60058361542a565b9150615c6a82615c29565b602082019050919050565b60006020820190508181036000830152615c8e81615c52565b9050919050565b7f21434e5400000000000000000000000000000000000000000000000000000000600082015250565b6000615ccb60048361542a565b9150615cd682615c95565b602082019050919050565b60006020820190508181036000830152615cfa81615cbe565b9050919050565b7f5361666545524332303a204552433230206f7065726174696f6e20646964206e60008201527f6f74207375636365656400000000000000000000000000000000000000000000602082015250565b6000615d5d602a8361542a565b9150615d6882615d01565b604082019050919050565b60006020820190508181036000830152615d8c81615d50565b9050919050565b7f416464726573733a20696e73756666696369656e742062616c616e636520666f60008201527f722063616c6c0000000000000000000000000000000000000000000000000000602082015250565b6000615def60268361542a565b9150615dfa82615d93565b604082019050919050565b60006020820190508181036000830152615e1e81615de2565b9050919050565b600081519050919050565b600081905092915050565b60005b83811015615e59578082015181840152602081019050615e3e565b60008484015250505050565b6000615e7082615e25565b615e7a8185615e30565b9350615e8a818560208601615e3b565b80840191505092915050565b6000615ea28284615e65565b915081905092915050565b7f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000600082015250565b6000615ee3601d8361542a565b9150615eee82615ead565b602082019050919050565b60006020820190508181036000830152615f1281615ed6565b9050919050565b600081519050919050565b6000601f19601f8301169050919050565b6000615f4082615f19565b615f4a818561542a565b9350615f5a818560208601615e3b565b615f6381615f24565b840191505092915050565b60006020820190508181036000830152615f888184615f35565b90509291505056fea264697066735822122010d3508fed178d23765185a7375a5019b2aae87a2fa82c1fcfa5b42c89804f0864736f6c63430008130033000000000000000000000000cc2d17dfa245dc2aa3705fc75d2f7df3fe6440c700000000000000000000000000000000000000000000000000000000654b668b
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106102745760003560e01c80637adbf97311610151578063b8d94d7d116100c3578063ea7cbff111610087578063ea7cbff1146107b6578063f2fde38b146107e6578063f50edc8614610802578063f69f408014610832578063f6ed201714610862578063f7023ac51461089257610274565b8063b8d94d7d146106fd578063dfa7e6b11461071b578063e05916d614610737578063e4e7c6b414610768578063e6fd48bc1461079857610274565b8063940973d911610115578063940973d91461062157806399c6f7e214610659578063a2908e2b14610689578063b334e88314610693578063b71cdc7d146106c3578063b80cd14e146106df57610274565b80637adbf9731461058f5780637dc0d1d0146105ab578063806672b3146105c95780638da5cb5b146105f95780638fd3ab801461061757610274565b806336dbef04116101ea57806340cb7660116101ae57806340cb7660146104e55780634aa116ec146105015780635d7555541461051d578063715018a614610539578063771602f71461054357806379ee54f71461055f57610274565b806336dbef041461043f578063372500ab1461046f5780633c2a27f2146104795780633fbf444e146104955780633fed8b15146104b357610274565b806317deeccb1161023c57806317deeccb146103435780631922cd3a146103735780631942a1a0146103a357806323ba4644146103c157806327c8f835146103f15780632c0bb50c1461040f57610274565b8063034c1a921461027957806304506c2e146102a95780630c57ac26146102c75780630d64b2c0146102e35780630f14b4d614610313575b600080fd5b610293600480360381019061028e9190614db0565b6108ae565b6040516102a09190614df6565b60405180910390f35b6102b16109b3565b6040516102be9190614df6565b60405180910390f35b6102e160048036038101906102dc9190614e49565b6109b9565b005b6102fd60048036038101906102f89190614eb5565b610ea8565b60405161030a9190614df6565b60405180910390f35b61032d60048036038101906103289190614db0565b610ec0565b60405161033a9190614df6565b60405180910390f35b61035d60048036038101906103589190614ee2565b610ed8565b60405161036a9190614df6565b60405180910390f35b61038d60048036038101906103889190614f22565b610f36565b60405161039a9190614df6565b60405180910390f35b6103ab61103e565b6040516103b89190614df6565b60405180910390f35b6103db60048036038101906103d69190614db0565b611044565b6040516103e89190614f84565b60405180910390f35b6103f961109a565b6040516104069190614fae565b60405180910390f35b61042960048036038101906104249190614ee2565b6110a0565b6040516104369190614df6565b60405180910390f35b61045960048036038101906104549190614db0565b611266565b6040516104669190614df6565b60405180910390f35b6104776112b4565b005b610493600480360381019061048e9190614db0565b61142a565b005b61049d6114e5565b6040516104aa9190615028565b60405180910390f35b6104cd60048036038101906104c89190615043565b61150b565b6040516104dc93929190615083565b60405180910390f35b6104ff60048036038101906104fa91906150ba565b611542565b005b61051b60048036038101906105169190615147565b611691565b005b61053760048036038101906105329190614eb5565b611765565b005b6105416119da565b005b61055d60048036038101906105589190615147565b6119ee565b005b61057960048036038101906105749190614db0565b611b66565b6040516105869190614df6565b60405180910390f35b6105a960048036038101906105a49190614db0565b611bc9565b005b6105b3611c84565b6040516105c091906151a8565b60405180910390f35b6105e360048036038101906105de9190614ee2565b611caa565b6040516105f09190614df6565b60405180910390f35b610601611cfa565b60405161060e9190614fae565b60405180910390f35b61061f611d23565b005b61063b60048036038101906106369190614eb5565b6121fd565b604051610650999897969594939291906151c3565b60405180910390f35b610673600480360381019061066e9190614f22565b612268565b6040516106809190614df6565b60405180910390f35b6106916123e4565b005b6106ad60048036038101906106a89190614db0565b6123f8565b6040516106ba9190614df6565b60405180910390f35b6106dd60048036038101906106d89190615250565b612410565b005b6106e7612699565b6040516106f491906152c4565b60405180910390f35b6107056126bd565b6040516107129190614df6565b60405180910390f35b61073560048036038101906107309190615250565b6126ca565b005b610751600480360381019061074c9190614db0565b612a92565b60405161075f9291906152df565b60405180910390f35b610782600480360381019061077d9190614ee2565b612c6d565b60405161078f9190614df6565b60405180910390f35b6107a0612ea4565b6040516107ad9190614df6565b60405180910390f35b6107d060048036038101906107cb9190614db0565b612eaa565b6040516107dd9190614df6565b60405180910390f35b61080060048036038101906107fb9190614db0565b612ef8565b005b61081c60048036038101906108179190614f22565b612f7b565b6040516108299190614df6565b60405180910390f35b61084c60048036038101906108479190614db0565b612fdb565b60405161085991906153c6565b60405180910390f35b61087c60048036038101906108779190614db0565b613081565b6040516108899190614df6565b60405180910390f35b6108ac60048036038101906108a79190615147565b6130cf565b005b60006109ac670de0b6b3a764000061099e600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663eb91d37e6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561092c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061095091906153fd565b600860008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461312f90919063ffffffff16565b61314590919063ffffffff16565b9050919050565b600b5481565b6000806109cc6109c761315b565b612a92565b915091506109e06109db61315b565b613163565b81610ea2578315610cc35780600960006109f861315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205411610a73576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610a6a90615487565b60405180910390fd5b610acc8160096000610a8361315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020546132fc90919063ffffffff16565b60096000610ad861315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610b6f8160086000610b2661315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461331290919063ffffffff16565b60086000610b7b61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508215610cbe57600060096000610bcd61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050610c1b610c1561315b565b82613328565b600060096000610c2961315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610c6f61315b565b73ffffffffffffffffffffffffffffffffffffffff167fd8138f8a3f377c5259ca548e70e4c2de94f129f5a11036a15b69513cba2b426a82604051610cb49190614df6565b60405180910390a2505b610ea1565b610cf87f000000000000000000000000cc2d17dfa245dc2aa3705fc75d2f7df3fe6440c7610cef61315b565b61dead84613402565b610d518160086000610d0861315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461331290919063ffffffff16565b60086000610d5d61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508215610ea057600060096000610daf61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050610dfd610df761315b565b82613328565b600060096000610e0b61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610e5161315b565b73ffffffffffffffffffffffffffffffffffffffff167fd8138f8a3f377c5259ca548e70e4c2de94f129f5a11036a15b69513cba2b426a82604051610e969190614df6565b60405180910390a2505b5b5b50505050565b600a6020528060005260406000206000915090505481565b60096020528060005260406000206000915090505481565b60006007600083815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060000154905092915050565b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16610f7961315b565b73ffffffffffffffffffffffffffffffffffffffff161480610feb5750600d6000610fa261315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff165b61102a576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611021906154f3565b60405180910390fd5b61103584848461348b565b90509392505050565b60045481565b6000600e60008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff169050919050565b61dead81565b600080600683815481106110b7576110b6615513565b5b906000526020600020906009020160405180610120016040529081600082015481526020016001820154815260200160028201548152602001600382015481526020016004820154815260200160058201548152602001600682015481526020016007820160009054906101000a900460ff16151515158152602001600882015481525050905060006007600085815260200190815260200160002060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020604051806060016040529081600082015481526020016001820154815260200160028201548152505090506000600a60008681526020019081526020016000205490506000811461125d57600061120a426111f560014261331290919063ffffffff16565b86604001518760e00151886101000151613984565b9050600061123f670de0b6b3a764000061123187602001518561312f90919063ffffffff16565b61314590919063ffffffff16565b905061125881856000015161312f90919063ffffffff16565b955050505b50505092915050565b600080600090505b6112766126bd565b8110156112ae5761129961128a8483611caa565b8361331290919063ffffffff16565b915080806112a690615571565b91505061126e565b50919050565b6112bc613ab4565b60006112ce6112c961315b565b612a92565b50905080611311576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161130890615605565b60405180910390fd5b61132161131c61315b565b613163565b60006009600061132f61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905061137d61137761315b565b82613328565b60006009600061138b61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506113d161315b565b73ffffffffffffffffffffffffffffffffffffffff167fd8138f8a3f377c5259ca548e70e4c2de94f129f5a11036a15b69513cba2b426a826040516114169190614df6565b60405180910390a25050611428613b03565b565b611432613b0c565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16036114a1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161149890615671565b60405180910390fd5b80600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6007602052816000526040600020602052806000526040600020600091509150508060000154908060010154908060020154905083565b61154a613b0c565b6115526126bd565b8610611593576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161158a906156dd565b60405180910390fd5b61159d6001613b8a565b6115b8670de0b6b3a76400008661312f90919063ffffffff16565b600687815481106115cc576115cb615513565b5b90600052602060002090600902016001018190555083600687815481106115f6576115f5615513565b5b90600052602060002090600902016002018190555082600687815481106116205761161f615513565b5b906000526020600020906009020160030181905550816006878154811061164a57611649615513565b5b906000526020600020906009020160060181905550806006878154811061167457611673615513565b5b906000526020600020906009020160080181905550505050505050565b611699613ab4565b60006116ad6116a661315b565b8484613bcd565b90506000611720611711600686815481106116cb576116ca615513565b5b906000526020600020906009020160010154600685815481106116f1576116f0615513565b5b9060005260206000209060090201600101546132fc90919063ffffffff16565b8461312f90919063ffffffff16565b90506117577f000000000000000000000000cc2d17dfa245dc2aa3705fc75d2f7df3fe6440c761174e61315b565b61dead84613402565b5050611761613b03565b5050565b61176d613b0c565b600073ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16036117fe576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016117f590615749565b60405180910390fd5b7f000000000000000000000000cc2d17dfa245dc2aa3705fc75d2f7df3fe6440c773ffffffffffffffffffffffffffffffffffffffff1663a0712d68826040518263ffffffff1660e01b81526004016118579190614df6565b600060405180830381600087803b15801561187157600080fd5b505af1158015611885573d6000803e3d6000fd5b505050507f000000000000000000000000cc2d17dfa245dc2aa3705fc75d2f7df3fe6440c773ffffffffffffffffffffffffffffffffffffffff1663095ea7b3600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16836040518363ffffffff1660e01b8152600401611906929190615769565b6020604051808303816000875af1158015611925573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061194991906157a7565b50600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd49756e826040518263ffffffff1660e01b81526004016119a59190614df6565b600060405180830381600087803b1580156119bf57600080fd5b505af11580156119d3573d6000803e3d6000fd5b5050505050565b6119e2613b0c565b6119ec600061446d565b565b6119f6613b0c565b6119fe6126bd565b8214611a3f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611a36906156dd565b60405180910390fd5b611a496001613b8a565b6000600c544211611a5c57600c54611a5e565b425b90506006604051806101200160405280858152602001611a8f670de0b6b3a76400008661312f90919063ffffffff16565b8152602001612710815260200160008152602001838152602001600081526020016000815260200160001515815260200160008152509080600181540180825580915050600190039060005260206000209060090201600090919091909150600082015181600001556020820151816001015560408201518160020155606082015181600301556080820151816004015560a0820151816005015560c0820151816006015560e08201518160070160006101000a81548160ff02191690831515021790555061010082015181600801555050505050565b6000611bc2611b7483613081565b600960008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461331290919063ffffffff16565b9050919050565b611bd1613b0c565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603611c40576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611c3790615671565b60405180910390fd5b80600360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080611cb78484610ed8565b9050611cf18160068581548110611cd157611cd0615513565b5b90600052602060002090600902016003015461312f90919063ffffffff16565b91505092915050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b611d2b613ab4565b600e6000611d3761315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff1615611dbf576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611db690615820565b60405180910390fd5b600073d6b5bfcfa8d012b2c4db0ae3f912cc9fa6ed5b8d905060008173ffffffffffffffffffffffffffffffffffffffff166379ee54f7611dfe61315b565b6040518263ffffffff1660e01b8152600401611e1a9190614fae565b602060405180830381865afa158015611e37573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e5b91906153fd565b90506000811115611f95577f000000000000000000000000cc2d17dfa245dc2aa3705fc75d2f7df3fe6440c773ffffffffffffffffffffffffffffffffffffffff1663a0712d68826040518263ffffffff1660e01b8152600401611ebf9190614df6565b600060405180830381600087803b158015611ed957600080fd5b505af1158015611eed573d6000803e3d6000fd5b50505050611f4a8160096000611f0161315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461331290919063ffffffff16565b60096000611f5661315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505b60005b8273ffffffffffffffffffffffffffffffffffffffff1663b8d94d7d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015611fe3573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061200791906153fd565b8110156120c65760008373ffffffffffffffffffffffffffffffffffffffff166317deeccb61203461315b565b846040518363ffffffff1660e01b8152600401612052929190615769565b602060405180830381865afa15801561206f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061209391906153fd565b905060008111156120b2576120b06120a961315b565b838361348b565b505b5080806120be90615571565b915050611f98565b508173ffffffffffffffffffffffffffffffffffffffff1663b334e8836120eb61315b565b6040518263ffffffff1660e01b81526004016121079190614fae565b602060405180830381865afa158015612124573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061214891906153fd565b6008600061215461315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506001600e60006121a061315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff02191690831515021790555050506121fb613b03565b565b6006818154811061220d57600080fd5b90600052602060002090600902016000915090508060000154908060010154908060020154908060030154908060040154908060050154908060060154908060070160009054906101000a900460ff16908060080154905089565b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166122ab61315b565b73ffffffffffffffffffffffffffffffffffffffff16148061231d5750600d60006122d461315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff165b61235c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612353906154f3565b60405180910390fd5b6000612369858585613bcd565b90506123da6123cb6006868154811061238557612384615513565b5b906000526020600020906009020160010154600684815481106123ab576123aa615513565b5b9060005260206000209060090201600101546132fc90919063ffffffff16565b8461312f90919063ffffffff16565b9150509392505050565b6123ec613b0c565b6123f66001613b8a565b565b60086020528060005260406000206000915090505481565b612418613ab4565b600061242a61242561315b565b612a92565b5090508061246d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161246490615605565b60405180910390fd5b61247d61247861315b565b613163565b600061249161248a61315b565b868661348b565b905080600960006124a061315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054101561251c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161251390615487565b60405180910390fd5b6000612577826009600061252e61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020546132fc90919063ffffffff16565b9050806009600061258661315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506000811180156125d15750835b15612689576125e76125e161315b565b82613328565b6000600960006125f561315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208190555061263b61315b565b73ffffffffffffffffffffffffffffffffffffffff167fd8138f8a3f377c5259ca548e70e4c2de94f129f5a11036a15b69513cba2b426a826040516126809190614df6565b60405180910390a25b505050612694613b03565b505050565b7f000000000000000000000000cc2d17dfa245dc2aa3705fc75d2f7df3fe6440c781565b6000600680549050905090565b6126d2613ab4565b600073ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1603612763576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161275a90615671565b60405180910390fd5b600061277561277061315b565b612a92565b509050806127b8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016127af90615605565b60405180910390fd5b6127c86127c361315b565b613163565b83600960006127d561315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020541015612851576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161284890615487565b60405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630a6060e4858561289961315b565b6040518463ffffffff1660e01b81526004016128b793929190615840565b600060405180830381600087803b1580156128d157600080fd5b505af11580156128e5573d6000803e3d6000fd5b505050506129167f000000000000000000000000cc2d17dfa245dc2aa3705fc75d2f7df3fe6440c761dead86614531565b6000612971856009600061292861315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020546132fc90919063ffffffff16565b9050806009600061298061315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506000811180156129cb5750825b15612a83576129e16129db61315b565b82613328565b6000600960006129ef61315b565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550612a3561315b565b73ffffffffffffffffffffffffffffffffffffffff167fd8138f8a3f377c5259ca548e70e4c2de94f129f5a11036a15b69513cba2b426a82604051612a7a9190614df6565b60405180910390a25b5050612a8d613b03565b505050565b6000806000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663eb91d37e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612b04573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612b2891906153fd565b9050600080600090505b612b3a6126bd565b811015612b7357612b5e612b4f878386612f7b565b8361331290919063ffffffff16565b91508080612b6b90615571565b915050612b32565b506000612b9f612710612b916005548561312f90919063ffffffff16565b61314590919063ffffffff16565b90506000612bb682846132fc90919063ffffffff16565b905080600860008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205410612c0b576001955060009450612c64565b60009550612c61600860008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054846132fc90919063ffffffff16565b94505b50505050915091565b60008060068381548110612c8457612c83615513565b5b906000526020600020906009020160405180610120016040529081600082015481526020016001820154815260200160028201548152602001600382015481526020016004820154815260200160058201548152602001600682015481526020016007820160009054906101000a900460ff16151515158152602001600882015481525050905060006007600085815260200190815260200160002060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206040518060600160405290816000820154815260200160018201548152602001600282015481525050905060008260a0015190506000600a6000878152602001908152602001600020549050836080015142118015612dbd575060008114155b15612e3b576000612de285608001514287604001518860e00151896101000151613984565b90506000612e0f83612e0188602001518561312f90919063ffffffff16565b61312f90919063ffffffff16565b9050612e36612e27848361314590919063ffffffff16565b8561331290919063ffffffff16565b935050505b612e98612e858460400151612e77670de0b6b3a7640000612e6987896000015161312f90919063ffffffff16565b61314590919063ffffffff16565b6132fc90919063ffffffff16565b846020015161331290919063ffffffff16565b94505050505092915050565b600c5481565b600080600090505b612eba6126bd565b811015612ef257612edd612ece84836110a0565b8361331290919063ffffffff16565b91508080612eea90615571565b915050612eb2565b50919050565b612f00613b0c565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603612f6f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612f66906158e9565b60405180910390fd5b612f788161446d565b50565b600080612fa2670de0b6b3a7640000612f948787611caa565b61312f90919063ffffffff16565b9050612fd183612fc3670de0b6b3a76400008461312f90919063ffffffff16565b61314590919063ffffffff16565b9150509392505050565b606060068054905067ffffffffffffffff811115612ffc57612ffb615909565b5b60405190808252806020026020018201604052801561302a5781602001602082028036833780820191505090505b50905060005b6130386126bd565b81101561307b576130498382610ed8565b82828151811061305c5761305b615513565b5b602002602001018181525050808061307390615571565b915050613030565b50919050565b600080600090505b6130916126bd565b8110156130c9576130b46130a58483612c6d565b8361331290919063ffffffff16565b915080806130c190615571565b915050613089565b50919050565b6130d7613ab4565b60006130eb6130e461315b565b848461348b565b90506131227f000000000000000000000000cc2d17dfa245dc2aa3705fc75d2f7df3fe6440c761311961315b565b61dead84613402565b5061312b613b03565b5050565b6000818361313d9190615938565b905092915050565b6000818361315391906159a9565b905092915050565b600033905090565b61316d6001613b8a565b600080600090505b61317d6126bd565b8110156132625761318e83826145b7565b6131f46007600083815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600101548361331290919063ffffffff16565b915060006007600083815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060010181905550808061325a90615571565b915050613175565b506132b581600960008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461331290919063ffffffff16565b600960008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505050565b6000818361330a91906159da565b905092915050565b600081836133209190615a0e565b905092915050565b60007f000000000000000000000000cc2d17dfa245dc2aa3705fc75d2f7df3fe6440c773ffffffffffffffffffffffffffffffffffffffff166370a08231306040518263ffffffff1660e01b81526004016133839190614fae565b602060405180830381865afa1580156133a0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133c491906153fd565b9050808211156133d2578091505b6133fd7f000000000000000000000000cc2d17dfa245dc2aa3705fc75d2f7df3fe6440c78484614531565b505050565b613485846323b872dd60e01b85858560405160240161342393929190615a42565b604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050506147bb565b50505050565b60006134956126bd565b83106134d6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016134cd906156dd565b60405180910390fd5b60008211613519576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161351090615ac5565b60405180910390fd5b613524836001614883565b60006006848154811061353a57613539615513565b5b906000526020600020906009020160405180610120016040529081600082015481526020016001820154815260200160028201548152602001600382015481526020016004820154815260200160058201548152602001600682015481526020016007820160009054906101000a900460ff1615151515815260200160088201548152505090508060e0015115613606576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016135fd90615b31565b60405180910390fd5b60006007600086815260200190815260200160002060008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905061367182602001518561312f90919063ffffffff16565b92506000816000015411156136fa5760006136cd82600201546136bf670de0b6b3a76400006136b18760a00151876000015461312f90919063ffffffff16565b61314590919063ffffffff16565b6132fc90919063ffffffff16565b905060008111156136f8576136ef81836001015461331290919063ffffffff16565b82600101819055505b505b60008411156138ef576000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663eb91d37e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613772573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061379691906153fd565b90506138336137e5826137d76ec097ce7bc90715b34b9f10000000006137c988606001518b61312f90919063ffffffff16565b61312f90919063ffffffff16565b61314590919063ffffffff16565b600860008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461331290919063ffffffff16565b600860008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208190555061388d85836000015461331290919063ffffffff16565b82600001819055506138bb85600a60008981526020019081526020016000205461331290919063ffffffff16565b600a6000888152602001908152602001600020819055506138e785600b5461331290919063ffffffff16565b600b81905550505b613924670de0b6b3a76400006139168460a00151846000015461312f90919063ffffffff16565b61314590919063ffffffff16565b8160020181905550848673ffffffffffffffffffffffffffffffffffffffff167ff761777482b4b40d2bcc0d050cfba6829900a2d8b3484bd0244ec0feeb3db504866040516139739190614df6565b60405180910390a350509392505050565b6000858510156139975760009050613aab565b60008315613a13576139e46301e133806139d66127106139c8670de0b6b3a76400008861312f90919063ffffffff16565b61314590919063ffffffff16565b61314590919063ffffffff16565b9050613a0b816139fd89896132fc90919063ffffffff16565b61312f90919063ffffffff16565b915050613aab565b613a5a6301e13380613a4c612710613a3e670de0b6b3a764000060045461312f90919063ffffffff16565b61314590919063ffffffff16565b61314590919063ffffffff16565b9050613aa7612710613a9987613a8b85613a7d8d8d6132fc90919063ffffffff16565b61312f90919063ffffffff16565b61312f90919063ffffffff16565b61314590919063ffffffff16565b9150505b95945050505050565b600260015403613af9576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613af090615b9d565b60405180910390fd5b6002600181905550565b60018081905550565b613b1461315b565b73ffffffffffffffffffffffffffffffffffffffff16613b32611cfa565b73ffffffffffffffffffffffffffffffffffffffff1614613b88576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613b7f90615c09565b60405180910390fd5b565b60005b613b956126bd565b811015613bba57613ba7816000614883565b8080613bb290615571565b915050613b8d565b508015613bca57613bc9614a64565b5b50565b6000613bd76126bd565b8310613c18576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613c0f906156dd565b60405180910390fd5b60008211613c5b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613c5290615ac5565b60405180910390fd5b613c66836000614883565b600060068481548110613c7c57613c7b615513565b5b906000526020600020906009020160405180610120016040529081600082015481526020016001820154815260200160028201548152602001600382015481526020016004820154815260200160058201548152602001600682015481526020016007820160009054906101000a900460ff16151515158152602001600882015481525050905060008160c0015103613d4a576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613d4190615c75565b60405180910390fd5b60006007600086815260200190815260200160002060008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508381600001541015613de5576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613ddc90615ce1565b60405180910390fd5b600081600001541115613e6c576000613e3f8260020154613e31670de0b6b3a7640000613e238760a00151876000015461312f90919063ffffffff16565b61314590919063ffffffff16565b6132fc90919063ffffffff16565b90506000811115613e6a57613e6181836001015461331290919063ffffffff16565b82600101819055505b505b8160c001519250613e7e836001614883565b600060068481548110613e9457613e93615513565b5b906000526020600020906009020160405180610120016040529081600082015481526020016001820154815260200160028201548152602001600382015481526020016004820154815260200160058201548152602001600682015481526020016007820160009054906101000a900460ff16151515158152602001600882015481525050905060006007600086815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050600081600001541115613ff6576000613fc98260020154613fbb670de0b6b3a7640000613fad8760a00151876000015461312f90919063ffffffff16565b61314590919063ffffffff16565b6132fc90919063ffffffff16565b90506000811115613ff457613feb81836001015461331290919063ffffffff16565b82600101819055505b505b61400d8684600001546132fc90919063ffffffff16565b836000018190555061403b86600a60008a8152602001908152602001600020546132fc90919063ffffffff16565b600a600089815260200190815260200160002081905550614087670de0b6b3a76400006140798660a00151866000015461312f90919063ffffffff16565b61314590919063ffffffff16565b83600201819055506000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663eb91d37e6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156140fe573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061412291906153fd565b90506000614170826141626ec097ce7bc90715b34b9f10000000006141548a606001518d61312f90919063ffffffff16565b61312f90919063ffffffff16565b61314590919063ffffffff16565b9050600860008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054811115614203576000600860008c73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550614299565b61425581600860008d73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020546132fc90919063ffffffff16565b600860008c73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505b6143346142e6836142d86ec097ce7bc90715b34b9f10000000006142ca89606001518e61312f90919063ffffffff16565b61312f90919063ffffffff16565b61314590919063ffffffff16565b600860008d73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461331290919063ffffffff16565b600860008c73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208190555061438e88846000015461331290919063ffffffff16565b83600001819055506143bc88600a60008a81526020019081526020016000205461331290919063ffffffff16565b600a600089815260200190815260200160002081905550614408670de0b6b3a76400006143fa8660a00151866000015461312f90919063ffffffff16565b61314590919063ffffffff16565b836002018190555086898b73ffffffffffffffffffffffffffffffffffffffff167f9c1ccdc91bf8cfe9ff410fa78f489a2cfd882132809cf9779293003b043a9e308b6040516144589190614df6565b60405180910390a45050505050509392505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b6145b28363a9059cbb60e01b8484604051602401614550929190615769565b604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050506147bb565b505050565b6145bf6126bd565b8110614600576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016145f7906156dd565b60405180910390fd5b60006006828154811061461657614615615513565b5b906000526020600020906009020160405180610120016040529081600082015481526020016001820154815260200160028201548152602001600382015481526020016004820154815260200160058201548152602001600682015481526020016007820160009054906101000a900460ff16151515158152602001600882015481525050905060006007600084815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905060008160000154111561477857600061474b826002015461473d670de0b6b3a764000061472f8760a00151876000015461312f90919063ffffffff16565b61314590919063ffffffff16565b6132fc90919063ffffffff16565b905060008111156147765761476d81836001015461331290919063ffffffff16565b82600101819055505b505b6147ad670de0b6b3a764000061479f8460a00151846000015461312f90919063ffffffff16565b61314590919063ffffffff16565b816002018190555050505050565b600061481d826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff16614b809092919063ffffffff16565b905060008151148061483f57508080602001905181019061483e91906157a7565b5b61487e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161487590615d73565b60405180910390fd5b505050565b60006006838154811061489957614898615513565b5b90600052602060002090600902019050806004015442116148c95781156148c3576148c2614a64565b5b50614a60565b6000600a60008581526020019081526020016000205490506000810361490857428260040181905550821561490157614900614a64565b5b5050614a60565b600061493483600401544285600201548660070160009054906101000a900460ff168760080154613984565b90506000811115614a4457600061496a8361495c86600101548561312f90919063ffffffff16565b61312f90919063ffffffff16565b90507f000000000000000000000000cc2d17dfa245dc2aa3705fc75d2f7df3fe6440c773ffffffffffffffffffffffffffffffffffffffff1663a0712d686149c3670de0b6b3a76400008461314590919063ffffffff16565b6040518263ffffffff1660e01b81526004016149df9190614df6565b600060405180830381600087803b1580156149f957600080fd5b505af1158015614a0d573d6000803e3d6000fd5b50505050614a3a614a27848361314590919063ffffffff16565b856005015461331290919063ffffffff16565b8460050181905550505b4283600401819055508315614a5c57614a5b614a64565b5b5050505b5050565b6000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630616c4ed6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015614ad5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190614af991906153fd565b905060018103614b755760005b614b0e6126bd565b811015614b6657600160068281548110614b2b57614b2a615513565b5b906000526020600020906009020160070160006101000a81548160ff0219169083151502179055508080614b5e90615571565b915050614b06565b50612710600481905550614b7d565b806004819055505b50565b6060614b8f8484600085614b98565b90509392505050565b606082471015614bdd576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401614bd490615e05565b60405180910390fd5b6000808673ffffffffffffffffffffffffffffffffffffffff168587604051614c069190615e96565b60006040518083038185875af1925050503d8060008114614c43576040519150601f19603f3d011682016040523d82523d6000602084013e614c48565b606091505b5091509150614c5987838387614c65565b92505050949350505050565b60608315614cc7576000835103614cbf57614c7f85614cda565b614cbe576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401614cb590615ef9565b60405180910390fd5b5b829050614cd2565b614cd18383614cfd565b5b949350505050565b6000808273ffffffffffffffffffffffffffffffffffffffff163b119050919050565b600082511115614d105781518083602001fd5b806040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401614d449190615f6e565b60405180910390fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000614d7d82614d52565b9050919050565b614d8d81614d72565b8114614d9857600080fd5b50565b600081359050614daa81614d84565b92915050565b600060208284031215614dc657614dc5614d4d565b5b6000614dd484828501614d9b565b91505092915050565b6000819050919050565b614df081614ddd565b82525050565b6000602082019050614e0b6000830184614de7565b92915050565b60008115159050919050565b614e2681614e11565b8114614e3157600080fd5b50565b600081359050614e4381614e1d565b92915050565b60008060408385031215614e6057614e5f614d4d565b5b6000614e6e85828601614e34565b9250506020614e7f85828601614e34565b9150509250929050565b614e9281614ddd565b8114614e9d57600080fd5b50565b600081359050614eaf81614e89565b92915050565b600060208284031215614ecb57614eca614d4d565b5b6000614ed984828501614ea0565b91505092915050565b60008060408385031215614ef957614ef8614d4d565b5b6000614f0785828601614d9b565b9250506020614f1885828601614ea0565b9150509250929050565b600080600060608486031215614f3b57614f3a614d4d565b5b6000614f4986828701614d9b565b9350506020614f5a86828701614ea0565b9250506040614f6b86828701614ea0565b9150509250925092565b614f7e81614e11565b82525050565b6000602082019050614f996000830184614f75565b92915050565b614fa881614d72565b82525050565b6000602082019050614fc36000830184614f9f565b92915050565b6000819050919050565b6000614fee614fe9614fe484614d52565b614fc9565b614d52565b9050919050565b600061500082614fd3565b9050919050565b600061501282614ff5565b9050919050565b61502281615007565b82525050565b600060208201905061503d6000830184615019565b92915050565b6000806040838503121561505a57615059614d4d565b5b600061506885828601614ea0565b925050602061507985828601614d9b565b9150509250929050565b60006060820190506150986000830186614de7565b6150a56020830185614de7565b6150b26040830184614de7565b949350505050565b60008060008060008060c087890312156150d7576150d6614d4d565b5b60006150e589828a01614ea0565b96505060206150f689828a01614ea0565b955050604061510789828a01614ea0565b945050606061511889828a01614ea0565b935050608061512989828a01614ea0565b92505060a061513a89828a01614ea0565b9150509295509295509295565b6000806040838503121561515e5761515d614d4d565b5b600061516c85828601614ea0565b925050602061517d85828601614ea0565b9150509250929050565b600061519282614ff5565b9050919050565b6151a281615187565b82525050565b60006020820190506151bd6000830184615199565b92915050565b6000610120820190506151d9600083018c614de7565b6151e6602083018b614de7565b6151f3604083018a614de7565b6152006060830189614de7565b61520d6080830188614de7565b61521a60a0830187614de7565b61522760c0830186614de7565b61523460e0830185614f75565b615242610100830184614de7565b9a9950505050505050505050565b60008060006060848603121561526957615268614d4d565b5b600061527786828701614ea0565b935050602061528886828701614ea0565b925050604061529986828701614e34565b9150509250925092565b60006152ae82614ff5565b9050919050565b6152be816152a3565b82525050565b60006020820190506152d960008301846152b5565b92915050565b60006040820190506152f46000830185614f75565b6153016020830184614de7565b9392505050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b61533d81614ddd565b82525050565b600061534f8383615334565b60208301905092915050565b6000602082019050919050565b600061537382615308565b61537d8185615313565b935061538883615324565b8060005b838110156153b95781516153a08882615343565b97506153ab8361535b565b92505060018101905061538c565b5085935050505092915050565b600060208201905081810360008301526153e08184615368565b905092915050565b6000815190506153f781614e89565b92915050565b60006020828403121561541357615412614d4d565b5b6000615421848285016153e8565b91505092915050565b600082825260208201905092915050565b7f214e450000000000000000000000000000000000000000000000000000000000600082015250565b600061547160038361542a565b915061547c8261543b565b602082019050919050565b600060208201905081810360008301526154a081615464565b9050919050565b7f21574c0000000000000000000000000000000000000000000000000000000000600082015250565b60006154dd60038361542a565b91506154e8826154a7565b602082019050919050565b6000602082019050818103600083015261550c816154d0565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061557c82614ddd565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036155ae576155ad615542565b5b600182019050919050565b7f2152535256000000000000000000000000000000000000000000000000000000600082015250565b60006155ef60058361542a565b91506155fa826155b9565b602082019050919050565b6000602082019050818103600083015261561e816155e2565b9050919050565b7f2141444452455353000000000000000000000000000000000000000000000000600082015250565b600061565b60088361542a565b915061566682615625565b602082019050919050565b6000602082019050818103600083015261568a8161564e565b9050919050565b7f2149440000000000000000000000000000000000000000000000000000000000600082015250565b60006156c760038361542a565b91506156d282615691565b602082019050919050565b600060208201905081810360008301526156f6816156ba565b9050919050565b7f2153455400000000000000000000000000000000000000000000000000000000600082015250565b600061573360048361542a565b915061573e826156fd565b602082019050919050565b6000602082019050818103600083015261576281615726565b9050919050565b600060408201905061577e6000830185614f9f565b61578b6020830184614de7565b9392505050565b6000815190506157a181614e1d565b92915050565b6000602082840312156157bd576157bc614d4d565b5b60006157cb84828501615792565b91505092915050565b7f4d49470000000000000000000000000000000000000000000000000000000000600082015250565b600061580a60038361542a565b9150615815826157d4565b602082019050919050565b60006020820190508181036000830152615839816157fd565b9050919050565b60006060820190506158556000830186614de7565b6158626020830185614de7565b61586f6040830184614f9f565b949350505050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b60006158d360268361542a565b91506158de82615877565b604082019050919050565b60006020820190508181036000830152615902816158c6565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600061594382614ddd565b915061594e83614ddd565b925082820261595c81614ddd565b9150828204841483151761597357615972615542565b5b5092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60006159b482614ddd565b91506159bf83614ddd565b9250826159cf576159ce61597a565b5b828204905092915050565b60006159e582614ddd565b91506159f083614ddd565b9250828203905081811115615a0857615a07615542565b5b92915050565b6000615a1982614ddd565b9150615a2483614ddd565b9250828201905080821115615a3c57615a3b615542565b5b92915050565b6000606082019050615a576000830186614f9f565b615a646020830185614f9f565b615a716040830184614de7565b949350505050565b7f215a45524f000000000000000000000000000000000000000000000000000000600082015250565b6000615aaf60058361542a565b9150615aba82615a79565b602082019050919050565b60006020820190508181036000830152615ade81615aa2565b9050919050565b7f2144495300000000000000000000000000000000000000000000000000000000600082015250565b6000615b1b60048361542a565b9150615b2682615ae5565b602082019050919050565b60006020820190508181036000830152615b4a81615b0e565b9050919050565b7f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00600082015250565b6000615b87601f8361542a565b9150615b9282615b51565b602082019050919050565b60006020820190508181036000830152615bb681615b7a565b9050919050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b6000615bf360208361542a565b9150615bfe82615bbd565b602082019050919050565b60006020820190508181036000830152615c2281615be6565b9050919050565b7f214e4f4e45000000000000000000000000000000000000000000000000000000600082015250565b6000615c5f60058361542a565b9150615c6a82615c29565b602082019050919050565b60006020820190508181036000830152615c8e81615c52565b9050919050565b7f21434e5400000000000000000000000000000000000000000000000000000000600082015250565b6000615ccb60048361542a565b9150615cd682615c95565b602082019050919050565b60006020820190508181036000830152615cfa81615cbe565b9050919050565b7f5361666545524332303a204552433230206f7065726174696f6e20646964206e60008201527f6f74207375636365656400000000000000000000000000000000000000000000602082015250565b6000615d5d602a8361542a565b9150615d6882615d01565b604082019050919050565b60006020820190508181036000830152615d8c81615d50565b9050919050565b7f416464726573733a20696e73756666696369656e742062616c616e636520666f60008201527f722063616c6c0000000000000000000000000000000000000000000000000000602082015250565b6000615def60268361542a565b9150615dfa82615d93565b604082019050919050565b60006020820190508181036000830152615e1e81615de2565b9050919050565b600081519050919050565b600081905092915050565b60005b83811015615e59578082015181840152602081019050615e3e565b60008484015250505050565b6000615e7082615e25565b615e7a8185615e30565b9350615e8a818560208601615e3b565b80840191505092915050565b6000615ea28284615e65565b915081905092915050565b7f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000600082015250565b6000615ee3601d8361542a565b9150615eee82615ead565b602082019050919050565b60006020820190508181036000830152615f1281615ed6565b9050919050565b600081519050919050565b6000601f19601f8301169050919050565b6000615f4082615f19565b615f4a818561542a565b9350615f5a818560208601615e3b565b615f6381615f24565b840191505092915050565b60006020820190508181036000830152615f888184615f35565b90509291505056fea264697066735822122010d3508fed178d23765185a7375a5019b2aae87a2fa82c1fcfa5b42c89804f0864736f6c63430008130033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000cc2d17dfa245dc2aa3705fc75d2f7df3fe6440c700000000000000000000000000000000000000000000000000000000654b668b
-----Decoded View---------------
Arg [0] : _rsrv (address): 0xcC2D17dfA245dC2Aa3705Fc75D2f7dF3fe6440C7
Arg [1] : _startTimestamp (uint256): 1699440267
-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 000000000000000000000000cc2d17dfa245dc2aa3705fc75d2f7df3fe6440c7
Arg [1] : 00000000000000000000000000000000000000000000000000000000654b668b
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 26 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.