Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
Funded By
N/A
Latest 25 from a total of 1,219 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Stake | 14126919 | 1057 days ago | IN | 0 ETH | 0.00237295 | ||||
Stake | 14125851 | 1057 days ago | IN | 0 ETH | 0.00759752 | ||||
Stake | 14125716 | 1057 days ago | IN | 0 ETH | 0.00491318 | ||||
Stake | 14125643 | 1057 days ago | IN | 0 ETH | 0.00591402 | ||||
Stake | 14125603 | 1057 days ago | IN | 0 ETH | 0.00709442 | ||||
Stake | 14124735 | 1057 days ago | IN | 0 ETH | 0.00808978 | ||||
Stake | 14124169 | 1057 days ago | IN | 0 ETH | 0.01709548 | ||||
Stake | 14123914 | 1057 days ago | IN | 0 ETH | 0.00881366 | ||||
Stake | 14122603 | 1057 days ago | IN | 0 ETH | 0.01326448 | ||||
Stake | 14121786 | 1057 days ago | IN | 0 ETH | 0.01491129 | ||||
Stake | 14120974 | 1057 days ago | IN | 0 ETH | 0.01163193 | ||||
Stake | 14120487 | 1058 days ago | IN | 0 ETH | 0.00629662 | ||||
Unstake | 14120407 | 1058 days ago | IN | 0 ETH | 0.00481388 | ||||
Start Unstake | 14120401 | 1058 days ago | IN | 0 ETH | 0.00957306 | ||||
Stake | 14119902 | 1058 days ago | IN | 0 ETH | 0.00547361 | ||||
Unstake | 14119888 | 1058 days ago | IN | 0 ETH | 0.00544927 | ||||
Start Unstake | 14119877 | 1058 days ago | IN | 0 ETH | 0.00980827 | ||||
Unstake | 14119852 | 1058 days ago | IN | 0 ETH | 0.00484741 | ||||
Start Unstake | 14119841 | 1058 days ago | IN | 0 ETH | 0.0106614 | ||||
Stake | 14119198 | 1058 days ago | IN | 0 ETH | 0.00752822 | ||||
Stake | 14118959 | 1058 days ago | IN | 0 ETH | 0.00811794 | ||||
Unstake | 14117818 | 1058 days ago | IN | 0 ETH | 0.00846563 | ||||
Start Unstake | 14117806 | 1058 days ago | IN | 0 ETH | 0.01600918 | ||||
Stake | 14117313 | 1058 days ago | IN | 0 ETH | 0.00704543 | ||||
Stake | 14116948 | 1058 days ago | IN | 0 ETH | 0.00865455 |
Latest 1 internal transaction
Advanced mode:
Parent Transaction Hash | Block |
From
|
To
|
|||
---|---|---|---|---|---|---|
14126457 | 1057 days ago | 0 ETH |
Loading...
Loading
Contract Self Destruct called at Txn Hash 0xc3eda235960ac2b3dd50b3ea77e7d253ff7b6685e6c4d69cef4fbb6c853e2c93
Contract Name:
StakingThales
Compiler Version
v0.5.16+commit.9c3226ce
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
pragma solidity ^0.5.16; import "openzeppelin-solidity-2.3.0/contracts/math/Math.sol"; import "openzeppelin-solidity-2.3.0/contracts/token/ERC20/SafeERC20.sol"; import "synthetix-2.43.1/contracts/SafeDecimalMath.sol"; import "openzeppelin-solidity-2.3.0/contracts/ownership/Ownable.sol"; import "openzeppelin-solidity-2.3.0/contracts/utils/ReentrancyGuard.sol"; import "synthetix-2.43.1/contracts/Pausable.sol"; import "../interfaces/IEscrowThales.sol"; import "../interfaces/IStakingThales.sol"; contract StakingThales is IStakingThales, Owned, ReentrancyGuard, Pausable { /* ========== LIBRARIES ========== */ using SafeMath for uint; using SafeDecimalMath for uint; using SafeERC20 for IERC20; /* ========== STATE VARIABLES ========== */ IEscrowThales public iEscrowThales; IERC20 public stakingToken; IERC20 public feeToken; uint public periodsOfStaking = 0; uint public lastPeriodTimeStamp = 0; uint public durationPeriod = 7 days; uint public unstakeDurationPeriod = 7 days; uint public startTimeStamp = 0; uint public currentPeriodRewards = 0; uint public currentPeriodFees = 0; bool public distributeFeesEnabled = false; uint public fixedPeriodReward = 100000 * 1e18; bool public claimEnabled = false; mapping(address => uint) public stakerLifetimeRewardsClaimed; mapping(address => uint) public stakerFeesClaimed; uint private _totalStakedAmount; uint private _totalEscrowedAmount; uint private _totalPendingStakeAmount; uint private _totalUnclaimedRewards; uint private _totalRewardsClaimed; uint private _totalRewardFeesClaimed; mapping(address => uint) public lastUnstakeTime; mapping(address => bool) public unstaking; mapping(address => uint) public unstakingAmount; mapping(address => uint) private _stakedBalances; mapping(address => uint) private _lastRewardsClaimedPeriod; /* ========== CONSTRUCTOR ========== */ constructor( address _owner, address _iEscrowThales, //THALES address _stakingToken, //THALES address _feeToken, //sUSD uint _durationPeriod, uint _unstakeDurationPeriod ) public Owned(_owner) { iEscrowThales = IEscrowThales(_iEscrowThales); stakingToken = IERC20(_stakingToken); feeToken = IERC20(_feeToken); stakingToken.approve(_iEscrowThales, 0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff); durationPeriod = _durationPeriod; unstakeDurationPeriod = _unstakeDurationPeriod; } /* ========== VIEWS ========== */ function totalStakedAmount() external view returns (uint) { return _totalStakedAmount; } function stakedBalanceOf(address account) external view returns (uint) { return _stakedBalances[account]; } function getLastPeriodOfClaimedRewards(address account) external view returns (uint) { return _lastRewardsClaimedPeriod[account]; } function getRewardsAvailable(address account) external view returns (uint) { return _calculateAvailableRewardsToClaim(account); } function getRewardFeesAvailable(address account) external view returns (uint) { return _calculateAvailableFeesToClaim(account); } function getAlreadyClaimedRewards(address account) external view returns (uint) { return stakerLifetimeRewardsClaimed[account]; } function getAlreadyClaimedFees(address account) external view returns (uint) { return stakerFeesClaimed[account]; } function getContractRewardFunds() external view returns (uint) { return stakingToken.balanceOf(address(this)); } function getContractFeeFunds() external view returns (uint) { return feeToken.balanceOf(address(this)); } function setDistributeFeesEnabled(bool _distributeFeesEnabled) external onlyOwner { distributeFeesEnabled = _distributeFeesEnabled; emit DistributeFeesEnabled(_distributeFeesEnabled); } function setFixedPeriodReward(uint _fixedReward) external onlyOwner { fixedPeriodReward = _fixedReward; emit FixedPeriodRewardChanged(_fixedReward); } function setClaimEnabled(bool _claimEnabled) external onlyOwner { claimEnabled = _claimEnabled; emit ClaimEnabled(_claimEnabled); } function setDurationPeriod(uint _durationPeriod) external onlyOwner { durationPeriod = _durationPeriod; emit DurationPeriodChanged(_durationPeriod); } function setUnstakeDurationPeriod(uint _unstakeDurationPeriod) external onlyOwner { unstakeDurationPeriod = _unstakeDurationPeriod; emit UnstakeDurationPeriodChanged(_unstakeDurationPeriod); } // Set EscrowThales contract address function setEscrow(address _escrowThalesContract) public onlyOwner { if (address(iEscrowThales) != address(0)) { stakingToken.approve(address(iEscrowThales), 0); } iEscrowThales = IEscrowThales(_escrowThalesContract); stakingToken.approve(_escrowThalesContract, 0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff); emit EscrowChanged(_escrowThalesContract); } /* ========== PUBLIC ========== */ function startStakingPeriod() external onlyOwner { require(startTimeStamp == 0, "Staking has already started"); startTimeStamp = block.timestamp; periodsOfStaking = 0; lastPeriodTimeStamp = startTimeStamp; _totalUnclaimedRewards = 0; _totalRewardsClaimed = 0; _totalRewardFeesClaimed = 0; _totalStakedAmount = 0; _totalEscrowedAmount = 0; _totalPendingStakeAmount = 0; emit StakingPeriodStarted(); } function closePeriod() external nonReentrant notPaused { require(startTimeStamp > 0, "Staking period has not started"); require( block.timestamp >= lastPeriodTimeStamp.add(durationPeriod), "A full period has not passed since the last closed period" ); iEscrowThales.updateCurrentPeriod(); lastPeriodTimeStamp = block.timestamp; periodsOfStaking = iEscrowThales.currentVestingPeriod(); _totalEscrowedAmount = iEscrowThales.totalEscrowedRewards().sub( iEscrowThales.totalEscrowBalanceNotIncludedInStaking() ); //Actions taken on every closed period currentPeriodRewards = fixedPeriodReward; _totalUnclaimedRewards = _totalUnclaimedRewards.add(currentPeriodRewards); currentPeriodFees = feeToken.balanceOf(address(this)); emit ClosedPeriod(periodsOfStaking, lastPeriodTimeStamp); } function stake(uint amount) external nonReentrant notPaused { require(startTimeStamp > 0, "Staking period has not started"); require(amount > 0, "Cannot stake 0"); require( stakingToken.allowance(msg.sender, address(this)) >= amount, "No allowance. Please grant StakingThales allowance" ); require(unstaking[msg.sender] == false, "Cannot stake, the staker is paused from staking due to unstaking"); // Check if there are not claimable rewards from last period. // Claim them, and add new stake if ((_lastRewardsClaimedPeriod[msg.sender] < periodsOfStaking) && claimEnabled && _stakedBalances[msg.sender] > 0) { _claimReward(msg.sender); } // if just started staking subtract his escrowed balance from totalEscrowBalanceNotIncludedInStaking if (_stakedBalances[msg.sender] == 0) { if (iEscrowThales.totalAccountEscrowedAmount(msg.sender) > 0) { iEscrowThales.subtractTotalEscrowBalanceNotIncludedInStaking( iEscrowThales.totalAccountEscrowedAmount(msg.sender) ); } } _totalStakedAmount = _totalStakedAmount.add(amount); _stakedBalances[msg.sender] = _stakedBalances[msg.sender].add(amount); stakingToken.safeTransferFrom(msg.sender, address(this), amount); emit Staked(msg.sender, amount); } function startUnstake(uint amount) external { require(amount > 0, "Cannot unstake 0"); require(_stakedBalances[msg.sender] >= amount, "Account doesnt have that much staked"); require(unstaking[msg.sender] == false, "Account has already triggered unstake cooldown"); if ((_lastRewardsClaimedPeriod[msg.sender] < periodsOfStaking) && claimEnabled) { claimReward(); } lastUnstakeTime[msg.sender] = block.timestamp; unstaking[msg.sender] = true; _totalStakedAmount = _totalStakedAmount.sub(amount); unstakingAmount[msg.sender] = amount; _stakedBalances[msg.sender] = _stakedBalances[msg.sender].sub(amount); // on full unstake add his escrowed balance to totalEscrowBalanceNotIncludedInStaking if (_stakedBalances[msg.sender] == 0) { if (iEscrowThales.totalAccountEscrowedAmount(msg.sender) > 0) { iEscrowThales.addTotalEscrowBalanceNotIncludedInStaking( iEscrowThales.totalAccountEscrowedAmount(msg.sender) ); } } emit UnstakeCooldown(msg.sender, lastUnstakeTime[msg.sender].add(unstakeDurationPeriod), amount); } function cancelUnstake() external { require(unstaking[msg.sender] == true, "Account is not unstaking"); // on revert full unstake remove his escrowed balance from totalEscrowBalanceNotIncludedInStaking if (_stakedBalances[msg.sender] == 0) { if (iEscrowThales.totalAccountEscrowedAmount(msg.sender) > 0) { iEscrowThales.subtractTotalEscrowBalanceNotIncludedInStaking( iEscrowThales.totalAccountEscrowedAmount(msg.sender) ); } } unstaking[msg.sender] = false; _totalStakedAmount = _totalStakedAmount.add(unstakingAmount[msg.sender]); _stakedBalances[msg.sender] = _stakedBalances[msg.sender].add(unstakingAmount[msg.sender]); unstakingAmount[msg.sender] = 0; emit CancelUnstake(msg.sender); } function unstake() external { require(unstaking[msg.sender] == true, "Account has not triggered unstake cooldown"); require( lastUnstakeTime[msg.sender] < block.timestamp.sub(unstakeDurationPeriod), "Cannot unstake yet, cooldown not expired." ); unstaking[msg.sender] = false; uint unstakeAmount = unstakingAmount[msg.sender]; stakingToken.safeTransfer(msg.sender, unstakeAmount); unstakingAmount[msg.sender] = 0; emit Unstaked(msg.sender, unstakeAmount); } function claimReward() public nonReentrant notPaused { _claimReward(msg.sender); } function selfDestruct(address payable account) external onlyOwner { stakingToken.safeTransfer(account, stakingToken.balanceOf(address(this))); feeToken.safeTransfer(account, feeToken.balanceOf(address(this))); selfdestruct(account); } /* ========== INTERNAL FUNCTIONS ========== */ function _claimReward(address account) internal notPaused { require(claimEnabled, "Claiming is not enabled."); require(startTimeStamp > 0, "Staking period has not started"); //Calculate rewards if (distributeFeesEnabled) { uint availableFeesToClaim = _calculateAvailableFeesToClaim(account); if (availableFeesToClaim > 0) { feeToken.safeTransfer(account, availableFeesToClaim); stakerFeesClaimed[account] = stakerFeesClaimed[account].add(availableFeesToClaim); _totalRewardFeesClaimed = _totalRewardFeesClaimed.add(availableFeesToClaim); emit FeeRewardsClaimed(account, availableFeesToClaim); } } uint availableRewardsToClaim = _calculateAvailableRewardsToClaim(account); if (availableRewardsToClaim > 0) { // Transfer THALES to Escrow contract iEscrowThales.addToEscrow(account, availableRewardsToClaim); // Record the total claimed rewards stakerLifetimeRewardsClaimed[account] = stakerLifetimeRewardsClaimed[account].add(availableRewardsToClaim); _totalRewardsClaimed = _totalRewardsClaimed.add(availableRewardsToClaim); _totalUnclaimedRewards = _totalUnclaimedRewards.sub(availableRewardsToClaim); emit RewardsClaimed(account, availableRewardsToClaim); } // Update last claiming period _lastRewardsClaimedPeriod[account] = periodsOfStaking; } function _calculateAvailableRewardsToClaim(address account) internal view returns (uint) { if ((_stakedBalances[account] == 0) || (_lastRewardsClaimedPeriod[account] == periodsOfStaking)) { return 0; } return _stakedBalances[account] .add(iEscrowThales.getStakedEscrowedBalanceForRewards(account)) .mul(currentPeriodRewards) .div(_totalStakedAmount.add(_totalEscrowedAmount)); } function _calculateAvailableFeesToClaim(address account) internal view returns (uint) { if ((_stakedBalances[account] == 0) || (_lastRewardsClaimedPeriod[account] == periodsOfStaking)) { return 0; } return _stakedBalances[account] .add(iEscrowThales.getStakedEscrowedBalanceForRewards(account)) .mul(currentPeriodFees) .div(_totalStakedAmount.add(_totalEscrowedAmount)); } /* ========== EVENTS ========== */ event RewardAdded(uint reward); event Staked(address user, uint amount); event ClosedPeriod(uint PeriodOfStaking, uint lastPeriodTimeStamp); event RewardsClaimed(address account, uint unclaimedReward); event FeeRewardsClaimed(address account, uint unclaimedFees); event UnstakeCooldown(address account, uint cooldownTime, uint amount); event CancelUnstake(address account); event Unstaked(address account, uint unstakeAmount); event ClaimEnabled(bool enabled); event DistributeFeesEnabled(bool enabled); event FixedPeriodRewardChanged(uint value); event DurationPeriodChanged(uint value); event UnstakeDurationPeriodChanged(uint value); event EscrowChanged(address newEscrow); event StakingPeriodStarted(); }
pragma solidity ^0.5.0; /** * @dev Standard math utilities missing in the Solidity language. */ library Math { /** * @dev Returns the largest of two numbers. */ function max(uint256 a, uint256 b) internal pure returns (uint256) { return a >= b ? a : b; } /** * @dev Returns the smallest of two numbers. */ function min(uint256 a, uint256 b) internal pure returns (uint256) { return a < b ? a : b; } /** * @dev Returns the average of two numbers. The result is rounded towards * zero. */ function average(uint256 a, uint256 b) internal pure returns (uint256) { // (a + b) / 2 can overflow, so we distribute return (a / 2) + (b / 2) + ((a % 2 + b % 2) / 2); } }
pragma solidity ^0.5.0; import "./IERC20.sol"; import "../../math/SafeMath.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 ERC20;` statement to your contract, * which allows you to call the safe operations as `token.safeTransfer(...)`, etc. */ library SafeERC20 { using SafeMath for uint256; using Address for address; function safeTransfer(IERC20 token, address to, uint256 value) internal { callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value)); } function safeTransferFrom(IERC20 token, address from, address to, uint256 value) internal { callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value)); } 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' // solhint-disable-next-line max-line-length 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)); } function safeIncreaseAllowance(IERC20 token, address spender, uint256 value) internal { uint256 newAllowance = token.allowance(address(this), spender).add(value); callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } function safeDecreaseAllowance(IERC20 token, address spender, uint256 value) internal { uint256 newAllowance = token.allowance(address(this), spender).sub(value); callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } /** * @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. // A Solidity high level call has three parts: // 1. The target address is checked to verify it contains contract code // 2. The call itself is made, and success asserted // 3. The return value is decoded, which in turn checks the size of the returned data. // solhint-disable-next-line max-line-length require(address(token).isContract(), "SafeERC20: call to non-contract"); // solhint-disable-next-line avoid-low-level-calls (bool success, bytes memory returndata) = address(token).call(data); require(success, "SafeERC20: low-level call failed"); if (returndata.length > 0) { // Return data is optional // solhint-disable-next-line max-line-length require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed"); } } }
pragma solidity ^0.5.16; // Libraries import "openzeppelin-solidity-2.3.0/contracts/math/SafeMath.sol"; // https://docs.synthetix.io/contracts/source/libraries/safedecimalmath library SafeDecimalMath { using SafeMath for uint; /* Number of decimal places in the representations. */ uint8 public constant decimals = 18; uint8 public constant highPrecisionDecimals = 27; /* The number representing 1.0. */ uint public constant UNIT = 10**uint(decimals); /* The number representing 1.0 for higher fidelity numbers. */ uint public constant PRECISE_UNIT = 10**uint(highPrecisionDecimals); uint private constant UNIT_TO_HIGH_PRECISION_CONVERSION_FACTOR = 10**uint(highPrecisionDecimals - decimals); /** * @return Provides an interface to UNIT. */ function unit() external pure returns (uint) { return UNIT; } /** * @return Provides an interface to PRECISE_UNIT. */ function preciseUnit() external pure returns (uint) { return PRECISE_UNIT; } /** * @return The result of multiplying x and y, interpreting the operands as fixed-point * decimals. * * @dev A unit factor is divided out after the product of x and y is evaluated, * so that product must be less than 2**256. As this is an integer division, * the internal division always rounds down. This helps save on gas. Rounding * is more expensive on gas. */ function multiplyDecimal(uint x, uint y) internal pure returns (uint) { /* Divide by UNIT to remove the extra factor introduced by the product. */ return x.mul(y) / UNIT; } /** * @return The result of safely multiplying x and y, interpreting the operands * as fixed-point decimals of the specified precision unit. * * @dev The operands should be in the form of a the specified unit factor which will be * divided out after the product of x and y is evaluated, so that product must be * less than 2**256. * * Unlike multiplyDecimal, this function rounds the result to the nearest increment. * Rounding is useful when you need to retain fidelity for small decimal numbers * (eg. small fractions or percentages). */ function _multiplyDecimalRound( uint x, uint y, uint precisionUnit ) private pure returns (uint) { /* Divide by UNIT to remove the extra factor introduced by the product. */ uint quotientTimesTen = x.mul(y) / (precisionUnit / 10); if (quotientTimesTen % 10 >= 5) { quotientTimesTen += 10; } return quotientTimesTen / 10; } /** * @return The result of safely multiplying x and y, interpreting the operands * as fixed-point decimals of a precise unit. * * @dev The operands should be in the precise unit factor which will be * divided out after the product of x and y is evaluated, so that product must be * less than 2**256. * * Unlike multiplyDecimal, this function rounds the result to the nearest increment. * Rounding is useful when you need to retain fidelity for small decimal numbers * (eg. small fractions or percentages). */ function multiplyDecimalRoundPrecise(uint x, uint y) internal pure returns (uint) { return _multiplyDecimalRound(x, y, PRECISE_UNIT); } /** * @return The result of safely multiplying x and y, interpreting the operands * as fixed-point decimals of a standard unit. * * @dev The operands should be in the standard unit factor which will be * divided out after the product of x and y is evaluated, so that product must be * less than 2**256. * * Unlike multiplyDecimal, this function rounds the result to the nearest increment. * Rounding is useful when you need to retain fidelity for small decimal numbers * (eg. small fractions or percentages). */ function multiplyDecimalRound(uint x, uint y) internal pure returns (uint) { return _multiplyDecimalRound(x, y, UNIT); } /** * @return The result of safely dividing x and y. The return value is a high * precision decimal. * * @dev y is divided after the product of x and the standard precision unit * is evaluated, so the product of x and UNIT must be less than 2**256. As * this is an integer division, the result is always rounded down. * This helps save on gas. Rounding is more expensive on gas. */ function divideDecimal(uint x, uint y) internal pure returns (uint) { /* Reintroduce the UNIT factor that will be divided out by y. */ return x.mul(UNIT).div(y); } /** * @return The result of safely dividing x and y. The return value is as a rounded * decimal in the precision unit specified in the parameter. * * @dev y is divided after the product of x and the specified precision unit * is evaluated, so the product of x and the specified precision unit must * be less than 2**256. The result is rounded to the nearest increment. */ function _divideDecimalRound( uint x, uint y, uint precisionUnit ) private pure returns (uint) { uint resultTimesTen = x.mul(precisionUnit * 10).div(y); if (resultTimesTen % 10 >= 5) { resultTimesTen += 10; } return resultTimesTen / 10; } /** * @return The result of safely dividing x and y. The return value is as a rounded * standard precision decimal. * * @dev y is divided after the product of x and the standard precision unit * is evaluated, so the product of x and the standard precision unit must * be less than 2**256. The result is rounded to the nearest increment. */ function divideDecimalRound(uint x, uint y) internal pure returns (uint) { return _divideDecimalRound(x, y, UNIT); } /** * @return The result of safely dividing x and y. The return value is as a rounded * high precision decimal. * * @dev y is divided after the product of x and the high precision unit * is evaluated, so the product of x and the high precision unit must * be less than 2**256. The result is rounded to the nearest increment. */ function divideDecimalRoundPrecise(uint x, uint y) internal pure returns (uint) { return _divideDecimalRound(x, y, PRECISE_UNIT); } /** * @dev Convert a standard decimal representation to a high precision one. */ function decimalToPreciseDecimal(uint i) internal pure returns (uint) { return i.mul(UNIT_TO_HIGH_PRECISION_CONVERSION_FACTOR); } /** * @dev Convert a high precision decimal to a standard decimal representation. */ function preciseDecimalToDecimal(uint i) internal pure returns (uint) { uint quotientTimesTen = i / (UNIT_TO_HIGH_PRECISION_CONVERSION_FACTOR / 10); if (quotientTimesTen % 10 >= 5) { quotientTimesTen += 10; } return quotientTimesTen / 10; } }
pragma solidity ^0.5.0; /** * @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. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be aplied to your functions to restrict their use to * the owner. */ contract Ownable { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor () internal { _owner = msg.sender; emit OwnershipTransferred(address(0), _owner); } /** * @dev Returns the address of the current owner. */ function owner() public view returns (address) { return _owner; } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { require(isOwner(), "Ownable: caller is not the owner"); _; } /** * @dev Returns true if the caller is the current owner. */ function isOwner() public view returns (bool) { return msg.sender == _owner; } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * > Note: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public onlyOwner { emit OwnershipTransferred(_owner, address(0)); _owner = 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 onlyOwner { _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). */ function _transferOwnership(address newOwner) internal { require(newOwner != address(0), "Ownable: new owner is the zero address"); emit OwnershipTransferred(_owner, newOwner); _owner = newOwner; } }
pragma solidity ^0.5.0; /** * @dev Contract module that helps prevent reentrant calls to a function. * * Inheriting from `ReentrancyGuard` will make the `nonReentrant` modifier * available, which can be aplied 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. */ contract ReentrancyGuard { /// @dev counter to allow mutex lock with only one SSTORE operation uint256 private _guardCounter; constructor () internal { // The counter starts at one to prevent changing it from zero to a non-zero // value, which is a more expensive operation. _guardCounter = 1; } /** * @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 make it call a * `private` function that does the actual work. */ modifier nonReentrant() { _guardCounter += 1; uint256 localCounter = _guardCounter; _; require(localCounter == _guardCounter, "ReentrancyGuard: reentrant call"); } }
pragma solidity ^0.5.16; // Inheritance import "./Owned.sol"; // https://docs.synthetix.io/contracts/source/contracts/pausable contract Pausable is Owned { uint public lastPauseTime; bool public paused; constructor() internal { // This contract is abstract, and thus cannot be instantiated directly require(owner != address(0), "Owner must be set"); // Paused will be false, and lastPauseTime will be 0 upon initialisation } /** * @notice Change the paused state of the contract * @dev Only the contract owner may call this. */ function setPaused(bool _paused) external onlyOwner { // Ensure we're actually changing the state before we do anything if (_paused == paused) { return; } // Set our paused state. paused = _paused; // If applicable, set the last pause time. if (paused) { lastPauseTime = now; } // Let everyone know that our pause state has changed. emit PauseChanged(paused); } event PauseChanged(bool isPaused); modifier notPaused { require(!paused, "This action cannot be performed while the contract is paused"); _; } }
pragma solidity >=0.4.24; interface IEscrowThales { /* ========== VIEWS / VARIABLES ========== */ function getStakerPeriod(address account, uint index) external view returns (uint); function getStakerAmounts(address account, uint index) external view returns (uint); function totalAccountEscrowedAmount(address account) external view returns (uint); function getStakedEscrowedBalanceForRewards(address account) external view returns (uint); function totalEscrowedRewards() external view returns (uint); function totalEscrowBalanceNotIncludedInStaking() external view returns (uint); function currentVestingPeriod() external view returns (uint); function updateCurrentPeriod() external returns (bool); function claimable(address account) external view returns (uint); function addToEscrow(address account, uint amount) external; function vest(uint amount) external returns (bool); function addTotalEscrowBalanceNotIncludedInStaking(uint amount) external; function subtractTotalEscrowBalanceNotIncludedInStaking(uint amount) external; }
pragma solidity >=0.4.24; interface IStakingThales { /* ========== VIEWS / VARIABLES ========== */ function totalStakedAmount() external view returns (uint); function stakedBalanceOf(address account) external view returns (uint); function currentPeriodRewards() external view returns (uint); function currentPeriodFees() external view returns (uint); function getLastPeriodOfClaimedRewards(address account) external view returns (uint); function getRewardsAvailable(address account) external view returns (uint); function getRewardFeesAvailable(address account) external view returns (uint); function getAlreadyClaimedRewards(address account) external view returns (uint); function getAlreadyClaimedFees(address account) external view returns (uint); function getContractRewardFunds() external view returns (uint); function getContractFeeFunds() external view returns (uint); }
pragma solidity ^0.5.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. Does not include * the optional functions; to access them see `ERC20Detailed`. */ interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a `Transfer` event. */ function transfer(address recipient, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through `transferFrom`. This is * zero by default. * * This value changes when `approve` or `transferFrom` are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * > Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an `Approval` event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `sender` to `recipient` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a `Transfer` event. */ function transferFrom(address sender, address recipient, uint256 amount) external returns (bool); /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to `approve`. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); }
pragma solidity ^0.5.0; /** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming languages. * `SafeMath` restores this intuition by reverting the transaction when an * operation overflows. * * Using this library instead of the unchecked operations eliminates an entire * class of bugs, so it's recommended to use it always. */ library SafeMath { /** * @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) { uint256 c = a + b; require(c >= a, "SafeMath: addition overflow"); return c; } /** * @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) { require(b <= a, "SafeMath: subtraction overflow"); uint256 c = a - b; return c; } /** * @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) { // 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-solidity/pull/522 if (a == 0) { return 0; } uint256 c = a * b; require(c / a == b, "SafeMath: multiplication overflow"); return c; } /** * @dev Returns the integer division of two unsigned integers. Reverts 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) internal pure returns (uint256) { // Solidity only automatically asserts when dividing by 0 require(b > 0, "SafeMath: division by zero"); uint256 c = a / b; // assert(a == b * c + a % b); // There is no case in which this doesn't hold return c; } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * Reverts 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) { require(b != 0, "SafeMath: modulo by zero"); return a % b; } }
pragma solidity ^0.5.0; /** * @dev Collection of functions related to the address type, */ library Address { /** * @dev Returns true if `account` is a contract. * * This test is non-exhaustive, and there may be false-negatives: during the * execution of a contract's constructor, its address will be reported as * not containing a contract. * * > It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. */ function isContract(address account) internal view returns (bool) { // This method relies in extcodesize, which returns 0 for contracts in // construction, since the code is only stored at the end of the // constructor execution. uint256 size; // solhint-disable-next-line no-inline-assembly assembly { size := extcodesize(account) } return size > 0; } }
pragma solidity ^0.5.16; // https://docs.synthetix.io/contracts/source/contracts/owned contract Owned { address public owner; address public nominatedOwner; constructor(address _owner) public { require(_owner != address(0), "Owner address cannot be 0"); owner = _owner; emit OwnerChanged(address(0), _owner); } function nominateNewOwner(address _owner) external onlyOwner { nominatedOwner = _owner; emit OwnerNominated(_owner); } function acceptOwnership() external { require(msg.sender == nominatedOwner, "You must be nominated before you can accept ownership"); emit OwnerChanged(owner, nominatedOwner); owner = nominatedOwner; nominatedOwner = address(0); } modifier onlyOwner { _onlyOwner(); _; } function _onlyOwner() private view { require(msg.sender == owner, "Only the contract owner may perform this action"); } event OwnerNominated(address newOwner); event OwnerChanged(address oldOwner, address newOwner); }
{ "optimizer": { "enabled": true, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address","name":"_owner","type":"address"},{"internalType":"address","name":"_iEscrowThales","type":"address"},{"internalType":"address","name":"_stakingToken","type":"address"},{"internalType":"address","name":"_feeToken","type":"address"},{"internalType":"uint256","name":"_durationPeriod","type":"uint256"},{"internalType":"uint256","name":"_unstakeDurationPeriod","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"CancelUnstake","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"enabled","type":"bool"}],"name":"ClaimEnabled","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"PeriodOfStaking","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"lastPeriodTimeStamp","type":"uint256"}],"name":"ClosedPeriod","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"enabled","type":"bool"}],"name":"DistributeFeesEnabled","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"DurationPeriodChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"newEscrow","type":"address"}],"name":"EscrowChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"unclaimedFees","type":"uint256"}],"name":"FeeRewardsClaimed","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"FixedPeriodRewardChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"oldOwner","type":"address"},{"indexed":false,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnerChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnerNominated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"isPaused","type":"bool"}],"name":"PauseChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"reward","type":"uint256"}],"name":"RewardAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"unclaimedReward","type":"uint256"}],"name":"RewardsClaimed","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Staked","type":"event"},{"anonymous":false,"inputs":[],"name":"StakingPeriodStarted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"cooldownTime","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"UnstakeCooldown","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"UnstakeDurationPeriodChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"unstakeAmount","type":"uint256"}],"name":"Unstaked","type":"event"},{"constant":false,"inputs":[],"name":"acceptOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"cancelUnstake","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"claimEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"claimReward","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"closePeriod","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"currentPeriodFees","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"currentPeriodRewards","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"distributeFeesEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"durationPeriod","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"feeToken","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"fixedPeriodReward","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"getAlreadyClaimedFees","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"getAlreadyClaimedRewards","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"getContractFeeFunds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"getContractRewardFunds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"getLastPeriodOfClaimedRewards","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"getRewardFeesAvailable","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"getRewardsAvailable","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"iEscrowThales","outputs":[{"internalType":"contract IEscrowThales","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"lastPauseTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"lastPeriodTimeStamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"lastUnstakeTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"_owner","type":"address"}],"name":"nominateNewOwner","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"nominatedOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"periodsOfStaking","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address payable","name":"account","type":"address"}],"name":"selfDestruct","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"bool","name":"_claimEnabled","type":"bool"}],"name":"setClaimEnabled","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"bool","name":"_distributeFeesEnabled","type":"bool"}],"name":"setDistributeFeesEnabled","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"uint256","name":"_durationPeriod","type":"uint256"}],"name":"setDurationPeriod","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"_escrowThalesContract","type":"address"}],"name":"setEscrow","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"uint256","name":"_fixedReward","type":"uint256"}],"name":"setFixedPeriodReward","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"bool","name":"_paused","type":"bool"}],"name":"setPaused","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"uint256","name":"_unstakeDurationPeriod","type":"uint256"}],"name":"setUnstakeDurationPeriod","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"stake","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"stakedBalanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"stakerFeesClaimed","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"stakerLifetimeRewardsClaimed","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"stakingToken","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"startStakingPeriod","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"startTimeStamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"startUnstake","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"totalStakedAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"unstake","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"unstakeDurationPeriod","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"unstaking","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"unstakingAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"}]
Contract Creation Code
608060405260006007819055600881905562093a806009819055600a55600b819055600c819055600d55600e805460ff1990811690915569152d02c7e14af6800000600f556010805490911690553480156200005a57600080fd5b5060405162002ecf38038062002ecf833981810160405260c08110156200008057600080fd5b508051602082015160408301516060840151608085015160a0909501519394929391929091856001600160a01b03811662000102576040805162461bcd60e51b815260206004820152601960248201527f4f776e657220616464726573732063616e6e6f74206265203000000000000000604482015290519081900360640190fd5b600080546001600160a01b0319166001600160a01b038316908117825560408051928352602083019190915280517fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c9281900390910190a15060016002556000546001600160a01b0316620001b2576040805162461bcd60e51b815260206004820152601160248201527013dddb995c881b5d5cdd081899481cd95d607a1b604482015290519081900360640190fd5b60048054610100600160a81b0319166101006001600160a01b03888116918202929092178355600580546001600160a01b03199081168985161791829055600680549091168885161790556040805163095ea7b360e01b8152948501929092526000196024850152905191169163095ea7b39160448083019260209291908290030181600087803b1580156200024757600080fd5b505af11580156200025c573d6000803e3d6000fd5b505050506040513d60208110156200027357600080fd5b5050600991909155600a5550505050612c3d80620002926000396000f3fe608060405234801561001057600080fd5b50600436106102a05760003560e01c8063647846a511610167578063a694fc3a116100ce578063cf44932711610087578063cf44932714610643578063d66e067714610660578063dd206d7c14610668578063e11cd0551461068e578063f38d00f014610696578063f3a467e31461069e576102a0565b8063a694fc3a146105ab578063ad2ce46b146105c8578063b88a802f146105e7578063ba47a5d9146105ef578063c10c3546146105f7578063cb8d751a1461061d576102a0565b80637c17f6fc116101205780637c17f6fc146105465780638a239de81461054e5780638da5cb5b1461057457806391b4ded91461057c57806392929a091461058457806393eb2e66146105a3576102a0565b8063647846a5146104c557806364c83591146104cd5780636ec0cd07146104f357806372f702f31461051057806379ba5097146105185780637a68567714610520576102a0565b806334dfb2681161020b57806353a47bb7116101c457806353a47bb71461049557806353cf41151461049d578063567e98f9146104a55780635c975abb146104ad57806362139e0e146104b55780636282719e146104bd576102a0565b806334dfb268146104145780633f5a0bdd146104315780633faae534146104575780634ab179691461045f5780634c4e75df14610467578063507a73281461048d576102a0565b8063200743541161025d57806320074354146103785780632866ed21146103805780632d2878861461039c5780632def6620146103c25780632f324158146103ca578063331e03a8146103ee576102a0565b8063080e2b47146102a55780631314f759146102dd57806315da5064146103035780631627540c1461030b578063167653911461033357806316c38b3c14610359575b600080fd5b6102cb600480360360208110156102bb57600080fd5b50356001600160a01b03166106bb565b60408051918252519081900360200190f35b6102cb600480360360208110156102f357600080fd5b50356001600160a01b03166106cd565b6102cb6106e0565b6103316004803603602081101561032157600080fd5b50356001600160a01b03166106e6565b005b6102cb6004803603602081101561034957600080fd5b50356001600160a01b0316610742565b6103316004803603602081101561036f57600080fd5b5035151561075d565b6102cb6107d7565b6103886107dd565b604080519115158252519081900360200190f35b6102cb600480360360208110156103b257600080fd5b50356001600160a01b03166107e6565b6103316107f8565b6103d261093b565b604080516001600160a01b039092168252519081900360200190f35b6102cb6004803603602081101561040457600080fd5b50356001600160a01b031661094f565b6103316004803603602081101561042a57600080fd5b5035610961565b6103316004803603602081101561044757600080fd5b50356001600160a01b0316610cc6565b6102cb610e06565b610331610e82565b6102cb6004803603602081101561047d57600080fd5b50356001600160a01b0316611116565b610331611131565b6103d2611543565b610388611552565b6102cb61155b565b610388611561565b6102cb61156a565b610331611570565b6103d2611627565b6102cb600480360360208110156104e357600080fd5b50356001600160a01b0316611636565b6103316004803603602081101561050957600080fd5b5035611648565b6103d261168b565b61033161169a565b6102cb6004803603602081101561053657600080fd5b50356001600160a01b0316611756565b6102cb611761565b6102cb6004803603602081101561056457600080fd5b50356001600160a01b0316611767565b6103d2611782565b6102cb611791565b6103316004803603602081101561059a57600080fd5b50351515611797565b6102cb6117e6565b610331600480360360208110156105c157600080fd5b50356117ec565b610331600480360360208110156105de57600080fd5b50351515611c94565b610331611ce3565b6102cb611d8f565b6103316004803603602081101561060d57600080fd5b50356001600160a01b0316611d95565b6103886004803603602081101561063357600080fd5b50356001600160a01b0316611f22565b6103316004803603602081101561065957600080fd5b5035611f37565b6102cb611f7a565b6102cb6004803603602081101561067e57600080fd5b50356001600160a01b0316611fc5565b6102cb611fe0565b6102cb611fe6565b610331600480360360208110156106b457600080fd5b5035611fec565b60126020526000908152604090205481565b60006106d88261202f565b90505b919050565b600f5481565b6106ee612171565b600180546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f906a1c6bd7e3091ea86693dd029a831c19049ce77f1dce2ce0bab1cacbabce229181900360200190a150565b6001600160a01b03166000908152601c602052604090205490565b610765612171565b60045460ff161515811515141561077b576107d4565b6004805460ff1916821515179081905560ff161561079857426003555b6004546040805160ff90921615158252517f8fb6c181ee25a520cf3dd6565006ef91229fcfe5a989566c2a3b8c115570cec59181900360200190a15b50565b60085481565b60105460ff1681565b601b6020526000908152604090205481565b336000908152601a602052604090205460ff16151560011461084b5760405162461bcd60e51b815260040180806020018281038252602a815260200180612a2c602a913960400191505060405180910390fd5b600a5461085f90429063ffffffff6121bc16565b33600090815260196020526040902054106108ab5760405162461bcd60e51b8152600401808060200182810382526029815260200180612a036029913960400191505060405180910390fd5b336000818152601a60209081526040808320805460ff19169055601b90915290205460055490916108ec916001600160a01b0316908363ffffffff61221e16565b336000818152601b60209081526040808320929092558151928352820183905280517f0f5bb82176feb1b5e747e28471aa92156a04d9f3ab9f45f28e2d704232b93f759281900390910190a150565b60045461010090046001600160a01b031681565b60196020526000908152604090205481565b600081116109a9576040805162461bcd60e51b815260206004820152601060248201526f043616e6e6f7420756e7374616b6520360841b604482015290519081900360640190fd5b336000908152601c60205260409020548111156109f75760405162461bcd60e51b8152600401808060200182810382526024815260200180612b896024913960400191505060405180910390fd5b336000908152601a602052604090205460ff1615610a465760405162461bcd60e51b815260040180806020018281038252602e815260200180612b1f602e913960400191505060405180910390fd5b600754336000908152601d6020526040902054108015610a68575060105460ff165b15610a7557610a75611ce3565b336000908152601960209081526040808320429055601a9091529020805460ff19166001179055601354610aaf908263ffffffff6121bc16565b601355336000908152601b60209081526040808320849055601c909152902054610adf908263ffffffff6121bc16565b336000908152601c60205260409020819055610c555760048054604080516334c78ae560e11b81523393810193909352516000926101009092046001600160a01b03169163698f15ca916024808301926020929190829003018186803b158015610b4857600080fd5b505afa158015610b5c573d6000803e3d6000fd5b505050506040513d6020811015610b7257600080fd5b50511115610c555760048054604080516334c78ae560e11b81523393810193909352516101009091046001600160a01b031691635817d04291839163698f15ca916024808301926020929190829003018186803b158015610bd257600080fd5b505afa158015610be6573d6000803e3d6000fd5b505050506040513d6020811015610bfc57600080fd5b5051604080516001600160e01b031960e085901b168152600481019290925251602480830192600092919082900301818387803b158015610c3c57600080fd5b505af1158015610c50573d6000803e3d6000fd5b505050505b600a54336000818152601960205260409020547f30797de805f090008d8b19fa0c6f92d0f164789f64d6f7a1b097fbf0b1abac6b92610c9a919063ffffffff61227516565b604080516001600160a01b0390931683526020830191909152818101849052519081900360600190a150565b610cce612171565b600554604080516370a0823160e01b81523060048201529051610d649284926001600160a01b03909116916370a0823191602480820192602092909190829003018186803b158015610d1f57600080fd5b505afa158015610d33573d6000803e3d6000fd5b505050506040513d6020811015610d4957600080fd5b50516005546001600160a01b0316919063ffffffff61221e16565b600654604080516370a0823160e01b81523060048201529051610dfa9284926001600160a01b03909116916370a0823191602480820192602092909190829003018186803b158015610db557600080fd5b505afa158015610dc9573d6000803e3d6000fd5b505050506040513d6020811015610ddf57600080fd5b50516006546001600160a01b0316919063ffffffff61221e16565b806001600160a01b0316ff5b600554604080516370a0823160e01b815230600482015290516000926001600160a01b0316916370a08231916024808301926020929190829003018186803b158015610e5157600080fd5b505afa158015610e65573d6000803e3d6000fd5b505050506040513d6020811015610e7b57600080fd5b5051905090565b336000908152601a602052604090205460ff161515600114610eeb576040805162461bcd60e51b815260206004820152601860248201527f4163636f756e74206973206e6f7420756e7374616b696e670000000000000000604482015290519081900360640190fd5b336000908152601c602052604090205461105f5760048054604080516334c78ae560e11b81523393810193909352516000926101009092046001600160a01b03169163698f15ca916024808301926020929190829003018186803b158015610f5257600080fd5b505afa158015610f66573d6000803e3d6000fd5b505050506040513d6020811015610f7c57600080fd5b5051111561105f5760048054604080516334c78ae560e11b81523393810193909352516101009091046001600160a01b03169163ad6d15de91839163698f15ca916024808301926020929190829003018186803b158015610fdc57600080fd5b505afa158015610ff0573d6000803e3d6000fd5b505050506040513d602081101561100657600080fd5b5051604080516001600160e01b031960e085901b168152600481019290925251602480830192600092919082900301818387803b15801561104657600080fd5b505af115801561105a573d6000803e3d6000fd5b505050505b336000908152601a60209081526040808320805460ff19169055601b9091529020546013546110939163ffffffff61227516565b601355336000908152601b6020908152604080832054601c909252909120546110c19163ffffffff61227516565b336000818152601c6020908152604080832094909455601b815283822091909155825191825291517f725ee3b9a70aadcb1e002c94935880d7f515620783a5144c90e39201dc6f92da929181900390910190a1565b6001600160a01b03166000908152601d602052604090205490565b600280546001019081905560045460ff161561117e5760405162461bcd60e51b815260040180806020018281038252603c815260200180612b4d603c913960400191505060405180910390fd5b6000600b54116111d5576040805162461bcd60e51b815260206004820152601e60248201527f5374616b696e6720706572696f6420686173206e6f7420737461727465640000604482015290519081900360640190fd5b6009546008546111ea9163ffffffff61227516565b4210156112285760405162461bcd60e51b8152600401808060200182810382526039815260200180612ae66039913960400191505060405180910390fd5b600460019054906101000a90046001600160a01b03166001600160a01b031663acfabbe46040518163ffffffff1660e01b8152600401602060405180830381600087803b15801561127857600080fd5b505af115801561128c573d6000803e3d6000fd5b505050506040513d60208110156112a257600080fd5b5050426008556004805460408051635d13850560e01b815290516101009092046001600160a01b031692635d138505928282019260209290829003018186803b1580156112ee57600080fd5b505afa158015611302573d6000803e3d6000fd5b505050506040513d602081101561131857600080fd5b505160075560048054604080516347d3681760e11b81529051611412936101009093046001600160a01b031692638fa6d02e92808201926020929091829003018186803b15801561136857600080fd5b505afa15801561137c573d6000803e3d6000fd5b505050506040513d602081101561139257600080fd5b5051600480546040805163b9d1c70b60e01b815290516101009092046001600160a01b03169263b9d1c70b928282019260209290829003018186803b1580156113da57600080fd5b505afa1580156113ee573d6000803e3d6000fd5b505050506040513d602081101561140457600080fd5b50519063ffffffff6121bc16565b601455600f54600c81905560165461142f9163ffffffff61227516565b601655600654604080516370a0823160e01b815230600482015290516001600160a01b03909216916370a0823191602480820192602092909190829003018186803b15801561147d57600080fd5b505afa158015611491573d6000803e3d6000fd5b505050506040513d60208110156114a757600080fd5b5051600d5560075460085460408051928352602083019190915280517f80827f48a8070d07af7887688320aadf44499e3a2751fc41cc965870cf0627d79281900390910190a160025481146107d4576040805162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b6001546001600160a01b031681565b600e5460ff1681565b60135490565b60045460ff1681565b60095481565b611578612171565b600b54156115cd576040805162461bcd60e51b815260206004820152601b60248201527f5374616b696e672068617320616c726561647920737461727465640000000000604482015290519081900360640190fd5b42600b819055600060078190556008919091556016819055601781905560188190556013819055601481905560158190556040517f7c01398e484f9a82feaa276906d5d1f84867a0ff5a5bd9a485d4357f58d401839190a1565b6006546001600160a01b031681565b60116020526000908152604090205481565b611650612171565b600f8190556040805182815290517f14287d4a2613a9be7577831054c6f7b3d27c4912fb53929a1d626342def8aada9181900360200190a150565b6005546001600160a01b031681565b6001546001600160a01b031633146116e35760405162461bcd60e51b81526004018080602001828103825260358152602001806129ce6035913960400191505060405180910390fd5b600054600154604080516001600160a01b03938416815292909116602083015280517fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c9281900390910190a160018054600080546001600160a01b03199081166001600160a01b03841617909155169055565b60006106d8826122d6565b60075481565b6001600160a01b031660009081526011602052604090205490565b6000546001600160a01b031681565b60035481565b61179f612171565b6010805482151560ff19909116811790915560408051918252517f1edd4dc7f91a5992aba0f39c0428bcf4df13d001eebc26eb188307d057f14a079181900360200190a150565b600a5481565b600280546001019081905560045460ff16156118395760405162461bcd60e51b815260040180806020018281038252603c815260200180612b4d603c913960400191505060405180910390fd5b6000600b5411611890576040805162461bcd60e51b815260206004820152601e60248201527f5374616b696e6720706572696f6420686173206e6f7420737461727465640000604482015290519081900360640190fd5b600082116118d6576040805162461bcd60e51b815260206004820152600e60248201526d043616e6e6f74207374616b6520360941b604482015290519081900360640190fd5b60055460408051636eb1769f60e11b8152336004820152306024820152905184926001600160a01b03169163dd62ed3e916044808301926020929190829003018186803b15801561192657600080fd5b505afa15801561193a573d6000803e3d6000fd5b505050506040513d602081101561195057600080fd5b5051101561198f5760405162461bcd60e51b8152600401808060200182810382526032815260200180612bd76032913960400191505060405180910390fd5b336000908152601a602052604090205460ff16156119de5760405162461bcd60e51b8152600401808060200182810382526040815260200180612a566040913960400191505060405180910390fd5b600754336000908152601d6020526040902054108015611a00575060105460ff165b8015611a1a5750336000908152601c602052604090205415155b15611a2857611a28336123af565b336000908152601c6020526040902054611b9c5760048054604080516334c78ae560e11b81523393810193909352516000926101009092046001600160a01b03169163698f15ca916024808301926020929190829003018186803b158015611a8f57600080fd5b505afa158015611aa3573d6000803e3d6000fd5b505050506040513d6020811015611ab957600080fd5b50511115611b9c5760048054604080516334c78ae560e11b81523393810193909352516101009091046001600160a01b03169163ad6d15de91839163698f15ca916024808301926020929190829003018186803b158015611b1957600080fd5b505afa158015611b2d573d6000803e3d6000fd5b505050506040513d6020811015611b4357600080fd5b5051604080516001600160e01b031960e085901b168152600481019290925251602480830192600092919082900301818387803b158015611b8357600080fd5b505af1158015611b97573d6000803e3d6000fd5b505050505b601354611baf908363ffffffff61227516565b601355336000908152601c6020526040902054611bd2908363ffffffff61227516565b336000818152601c6020526040902091909155600554611bff916001600160a01b039091169030856126ec565b604080513381526020810184905281517f9e71bc8eea02a63969f509818f2dafb9254532904319f9dbda79b67bd34a5f3d929181900390910190a16002548114611c90576040805162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b5050565b611c9c612171565b600e805482151560ff19909116811790915560408051918252517f85de4a4b7db92534188eb7833a0fb258893c3829293a0ce3de521b189fb4619d9181900360200190a150565b600280546001019081905560045460ff1615611d305760405162461bcd60e51b815260040180806020018281038252603c815260200180612b4d603c913960400191505060405180910390fd5b611d39336123af565b60025481146107d4576040805162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b600d5481565b611d9d612171565b60045461010090046001600160a01b031615611e4557600554600480546040805163095ea7b360e01b81526101009092046001600160a01b03908116938301939093526000602483018190529051929093169263095ea7b3926044808401936020939083900390910190829087803b158015611e1857600080fd5b505af1158015611e2c573d6000803e3d6000fd5b505050506040513d6020811015611e4257600080fd5b50505b60048054610100600160a81b0319166101006001600160a01b038481169182029290921783556005546040805163095ea7b360e01b8152948501929092526000196024850152905191169163095ea7b39160448083019260209291908290030181600087803b158015611eb757600080fd5b505af1158015611ecb573d6000803e3d6000fd5b505050506040513d6020811015611ee157600080fd5b5050604080516001600160a01b038316815290517feb1a4b1e230d212e1644ea31e3890084e2fa17ddee990e46a46e198e1728c4a09181900360200190a150565b601a6020526000908152604090205460ff1681565b611f3f612171565b60098190556040805182815290517feb564dffd3daf74504b745a322550f31ab110ec5c012cc525d0e14f9b38436d19181900360200190a150565b600654604080516370a0823160e01b815230600482015290516000926001600160a01b0316916370a08231916024808301926020929190829003018186803b158015610e5157600080fd5b6001600160a01b031660009081526012602052604090205490565b600c5481565b600b5481565b611ff4612171565b600a8190556040805182815290517f119e399359baa8bc27eabe26ea23641a285b6a0cb3398a69a34f6f77efa4a29c9181900360200190a150565b6001600160a01b0381166000908152601c6020526040812054158061206d57506007546001600160a01b0383166000908152601d6020526040902054145b1561207a575060006106db565b6106d861209460145460135461227590919063ffffffff16565b612165600d54612159600460019054906101000a90046001600160a01b03166001600160a01b03166317640e07886040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561210857600080fd5b505afa15801561211c573d6000803e3d6000fd5b505050506040513d602081101561213257600080fd5b50516001600160a01b0388166000908152601c60205260409020549063ffffffff61227516565b9063ffffffff61274c16565b9063ffffffff6127a516565b6000546001600160a01b031633146121ba5760405162461bcd60e51b815260040180806020018281038252602f815260200180612a96602f913960400191505060405180910390fd5b565b600082821115612213576040805162461bcd60e51b815260206004820152601e60248201527f536166654d6174683a207375627472616374696f6e206f766572666c6f770000604482015290519081900360640190fd5b508082035b92915050565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b17905261227090849061280f565b505050565b6000828201838110156122cf576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b9392505050565b6001600160a01b0381166000908152601c6020526040812054158061231457506007546001600160a01b0383166000908152601d6020526040902054145b15612321575060006106db565b6106d861233b60145460135461227590919063ffffffff16565b612165600c54612159600460019054906101000a90046001600160a01b03166001600160a01b03166317640e07886040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561210857600080fd5b60045460ff16156123f15760405162461bcd60e51b815260040180806020018281038252603c815260200180612b4d603c913960400191505060405180910390fd5b60105460ff16612448576040805162461bcd60e51b815260206004820152601860248201527f436c61696d696e67206973206e6f7420656e61626c65642e0000000000000000604482015290519081900360640190fd5b6000600b541161249f576040805162461bcd60e51b815260206004820152601e60248201527f5374616b696e6720706572696f6420686173206e6f7420737461727465640000604482015290519081900360640190fd5b600e5460ff16156125795760006124b58261202f565b90508015612577576006546124da906001600160a01b0316838363ffffffff61221e16565b6001600160a01b038216600090815260126020526040902054612503908263ffffffff61227516565b6001600160a01b03831660009081526012602052604090205560185461252f908263ffffffff61227516565b601855604080516001600160a01b03841681526020810183905281517f5b16e1043a283423361eb77682c99aff55948b34296846800a1a7dc9547a89fc929181900390910190a15b505b6000612584826122d6565b905080156126cc57600460019054906101000a90046001600160a01b03166001600160a01b031663b01ca88f83836040518363ffffffff1660e01b815260040180836001600160a01b03166001600160a01b0316815260200182815260200192505050600060405180830381600087803b15801561260157600080fd5b505af1158015612615573d6000803e3d6000fd5b5050506001600160a01b03831660009081526011602052604090205461264291508263ffffffff61227516565b6001600160a01b03831660009081526011602052604090205560175461266e908263ffffffff61227516565b601755601654612684908263ffffffff6121bc16565b601655604080516001600160a01b03841681526020810183905281517ffc30cddea38e2bf4d6ea7d3f9ed3b6ad7f176419f4963bd81318067a4aee73fe929181900390910190a15b506007546001600160a01b039091166000908152601d6020526040902055565b604080516001600160a01b0385811660248301528416604482015260648082018490528251808303909101815260849091019091526020810180516001600160e01b03166323b872dd60e01b17905261274690859061280f565b50505050565b60008261275b57506000612218565b8282028284828161276857fe5b04146122cf5760405162461bcd60e51b8152600401808060200182810382526021815260200180612ac56021913960400191505060405180910390fd5b60008082116127fb576040805162461bcd60e51b815260206004820152601a60248201527f536166654d6174683a206469766973696f6e206279207a65726f000000000000604482015290519081900360640190fd5b600082848161280657fe5b04949350505050565b612821826001600160a01b03166129c7565b612872576040805162461bcd60e51b815260206004820152601f60248201527f5361666545524332303a2063616c6c20746f206e6f6e2d636f6e747261637400604482015290519081900360640190fd5b60006060836001600160a01b0316836040518082805190602001908083835b602083106128b05780518252601f199092019160209182019101612891565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d8060008114612912576040519150601f19603f3d011682016040523d82523d6000602084013e612917565b606091505b50915091508161296e576040805162461bcd60e51b815260206004820181905260248201527f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564604482015290519081900360640190fd5b8051156127465780806020019051602081101561298a57600080fd5b50516127465760405162461bcd60e51b815260040180806020018281038252602a815260200180612bad602a913960400191505060405180910390fd5b3b15159056fe596f75206d757374206265206e6f6d696e61746564206265666f726520796f752063616e20616363657074206f776e65727368697043616e6e6f7420756e7374616b65207965742c20636f6f6c646f776e206e6f7420657870697265642e4163636f756e7420686173206e6f742074726967676572656420756e7374616b6520636f6f6c646f776e43616e6e6f74207374616b652c20746865207374616b6572206973207061757365642066726f6d207374616b696e672064756520746f20756e7374616b696e674f6e6c792074686520636f6e7472616374206f776e6572206d617920706572666f726d207468697320616374696f6e536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77412066756c6c20706572696f6420686173206e6f74207061737365642073696e636520746865206c61737420636c6f73656420706572696f644163636f756e742068617320616c72656164792074726967676572656420756e7374616b6520636f6f6c646f776e5468697320616374696f6e2063616e6e6f7420626520706572666f726d6564207768696c652074686520636f6e7472616374206973207061757365644163636f756e7420646f65736e7420686176652074686174206d756368207374616b65645361666545524332303a204552433230206f7065726174696f6e20646964206e6f7420737563636565644e6f20616c6c6f77616e63652e20506c65617365206772616e74205374616b696e675468616c657320616c6c6f77616e6365a265627a7a72315820509426d7d92d58df60794db4111e27a693c8b35e88d9572fb3c834f770e1fca464736f6c634300051000320000000000000000000000004d03ef005e5f559fc9294a8e1cebba09284b1f820000000000000000000000008d3703d4ded77473e632def20002dadc86bf4aad00000000000000000000000003e173ad8d1581a4802d3b532ace27a62c5b81dc00000000000000000000000057ab1ec28d129707052df4df418d58a2d46d5f510000000000000000000000000000000000000000000000000000000000093a800000000000000000000000000000000000000000000000000000000000093a80
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106102a05760003560e01c8063647846a511610167578063a694fc3a116100ce578063cf44932711610087578063cf44932714610643578063d66e067714610660578063dd206d7c14610668578063e11cd0551461068e578063f38d00f014610696578063f3a467e31461069e576102a0565b8063a694fc3a146105ab578063ad2ce46b146105c8578063b88a802f146105e7578063ba47a5d9146105ef578063c10c3546146105f7578063cb8d751a1461061d576102a0565b80637c17f6fc116101205780637c17f6fc146105465780638a239de81461054e5780638da5cb5b1461057457806391b4ded91461057c57806392929a091461058457806393eb2e66146105a3576102a0565b8063647846a5146104c557806364c83591146104cd5780636ec0cd07146104f357806372f702f31461051057806379ba5097146105185780637a68567714610520576102a0565b806334dfb2681161020b57806353a47bb7116101c457806353a47bb71461049557806353cf41151461049d578063567e98f9146104a55780635c975abb146104ad57806362139e0e146104b55780636282719e146104bd576102a0565b806334dfb268146104145780633f5a0bdd146104315780633faae534146104575780634ab179691461045f5780634c4e75df14610467578063507a73281461048d576102a0565b8063200743541161025d57806320074354146103785780632866ed21146103805780632d2878861461039c5780632def6620146103c25780632f324158146103ca578063331e03a8146103ee576102a0565b8063080e2b47146102a55780631314f759146102dd57806315da5064146103035780631627540c1461030b578063167653911461033357806316c38b3c14610359575b600080fd5b6102cb600480360360208110156102bb57600080fd5b50356001600160a01b03166106bb565b60408051918252519081900360200190f35b6102cb600480360360208110156102f357600080fd5b50356001600160a01b03166106cd565b6102cb6106e0565b6103316004803603602081101561032157600080fd5b50356001600160a01b03166106e6565b005b6102cb6004803603602081101561034957600080fd5b50356001600160a01b0316610742565b6103316004803603602081101561036f57600080fd5b5035151561075d565b6102cb6107d7565b6103886107dd565b604080519115158252519081900360200190f35b6102cb600480360360208110156103b257600080fd5b50356001600160a01b03166107e6565b6103316107f8565b6103d261093b565b604080516001600160a01b039092168252519081900360200190f35b6102cb6004803603602081101561040457600080fd5b50356001600160a01b031661094f565b6103316004803603602081101561042a57600080fd5b5035610961565b6103316004803603602081101561044757600080fd5b50356001600160a01b0316610cc6565b6102cb610e06565b610331610e82565b6102cb6004803603602081101561047d57600080fd5b50356001600160a01b0316611116565b610331611131565b6103d2611543565b610388611552565b6102cb61155b565b610388611561565b6102cb61156a565b610331611570565b6103d2611627565b6102cb600480360360208110156104e357600080fd5b50356001600160a01b0316611636565b6103316004803603602081101561050957600080fd5b5035611648565b6103d261168b565b61033161169a565b6102cb6004803603602081101561053657600080fd5b50356001600160a01b0316611756565b6102cb611761565b6102cb6004803603602081101561056457600080fd5b50356001600160a01b0316611767565b6103d2611782565b6102cb611791565b6103316004803603602081101561059a57600080fd5b50351515611797565b6102cb6117e6565b610331600480360360208110156105c157600080fd5b50356117ec565b610331600480360360208110156105de57600080fd5b50351515611c94565b610331611ce3565b6102cb611d8f565b6103316004803603602081101561060d57600080fd5b50356001600160a01b0316611d95565b6103886004803603602081101561063357600080fd5b50356001600160a01b0316611f22565b6103316004803603602081101561065957600080fd5b5035611f37565b6102cb611f7a565b6102cb6004803603602081101561067e57600080fd5b50356001600160a01b0316611fc5565b6102cb611fe0565b6102cb611fe6565b610331600480360360208110156106b457600080fd5b5035611fec565b60126020526000908152604090205481565b60006106d88261202f565b90505b919050565b600f5481565b6106ee612171565b600180546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f906a1c6bd7e3091ea86693dd029a831c19049ce77f1dce2ce0bab1cacbabce229181900360200190a150565b6001600160a01b03166000908152601c602052604090205490565b610765612171565b60045460ff161515811515141561077b576107d4565b6004805460ff1916821515179081905560ff161561079857426003555b6004546040805160ff90921615158252517f8fb6c181ee25a520cf3dd6565006ef91229fcfe5a989566c2a3b8c115570cec59181900360200190a15b50565b60085481565b60105460ff1681565b601b6020526000908152604090205481565b336000908152601a602052604090205460ff16151560011461084b5760405162461bcd60e51b815260040180806020018281038252602a815260200180612a2c602a913960400191505060405180910390fd5b600a5461085f90429063ffffffff6121bc16565b33600090815260196020526040902054106108ab5760405162461bcd60e51b8152600401808060200182810382526029815260200180612a036029913960400191505060405180910390fd5b336000818152601a60209081526040808320805460ff19169055601b90915290205460055490916108ec916001600160a01b0316908363ffffffff61221e16565b336000818152601b60209081526040808320929092558151928352820183905280517f0f5bb82176feb1b5e747e28471aa92156a04d9f3ab9f45f28e2d704232b93f759281900390910190a150565b60045461010090046001600160a01b031681565b60196020526000908152604090205481565b600081116109a9576040805162461bcd60e51b815260206004820152601060248201526f043616e6e6f7420756e7374616b6520360841b604482015290519081900360640190fd5b336000908152601c60205260409020548111156109f75760405162461bcd60e51b8152600401808060200182810382526024815260200180612b896024913960400191505060405180910390fd5b336000908152601a602052604090205460ff1615610a465760405162461bcd60e51b815260040180806020018281038252602e815260200180612b1f602e913960400191505060405180910390fd5b600754336000908152601d6020526040902054108015610a68575060105460ff165b15610a7557610a75611ce3565b336000908152601960209081526040808320429055601a9091529020805460ff19166001179055601354610aaf908263ffffffff6121bc16565b601355336000908152601b60209081526040808320849055601c909152902054610adf908263ffffffff6121bc16565b336000908152601c60205260409020819055610c555760048054604080516334c78ae560e11b81523393810193909352516000926101009092046001600160a01b03169163698f15ca916024808301926020929190829003018186803b158015610b4857600080fd5b505afa158015610b5c573d6000803e3d6000fd5b505050506040513d6020811015610b7257600080fd5b50511115610c555760048054604080516334c78ae560e11b81523393810193909352516101009091046001600160a01b031691635817d04291839163698f15ca916024808301926020929190829003018186803b158015610bd257600080fd5b505afa158015610be6573d6000803e3d6000fd5b505050506040513d6020811015610bfc57600080fd5b5051604080516001600160e01b031960e085901b168152600481019290925251602480830192600092919082900301818387803b158015610c3c57600080fd5b505af1158015610c50573d6000803e3d6000fd5b505050505b600a54336000818152601960205260409020547f30797de805f090008d8b19fa0c6f92d0f164789f64d6f7a1b097fbf0b1abac6b92610c9a919063ffffffff61227516565b604080516001600160a01b0390931683526020830191909152818101849052519081900360600190a150565b610cce612171565b600554604080516370a0823160e01b81523060048201529051610d649284926001600160a01b03909116916370a0823191602480820192602092909190829003018186803b158015610d1f57600080fd5b505afa158015610d33573d6000803e3d6000fd5b505050506040513d6020811015610d4957600080fd5b50516005546001600160a01b0316919063ffffffff61221e16565b600654604080516370a0823160e01b81523060048201529051610dfa9284926001600160a01b03909116916370a0823191602480820192602092909190829003018186803b158015610db557600080fd5b505afa158015610dc9573d6000803e3d6000fd5b505050506040513d6020811015610ddf57600080fd5b50516006546001600160a01b0316919063ffffffff61221e16565b806001600160a01b0316ff5b600554604080516370a0823160e01b815230600482015290516000926001600160a01b0316916370a08231916024808301926020929190829003018186803b158015610e5157600080fd5b505afa158015610e65573d6000803e3d6000fd5b505050506040513d6020811015610e7b57600080fd5b5051905090565b336000908152601a602052604090205460ff161515600114610eeb576040805162461bcd60e51b815260206004820152601860248201527f4163636f756e74206973206e6f7420756e7374616b696e670000000000000000604482015290519081900360640190fd5b336000908152601c602052604090205461105f5760048054604080516334c78ae560e11b81523393810193909352516000926101009092046001600160a01b03169163698f15ca916024808301926020929190829003018186803b158015610f5257600080fd5b505afa158015610f66573d6000803e3d6000fd5b505050506040513d6020811015610f7c57600080fd5b5051111561105f5760048054604080516334c78ae560e11b81523393810193909352516101009091046001600160a01b03169163ad6d15de91839163698f15ca916024808301926020929190829003018186803b158015610fdc57600080fd5b505afa158015610ff0573d6000803e3d6000fd5b505050506040513d602081101561100657600080fd5b5051604080516001600160e01b031960e085901b168152600481019290925251602480830192600092919082900301818387803b15801561104657600080fd5b505af115801561105a573d6000803e3d6000fd5b505050505b336000908152601a60209081526040808320805460ff19169055601b9091529020546013546110939163ffffffff61227516565b601355336000908152601b6020908152604080832054601c909252909120546110c19163ffffffff61227516565b336000818152601c6020908152604080832094909455601b815283822091909155825191825291517f725ee3b9a70aadcb1e002c94935880d7f515620783a5144c90e39201dc6f92da929181900390910190a1565b6001600160a01b03166000908152601d602052604090205490565b600280546001019081905560045460ff161561117e5760405162461bcd60e51b815260040180806020018281038252603c815260200180612b4d603c913960400191505060405180910390fd5b6000600b54116111d5576040805162461bcd60e51b815260206004820152601e60248201527f5374616b696e6720706572696f6420686173206e6f7420737461727465640000604482015290519081900360640190fd5b6009546008546111ea9163ffffffff61227516565b4210156112285760405162461bcd60e51b8152600401808060200182810382526039815260200180612ae66039913960400191505060405180910390fd5b600460019054906101000a90046001600160a01b03166001600160a01b031663acfabbe46040518163ffffffff1660e01b8152600401602060405180830381600087803b15801561127857600080fd5b505af115801561128c573d6000803e3d6000fd5b505050506040513d60208110156112a257600080fd5b5050426008556004805460408051635d13850560e01b815290516101009092046001600160a01b031692635d138505928282019260209290829003018186803b1580156112ee57600080fd5b505afa158015611302573d6000803e3d6000fd5b505050506040513d602081101561131857600080fd5b505160075560048054604080516347d3681760e11b81529051611412936101009093046001600160a01b031692638fa6d02e92808201926020929091829003018186803b15801561136857600080fd5b505afa15801561137c573d6000803e3d6000fd5b505050506040513d602081101561139257600080fd5b5051600480546040805163b9d1c70b60e01b815290516101009092046001600160a01b03169263b9d1c70b928282019260209290829003018186803b1580156113da57600080fd5b505afa1580156113ee573d6000803e3d6000fd5b505050506040513d602081101561140457600080fd5b50519063ffffffff6121bc16565b601455600f54600c81905560165461142f9163ffffffff61227516565b601655600654604080516370a0823160e01b815230600482015290516001600160a01b03909216916370a0823191602480820192602092909190829003018186803b15801561147d57600080fd5b505afa158015611491573d6000803e3d6000fd5b505050506040513d60208110156114a757600080fd5b5051600d5560075460085460408051928352602083019190915280517f80827f48a8070d07af7887688320aadf44499e3a2751fc41cc965870cf0627d79281900390910190a160025481146107d4576040805162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b6001546001600160a01b031681565b600e5460ff1681565b60135490565b60045460ff1681565b60095481565b611578612171565b600b54156115cd576040805162461bcd60e51b815260206004820152601b60248201527f5374616b696e672068617320616c726561647920737461727465640000000000604482015290519081900360640190fd5b42600b819055600060078190556008919091556016819055601781905560188190556013819055601481905560158190556040517f7c01398e484f9a82feaa276906d5d1f84867a0ff5a5bd9a485d4357f58d401839190a1565b6006546001600160a01b031681565b60116020526000908152604090205481565b611650612171565b600f8190556040805182815290517f14287d4a2613a9be7577831054c6f7b3d27c4912fb53929a1d626342def8aada9181900360200190a150565b6005546001600160a01b031681565b6001546001600160a01b031633146116e35760405162461bcd60e51b81526004018080602001828103825260358152602001806129ce6035913960400191505060405180910390fd5b600054600154604080516001600160a01b03938416815292909116602083015280517fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c9281900390910190a160018054600080546001600160a01b03199081166001600160a01b03841617909155169055565b60006106d8826122d6565b60075481565b6001600160a01b031660009081526011602052604090205490565b6000546001600160a01b031681565b60035481565b61179f612171565b6010805482151560ff19909116811790915560408051918252517f1edd4dc7f91a5992aba0f39c0428bcf4df13d001eebc26eb188307d057f14a079181900360200190a150565b600a5481565b600280546001019081905560045460ff16156118395760405162461bcd60e51b815260040180806020018281038252603c815260200180612b4d603c913960400191505060405180910390fd5b6000600b5411611890576040805162461bcd60e51b815260206004820152601e60248201527f5374616b696e6720706572696f6420686173206e6f7420737461727465640000604482015290519081900360640190fd5b600082116118d6576040805162461bcd60e51b815260206004820152600e60248201526d043616e6e6f74207374616b6520360941b604482015290519081900360640190fd5b60055460408051636eb1769f60e11b8152336004820152306024820152905184926001600160a01b03169163dd62ed3e916044808301926020929190829003018186803b15801561192657600080fd5b505afa15801561193a573d6000803e3d6000fd5b505050506040513d602081101561195057600080fd5b5051101561198f5760405162461bcd60e51b8152600401808060200182810382526032815260200180612bd76032913960400191505060405180910390fd5b336000908152601a602052604090205460ff16156119de5760405162461bcd60e51b8152600401808060200182810382526040815260200180612a566040913960400191505060405180910390fd5b600754336000908152601d6020526040902054108015611a00575060105460ff165b8015611a1a5750336000908152601c602052604090205415155b15611a2857611a28336123af565b336000908152601c6020526040902054611b9c5760048054604080516334c78ae560e11b81523393810193909352516000926101009092046001600160a01b03169163698f15ca916024808301926020929190829003018186803b158015611a8f57600080fd5b505afa158015611aa3573d6000803e3d6000fd5b505050506040513d6020811015611ab957600080fd5b50511115611b9c5760048054604080516334c78ae560e11b81523393810193909352516101009091046001600160a01b03169163ad6d15de91839163698f15ca916024808301926020929190829003018186803b158015611b1957600080fd5b505afa158015611b2d573d6000803e3d6000fd5b505050506040513d6020811015611b4357600080fd5b5051604080516001600160e01b031960e085901b168152600481019290925251602480830192600092919082900301818387803b158015611b8357600080fd5b505af1158015611b97573d6000803e3d6000fd5b505050505b601354611baf908363ffffffff61227516565b601355336000908152601c6020526040902054611bd2908363ffffffff61227516565b336000818152601c6020526040902091909155600554611bff916001600160a01b039091169030856126ec565b604080513381526020810184905281517f9e71bc8eea02a63969f509818f2dafb9254532904319f9dbda79b67bd34a5f3d929181900390910190a16002548114611c90576040805162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b5050565b611c9c612171565b600e805482151560ff19909116811790915560408051918252517f85de4a4b7db92534188eb7833a0fb258893c3829293a0ce3de521b189fb4619d9181900360200190a150565b600280546001019081905560045460ff1615611d305760405162461bcd60e51b815260040180806020018281038252603c815260200180612b4d603c913960400191505060405180910390fd5b611d39336123af565b60025481146107d4576040805162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b600d5481565b611d9d612171565b60045461010090046001600160a01b031615611e4557600554600480546040805163095ea7b360e01b81526101009092046001600160a01b03908116938301939093526000602483018190529051929093169263095ea7b3926044808401936020939083900390910190829087803b158015611e1857600080fd5b505af1158015611e2c573d6000803e3d6000fd5b505050506040513d6020811015611e4257600080fd5b50505b60048054610100600160a81b0319166101006001600160a01b038481169182029290921783556005546040805163095ea7b360e01b8152948501929092526000196024850152905191169163095ea7b39160448083019260209291908290030181600087803b158015611eb757600080fd5b505af1158015611ecb573d6000803e3d6000fd5b505050506040513d6020811015611ee157600080fd5b5050604080516001600160a01b038316815290517feb1a4b1e230d212e1644ea31e3890084e2fa17ddee990e46a46e198e1728c4a09181900360200190a150565b601a6020526000908152604090205460ff1681565b611f3f612171565b60098190556040805182815290517feb564dffd3daf74504b745a322550f31ab110ec5c012cc525d0e14f9b38436d19181900360200190a150565b600654604080516370a0823160e01b815230600482015290516000926001600160a01b0316916370a08231916024808301926020929190829003018186803b158015610e5157600080fd5b6001600160a01b031660009081526012602052604090205490565b600c5481565b600b5481565b611ff4612171565b600a8190556040805182815290517f119e399359baa8bc27eabe26ea23641a285b6a0cb3398a69a34f6f77efa4a29c9181900360200190a150565b6001600160a01b0381166000908152601c6020526040812054158061206d57506007546001600160a01b0383166000908152601d6020526040902054145b1561207a575060006106db565b6106d861209460145460135461227590919063ffffffff16565b612165600d54612159600460019054906101000a90046001600160a01b03166001600160a01b03166317640e07886040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561210857600080fd5b505afa15801561211c573d6000803e3d6000fd5b505050506040513d602081101561213257600080fd5b50516001600160a01b0388166000908152601c60205260409020549063ffffffff61227516565b9063ffffffff61274c16565b9063ffffffff6127a516565b6000546001600160a01b031633146121ba5760405162461bcd60e51b815260040180806020018281038252602f815260200180612a96602f913960400191505060405180910390fd5b565b600082821115612213576040805162461bcd60e51b815260206004820152601e60248201527f536166654d6174683a207375627472616374696f6e206f766572666c6f770000604482015290519081900360640190fd5b508082035b92915050565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b17905261227090849061280f565b505050565b6000828201838110156122cf576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b9392505050565b6001600160a01b0381166000908152601c6020526040812054158061231457506007546001600160a01b0383166000908152601d6020526040902054145b15612321575060006106db565b6106d861233b60145460135461227590919063ffffffff16565b612165600c54612159600460019054906101000a90046001600160a01b03166001600160a01b03166317640e07886040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561210857600080fd5b60045460ff16156123f15760405162461bcd60e51b815260040180806020018281038252603c815260200180612b4d603c913960400191505060405180910390fd5b60105460ff16612448576040805162461bcd60e51b815260206004820152601860248201527f436c61696d696e67206973206e6f7420656e61626c65642e0000000000000000604482015290519081900360640190fd5b6000600b541161249f576040805162461bcd60e51b815260206004820152601e60248201527f5374616b696e6720706572696f6420686173206e6f7420737461727465640000604482015290519081900360640190fd5b600e5460ff16156125795760006124b58261202f565b90508015612577576006546124da906001600160a01b0316838363ffffffff61221e16565b6001600160a01b038216600090815260126020526040902054612503908263ffffffff61227516565b6001600160a01b03831660009081526012602052604090205560185461252f908263ffffffff61227516565b601855604080516001600160a01b03841681526020810183905281517f5b16e1043a283423361eb77682c99aff55948b34296846800a1a7dc9547a89fc929181900390910190a15b505b6000612584826122d6565b905080156126cc57600460019054906101000a90046001600160a01b03166001600160a01b031663b01ca88f83836040518363ffffffff1660e01b815260040180836001600160a01b03166001600160a01b0316815260200182815260200192505050600060405180830381600087803b15801561260157600080fd5b505af1158015612615573d6000803e3d6000fd5b5050506001600160a01b03831660009081526011602052604090205461264291508263ffffffff61227516565b6001600160a01b03831660009081526011602052604090205560175461266e908263ffffffff61227516565b601755601654612684908263ffffffff6121bc16565b601655604080516001600160a01b03841681526020810183905281517ffc30cddea38e2bf4d6ea7d3f9ed3b6ad7f176419f4963bd81318067a4aee73fe929181900390910190a15b506007546001600160a01b039091166000908152601d6020526040902055565b604080516001600160a01b0385811660248301528416604482015260648082018490528251808303909101815260849091019091526020810180516001600160e01b03166323b872dd60e01b17905261274690859061280f565b50505050565b60008261275b57506000612218565b8282028284828161276857fe5b04146122cf5760405162461bcd60e51b8152600401808060200182810382526021815260200180612ac56021913960400191505060405180910390fd5b60008082116127fb576040805162461bcd60e51b815260206004820152601a60248201527f536166654d6174683a206469766973696f6e206279207a65726f000000000000604482015290519081900360640190fd5b600082848161280657fe5b04949350505050565b612821826001600160a01b03166129c7565b612872576040805162461bcd60e51b815260206004820152601f60248201527f5361666545524332303a2063616c6c20746f206e6f6e2d636f6e747261637400604482015290519081900360640190fd5b60006060836001600160a01b0316836040518082805190602001908083835b602083106128b05780518252601f199092019160209182019101612891565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d8060008114612912576040519150601f19603f3d011682016040523d82523d6000602084013e612917565b606091505b50915091508161296e576040805162461bcd60e51b815260206004820181905260248201527f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564604482015290519081900360640190fd5b8051156127465780806020019051602081101561298a57600080fd5b50516127465760405162461bcd60e51b815260040180806020018281038252602a815260200180612bad602a913960400191505060405180910390fd5b3b15159056fe596f75206d757374206265206e6f6d696e61746564206265666f726520796f752063616e20616363657074206f776e65727368697043616e6e6f7420756e7374616b65207965742c20636f6f6c646f776e206e6f7420657870697265642e4163636f756e7420686173206e6f742074726967676572656420756e7374616b6520636f6f6c646f776e43616e6e6f74207374616b652c20746865207374616b6572206973207061757365642066726f6d207374616b696e672064756520746f20756e7374616b696e674f6e6c792074686520636f6e7472616374206f776e6572206d617920706572666f726d207468697320616374696f6e536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77412066756c6c20706572696f6420686173206e6f74207061737365642073696e636520746865206c61737420636c6f73656420706572696f644163636f756e742068617320616c72656164792074726967676572656420756e7374616b6520636f6f6c646f776e5468697320616374696f6e2063616e6e6f7420626520706572666f726d6564207768696c652074686520636f6e7472616374206973207061757365644163636f756e7420646f65736e7420686176652074686174206d756368207374616b65645361666545524332303a204552433230206f7065726174696f6e20646964206e6f7420737563636565644e6f20616c6c6f77616e63652e20506c65617365206772616e74205374616b696e675468616c657320616c6c6f77616e6365a265627a7a72315820509426d7d92d58df60794db4111e27a693c8b35e88d9572fb3c834f770e1fca464736f6c63430005100032
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
0000000000000000000000004d03ef005e5f559fc9294a8e1cebba09284b1f820000000000000000000000008d3703d4ded77473e632def20002dadc86bf4aad00000000000000000000000003e173ad8d1581a4802d3b532ace27a62c5b81dc00000000000000000000000057ab1ec28d129707052df4df418d58a2d46d5f510000000000000000000000000000000000000000000000000000000000093a800000000000000000000000000000000000000000000000000000000000093a80
-----Decoded View---------------
Arg [0] : _owner (address): 0x4D03eF005e5f559fc9294a8E1CeBbA09284B1F82
Arg [1] : _iEscrowThales (address): 0x8d3703d4dED77473E632dEf20002DAdC86bf4AAD
Arg [2] : _stakingToken (address): 0x03E173Ad8d1581A4802d3B532AcE27a62c5B81dc
Arg [3] : _feeToken (address): 0x57Ab1ec28D129707052df4dF418D58a2D46d5f51
Arg [4] : _durationPeriod (uint256): 604800
Arg [5] : _unstakeDurationPeriod (uint256): 604800
-----Encoded View---------------
6 Constructor Arguments found :
Arg [0] : 0000000000000000000000004d03ef005e5f559fc9294a8e1cebba09284b1f82
Arg [1] : 0000000000000000000000008d3703d4ded77473e632def20002dadc86bf4aad
Arg [2] : 00000000000000000000000003e173ad8d1581a4802d3b532ace27a62c5b81dc
Arg [3] : 00000000000000000000000057ab1ec28d129707052df4df418d58a2d46d5f51
Arg [4] : 0000000000000000000000000000000000000000000000000000000000093a80
Arg [5] : 0000000000000000000000000000000000000000000000000000000000093a80
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ Download: CSV Export ]
[ 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.