More Info
Private Name Tags
ContractCreator
Latest 7 from a total of 7 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Transfer Ownersh... | 51076494 | 433 days ago | IN | 0 POL | 0.00515421 | ||||
Set Cooldown Sec... | 51039432 | 434 days ago | IN | 0 POL | 0.00273454 | ||||
Set Cooldown Sec... | 51012506 | 435 days ago | IN | 0 POL | 0.13828688 | ||||
Change Apr | 50614408 | 445 days ago | IN | 0 POL | 0.00834331 | ||||
Allow Token Tran... | 50614403 | 445 days ago | IN | 0 POL | 0.00437389 | ||||
Set Contracts | 50614161 | 445 days ago | IN | 0 POL | 0.00134625 | ||||
Set Contracts | 50613604 | 445 days ago | IN | 0 POL | 0.00266416 |
Loading...
Loading
Contract Name:
RadarStake
Compiler Version
v0.8.17+commit.8df45f5f
Optimization Enabled:
Yes with 1000 runs
Other Settings:
london EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT LICENSE pragma solidity ^0.8.17; // Author: @mizi import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/security/ReentrancyGuard.sol"; import "./interfaces/iRadarStake.sol"; import "./interfaces/iRadarToken.sol"; import "./interfaces/iRadarStakingLogic.sol"; contract RadarStake is iRadarStake, Ownable, ReentrancyGuard { constructor(address radarTokenContractAddr) { require(address(radarTokenContractAddr) != address(0), "RadarStake: Token contract not set"); radarTokenContract = iRadarToken(radarTokenContractAddr); } /** EVENTS */ event AddedToStake(address indexed owner, uint256 amount); event RemovedFromStake(address indexed owner, uint256 amount); event CooldownTriggered(address indexed owner, uint256 cooldownSeconds); /** PUBLIC VARS */ // interface of our ERC20 RADAR token iRadarToken public radarTokenContract; // interface of the staking logic smart contract (stateless) iRadarStakingLogic public radarStakingLogicContract; // keeps track of all staked tokens at all times uint256 public totalStaked; // duration of the cooldown before a user can unstake uint256 public cooldownSeconds = 30 days; // e.g. 86_400 = 1 day // all APRs over time with their respective start and end times Apr[] public allAprs; /** PRIVATE VARS */ // all data needed to calculate staking rewards and for keeping tack of users staked funds mapping(address => Stake) private _stakedTokens; /** MODIFIERS */ modifier onlyStakingLogicContract() { require(_msgSender() == address(radarStakingLogicContract), "RadarStake: Only the StakingLogic contract can call this"); _; } /** PUBLIC */ // allow fetching all APRs with one call function getAllAprs() external view returns(Apr[] memory) { return allAprs; } // get one user's staking information function getStake(address addr) external view returns (Stake memory) { return _stakedTokens[addr]; } /** ONLY STAKING LOGIC CONTRACT */ // add to your stake & reset counters. // allow amount == 0, so a user can reset timers without having to add tokens to its stake for doing so function addToStake(uint256 amount, address addr) external onlyStakingLogicContract { require(addr != address(0), "RadarStake: Cannot use the null address"); require(allAprs.length > 0, "RadarStake: No APR set"); // get current stake Stake memory myStake = _stakedTokens[addr]; // save new Stake _stakedTokens[addr] = Stake({ totalStaked: myStake.totalStaked + amount, lastStakedTimestamp: block.timestamp, cooldownSeconds: 0, // reset cooldown cooldownTriggeredAtTimestamp: 0 // reset cooldown }); // increase the counter totalStaked += amount; emit AddedToStake(addr, amount); } // start the cooldown period before user can unstake when calling unstake() later function triggerUnstake(address addr) external onlyStakingLogicContract { require(addr != address(0), "RadarStake: Cannot use the null address"); require(cooldownSeconds > 0, "RadarStake: Cooldown seconds must be bigger than 0"); Stake memory myStake = _stakedTokens[addr]; require(myStake.totalStaked >= 0, "RadarStake: You have no stake yet"); require(myStake.cooldownTriggeredAtTimestamp == 0, "RadarStake: Cooldown is already in progress - cannot trigger it again"); // set the amount of seconds that have to pass before user can unstake myStake.cooldownSeconds = cooldownSeconds; // store the current time to calculate if the cooldown has passed myStake.cooldownTriggeredAtTimestamp = block.timestamp; // store the updated Stake to permantent storage _stakedTokens[addr] = myStake; emit CooldownTriggered(addr, cooldownSeconds); } // remove from your stake function removeFromStake(uint256 amount, address addr) external onlyStakingLogicContract { require(amount > 0, "RadarStake: Amount cannot be lower than 0"); require(addr != address(0), "RadarStake: Cannot use the null address"); Stake memory myStake = _stakedTokens[addr]; require(myStake.cooldownSeconds >= 0, "RadarStake: CooldownSeconds cannot be lower than 0"); require(myStake.totalStaked >= amount, "RadarStake: You cannot unstake more than you have staked"); require(totalStaked >= amount, "RadarStake: Cannot unstake more than is staked in total"); if (myStake.totalStaked == amount) { delete(_stakedTokens[addr]); // clean memory when the whole stake is being taken out } else { // save new Stake _stakedTokens[addr] = Stake({ totalStaked: myStake.totalStaked - amount, // deduct the amount from the current stake lastStakedTimestamp: block.timestamp, // reset stake timestamp because we always harvest rewards before unstaking cooldownSeconds: 0, // reset cooldown cooldownTriggeredAtTimestamp: 0 // reset cooldown }); } totalStaked -= amount; // subtract from total staked amount emit RemovedFromStake(addr, amount); } /** ONLY OWNER */ // called when we deploy a new version of our staking rewards logic (e.g. when launching new features) function setContracts(address radarStakingLogicContractAddr) external onlyOwner { require(radarStakingLogicContractAddr != address(0), "RadarStake: Cannot use the null address"); radarStakingLogicContract = iRadarStakingLogic(radarStakingLogicContractAddr); } // e.g apr = 300 => 3% APR function changeApr(uint256 apr) external onlyOwner { require(apr > 0, "RadarStake: APR cannot be lower than 0"); // set endTime for previous APR to make rewards calculations easier later on if (allAprs.length > 0) { Apr storage previousApr = allAprs[allAprs.length - 1]; previousApr.endTime = block.timestamp; } // add new APR to the array so rewards can start accruing for this new APR from now on allAprs.push(Apr({ startTime: block.timestamp, endTime: 0, apr: apr })); } // this is needed so that the radarStakingLogicContract is allowed to call transferFrom() in the name of this contract so that users can get back their tokens when they RadarStakingLogic.unstake function allowTokenTransfers(uint256 amount) external onlyOwner { require(amount > 0, "RadarStake: Amount has to be greater than 0"); radarTokenContract.approve(address(radarStakingLogicContract), amount); } // allow to change the cooldown period function setCooldownSeconds(uint256 number) external onlyOwner { require(number > 0, "RadarStake: Amount must be above 0"); cooldownSeconds = number; } // if someone sends RADAR to this contract by accident we want to be able to send it back to them function withdrawRewardTokens(address to, uint256 amount) external onlyOwner { require(to != address(0), "RadarStake: Cannot use the null address"); require(amount > 0, "RadarStake: Amount has to be greater than 0"); uint256 radarBalance = radarTokenContract.balanceOf(address(this)); require(radarBalance >= amount, "RadarStake: Cannot withdraw more than is available"); require(radarBalance - amount >= totalStaked, "RadarStake: Cannot withdraw more than is staked"); // approve this contract to move the amount of tokens radarTokenContract.approve(address(this), amount); // transfer those tokens to the given address radarTokenContract.transferFrom(address(this), to, amount); } // if someone sends ETH to this contract by accident we want to be able to send it back to them function withdraw() external onlyOwner { uint256 totalAmount = address(this).balance; bool sent; (sent, ) = owner().call{value: totalAmount}(""); require(sent, "RadarStake: Failed to send funds"); } }
// SPDX-License-Identifier: MIT LICENSE pragma solidity ^0.8.17; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; interface iRadarToken is IERC20 { }
// SPDX-License-Identifier: MIT LICENSE pragma solidity ^0.8.17; interface iRadarStakingLogic { }
// SPDX-License-Identifier: MIT LICENSE pragma solidity ^0.8.17; interface iRadarStake { // store lock meta data struct Stake { uint256 totalStaked; uint256 lastStakedTimestamp; uint256 cooldownSeconds; uint256 cooldownTriggeredAtTimestamp; } struct Apr { uint256 startTime; uint256 endTime; uint256 apr; // e.g. 300 => 3% } function getAllAprs() external view returns(Apr[] memory); function getStake(address addr) external view returns (Stake memory); function addToStake(uint256 amount, address addr) external; // onlyStakingLogicContract function triggerUnstake(address addr) external; // onlyStakingLogicContract function removeFromStake(uint256 amount, address addr) external; // onlyStakingLogicContract }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `to`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address to, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an {Approval} event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `from` to `to` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 amount ) external returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (security/ReentrancyGuard.sol) pragma solidity ^0.8.0; /** * @dev Contract module that helps prevent reentrant calls to a function. * * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier * available, which can be applied to functions to make sure there are no nested * (reentrant) calls to them. * * Note that because there is a single `nonReentrant` guard, functions marked as * `nonReentrant` may not call one another. This can be worked around by making * those functions `private`, and then adding `external` `nonReentrant` entry * points to them. * * TIP: If you would like to learn more about reentrancy and alternative ways * to protect against it, check out our blog post * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul]. */ abstract contract ReentrancyGuard { // Booleans are more expensive than uint256 or any type that takes up a full // word because each write operation emits an extra SLOAD to first read the // slot's contents, replace the bits taken up by the boolean, and then write // back. This is the compiler's defense against contract upgrades and // pointer aliasing, and it cannot be disabled. // The values being non-zero value makes deployment a bit more expensive, // but in exchange the refund on every call to nonReentrant will be lower in // amount. Since refunds are capped to a percentage of the total // transaction's gas, it is best to keep them low in cases like this one, to // increase the likelihood of the full refund coming into effect. uint256 private constant _NOT_ENTERED = 1; uint256 private constant _ENTERED = 2; uint256 private _status; constructor() { _status = _NOT_ENTERED; } /** * @dev Prevents a contract from calling itself, directly or indirectly. * Calling a `nonReentrant` function from another `nonReentrant` * function is not supported. It is possible to prevent this from happening * by making the `nonReentrant` function external, and making it call a * `private` function that does the actual work. */ modifier nonReentrant() { // On the first call to nonReentrant, _notEntered will be true require(_status != _ENTERED, "ReentrancyGuard: reentrant call"); // Any calls to nonReentrant after this point will fail _status = _ENTERED; _; // By storing the original value once again, a refund is triggered (see // https://eips.ethereum.org/EIPS/eip-2200) _status = _NOT_ENTERED; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol) pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _transferOwnership(_msgSender()); } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { _checkOwner(); _; } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { require(owner() == _msgSender(), "Ownable: caller is not the owner"); } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
{ "remappings": [], "optimizer": { "enabled": true, "runs": 1000 }, "evmVersion": "london", "libraries": {}, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address","name":"radarTokenContractAddr","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"AddedToStake","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":false,"internalType":"uint256","name":"cooldownSeconds","type":"uint256"}],"name":"CooldownTriggered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"RemovedFromStake","type":"event"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"address","name":"addr","type":"address"}],"name":"addToStake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"allAprs","outputs":[{"internalType":"uint256","name":"startTime","type":"uint256"},{"internalType":"uint256","name":"endTime","type":"uint256"},{"internalType":"uint256","name":"apr","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"allowTokenTransfers","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"apr","type":"uint256"}],"name":"changeApr","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"cooldownSeconds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAllAprs","outputs":[{"components":[{"internalType":"uint256","name":"startTime","type":"uint256"},{"internalType":"uint256","name":"endTime","type":"uint256"},{"internalType":"uint256","name":"apr","type":"uint256"}],"internalType":"struct iRadarStake.Apr[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"}],"name":"getStake","outputs":[{"components":[{"internalType":"uint256","name":"totalStaked","type":"uint256"},{"internalType":"uint256","name":"lastStakedTimestamp","type":"uint256"},{"internalType":"uint256","name":"cooldownSeconds","type":"uint256"},{"internalType":"uint256","name":"cooldownTriggeredAtTimestamp","type":"uint256"}],"internalType":"struct iRadarStake.Stake","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"radarStakingLogicContract","outputs":[{"internalType":"contract iRadarStakingLogic","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"radarTokenContract","outputs":[{"internalType":"contract iRadarToken","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"address","name":"addr","type":"address"}],"name":"removeFromStake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"radarStakingLogicContractAddr","type":"address"}],"name":"setContracts","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"number","type":"uint256"}],"name":"setCooldownSeconds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"totalStaked","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"}],"name":"triggerUnstake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdrawRewardTokens","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
608060405262278d0060055534801561001757600080fd5b506040516200190b3803806200190b8339810160408190526100389161011f565b610041336100cf565b600180556001600160a01b0381166100aa5760405162461bcd60e51b815260206004820152602260248201527f52616461725374616b653a20546f6b656e20636f6e7472616374206e6f742073604482015261195d60f21b606482015260840160405180910390fd5b600280546001600160a01b0319166001600160a01b039290921691909117905561014f565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60006020828403121561013157600080fd5b81516001600160a01b038116811461014857600080fd5b9392505050565b6117ac806200015f6000396000f3fe608060405234801561001057600080fd5b50600436106101515760003560e01c8063817b1cd2116100cd578063cfe2284a11610081578063e74727f711610066578063e74727f7146102bc578063f2fde38b146102ea578063f94090c8146102fd57600080fd5b8063cfe2284a14610296578063dba45877146102a957600080fd5b80638f3bbb9f116100b25780638f3bbb9f14610267578063922f21231461027a578063b8221bc41461028d57600080fd5b8063817b1cd21461023f5780638da5cb5b1461025657600080fd5b80634bb9a48211610124578063715018a611610109578063715018a6146101de5780637a766460146101e65780637b5b11571461022c57600080fd5b80634bb9a482146101b85780635a2e2f47146101cb57600080fd5b80630a7dcd75146101565780631f1d74031461018657806327c2ad4c1461019b5780633ccfd60b146101b0575b600080fd5b600354610169906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b61018e610310565b60405161017d91906115dd565b6101ae6101a9366004611652565b61038d565b005b6101ae610730565b6101ae6101c636600461167e565b6107f3565b6101ae6101d9366004611697565b6108d8565b6101ae610975565b6101f96101f4366004611697565b610989565b60405161017d91908151815260208083015190820152604080830151908201526060918201519181019190915260800190565b6101ae61023a36600461167e565b610a02565b61024860045481565b60405190815260200161017d565b6000546001600160a01b0316610169565b6101ae6102753660046116b9565b610a85565b6101ae61028836600461167e565b610de8565b61024860055481565b6101ae6102a4366004611652565b610f50565b600254610169906001600160a01b031681565b6102cf6102ca36600461167e565b611191565b6040805193845260208401929092529082015260600161017d565b6101ae6102f8366004611697565b6111c4565b6101ae61030b366004611697565b611254565b60606006805480602002602001604051908101604052809291908181526020016000905b828210156103845783829060005260206000209060030201604051806060016040529081600082015481526020016001820154815260200160028201548152505081526020019060010190610334565b50505050905090565b6003546001600160a01b0316336001600160a01b03161461041b5760405162461bcd60e51b815260206004820152603860248201527f52616461725374616b653a204f6e6c7920746865205374616b696e674c6f676960448201527f6320636f6e74726163742063616e2063616c6c2074686973000000000000000060648201526084015b60405180910390fd5b600082116104915760405162461bcd60e51b815260206004820152602960248201527f52616461725374616b653a20416d6f756e742063616e6e6f74206265206c6f7760448201527f6572207468616e203000000000000000000000000000000000000000000000006064820152608401610412565b6001600160a01b0381166104f75760405162461bcd60e51b815260206004820152602760248201527f52616461725374616b653a2043616e6e6f742075736520746865206e756c6c206044820152666164647265737360c81b6064820152608401610412565b6001600160a01b038116600090815260076020908152604091829020825160808101845281548082526001830154938201939093526002820154938101939093526003015460608301528311156105b65760405162461bcd60e51b815260206004820152603860248201527f52616461725374616b653a20596f752063616e6e6f7420756e7374616b65206d60448201527f6f7265207468616e20796f752068617665207374616b656400000000000000006064820152608401610412565b82600454101561062e5760405162461bcd60e51b815260206004820152603760248201527f52616461725374616b653a2043616e6e6f7420756e7374616b65206d6f72652060448201527f7468616e206973207374616b656420696e20746f74616c0000000000000000006064820152608401610412565b8051839003610669576001600160a01b03821660009081526007602052604081208181556001810182905560028101829055600301556106d5565b604051806080016040528084836000015161068491906116f9565b8152426020808301919091526000604080840182905260609384018290526001600160a01b038716825260078352908190208451815591840151600183015583015160028201559101516003909101555b82600460008282546106e791906116f9565b90915550506040518381526001600160a01b038316907fa952f29b693be45a22ce3b4af46afdf4576cbaa7ffb0d205f77d3b8bb53f1855906020015b60405180910390a2505050565b610738611526565b47600061074d6000546001600160a01b031690565b6001600160a01b03168260405160006040518083038185875af1925050503d8060008114610797576040519150601f19603f3d011682016040523d82523d6000602084013e61079c565b606091505b505080915050806107ef5760405162461bcd60e51b815260206004820181905260248201527f52616461725374616b653a204661696c656420746f2073656e642066756e64736044820152606401610412565b5050565b6107fb611526565b6000811161085f5760405162461bcd60e51b815260206004820152602b60248201527f52616461725374616b653a20416d6f756e742068617320746f2062652067726560448201526a061746572207468616e20360ac1b6064820152608401610412565b60025460035460405163095ea7b360e01b81526001600160a01b0391821660048201526024810184905291169063095ea7b3906044016020604051808303816000875af11580156108b4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107ef9190611712565b6108e0611526565b6001600160a01b0381166109465760405162461bcd60e51b815260206004820152602760248201527f52616461725374616b653a2043616e6e6f742075736520746865206e756c6c206044820152666164647265737360c81b6064820152608401610412565b6003805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b61097d611526565b6109876000611580565b565b6109b46040518060800160405280600081526020016000815260200160008152602001600081525090565b506001600160a01b0316600090815260076020908152604091829020825160808101845281548152600182015492810192909252600281015492820192909252600390910154606082015290565b610a0a611526565b60008111610a805760405162461bcd60e51b815260206004820152602260248201527f52616461725374616b653a20416d6f756e74206d7573742062652061626f766560448201527f20300000000000000000000000000000000000000000000000000000000000006064820152608401610412565b600555565b610a8d611526565b6001600160a01b038216610af35760405162461bcd60e51b815260206004820152602760248201527f52616461725374616b653a2043616e6e6f742075736520746865206e756c6c206044820152666164647265737360c81b6064820152608401610412565b60008111610b575760405162461bcd60e51b815260206004820152602b60248201527f52616461725374616b653a20416d6f756e742068617320746f2062652067726560448201526a061746572207468616e20360ac1b6064820152608401610412565b6002546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916001600160a01b0316906370a0823190602401602060405180830381865afa158015610bb9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bdd9190611734565b905081811015610c555760405162461bcd60e51b815260206004820152603260248201527f52616461725374616b653a2043616e6e6f74207769746864726177206d6f726560448201527f207468616e20697320617661696c61626c6500000000000000000000000000006064820152608401610412565b600454610c6283836116f9565b1015610cd65760405162461bcd60e51b815260206004820152602f60248201527f52616461725374616b653a2043616e6e6f74207769746864726177206d6f726560448201527f207468616e206973207374616b656400000000000000000000000000000000006064820152608401610412565b60025460405163095ea7b360e01b8152306004820152602481018490526001600160a01b039091169063095ea7b3906044016020604051808303816000875af1158015610d27573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d4b9190611712565b506002546040517f23b872dd0000000000000000000000000000000000000000000000000000000081523060048201526001600160a01b03858116602483015260448201859052909116906323b872dd906064016020604051808303816000875af1158015610dbe573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610de29190611712565b50505050565b610df0611526565b60008111610e665760405162461bcd60e51b815260206004820152602660248201527f52616461725374616b653a204150522063616e6e6f74206265206c6f7765722060448201527f7468616e203000000000000000000000000000000000000000000000000000006064820152608401610412565b60065415610ead576006805460009190610e82906001906116f9565b81548110610e9257610e9261174d565b90600052602060002090600302019050428160010181905550505b6040805160608101825242815260006020820181815292820193845260068054600181018255915290517ff652222313e28459528d920b65115c16c04f3efc82aaedc97be59f3f377c0d3f60039092029182015590517ff652222313e28459528d920b65115c16c04f3efc82aaedc97be59f3f377c0d4082015590517ff652222313e28459528d920b65115c16c04f3efc82aaedc97be59f3f377c0d4190910155565b6003546001600160a01b0316336001600160a01b031614610fd95760405162461bcd60e51b815260206004820152603860248201527f52616461725374616b653a204f6e6c7920746865205374616b696e674c6f676960448201527f6320636f6e74726163742063616e2063616c6c207468697300000000000000006064820152608401610412565b6001600160a01b03811661103f5760405162461bcd60e51b815260206004820152602760248201527f52616461725374616b653a2043616e6e6f742075736520746865206e756c6c206044820152666164647265737360c81b6064820152608401610412565b60065461108e5760405162461bcd60e51b815260206004820152601660248201527f52616461725374616b653a204e6f2041505220736574000000000000000000006044820152606401610412565b6001600160a01b0381166000908152600760209081526040918290208251608080820185528254825260018301549382019390935260028201548185015260039091015460608201528251918201909252815181906110ee908690611763565b8152426020808301919091526000604080840182905260609384018290526001600160a01b038716825260078352808220855181559285015160018401558401516002830155929091015160039091015560048054859290611151908490611763565b90915550506040518381526001600160a01b038316907f7bbf6a19a8b550713b9d9b9d38e56fd83d58218685b4d39e2ed965d777598df190602001610723565b600681815481106111a157600080fd5b600091825260209091206003909102018054600182015460029092015490925083565b6111cc611526565b6001600160a01b0381166112485760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610412565b61125181611580565b50565b6003546001600160a01b0316336001600160a01b0316146112dd5760405162461bcd60e51b815260206004820152603860248201527f52616461725374616b653a204f6e6c7920746865205374616b696e674c6f676960448201527f6320636f6e74726163742063616e2063616c6c207468697300000000000000006064820152608401610412565b6001600160a01b0381166113435760405162461bcd60e51b815260206004820152602760248201527f52616461725374616b653a2043616e6e6f742075736520746865206e756c6c206044820152666164647265737360c81b6064820152608401610412565b6000600554116113bb5760405162461bcd60e51b815260206004820152603260248201527f52616461725374616b653a20436f6f6c646f776e207365636f6e6473206d757360448201527f7420626520626967676572207468616e203000000000000000000000000000006064820152608401610412565b6001600160a01b03811660009081526007602090815260409182902082516080810184528154815260018201549281019290925260028101549282019290925260039091015460608201819052156114a15760405162461bcd60e51b815260206004820152604560248201527f52616461725374616b653a20436f6f6c646f776e20697320616c72656164792060448201527f696e2070726f6772657373202d2063616e6e6f7420747269676765722069742060648201527f616761696e000000000000000000000000000000000000000000000000000000608482015260a401610412565b60058054604083810191825242606085019081526001600160a01b03861660008181526007602090815290849020875181558188015160018201559451600286015591516003909401939093559254905190815290917fdd9ec76fd04aab7ee6b385c04a7bdf966620500e72b134bfc3f19654fae20f25910160405180910390a25050565b6000546001600160a01b031633146109875760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610412565b600080546001600160a01b0383811673ffffffffffffffffffffffffffffffffffffffff19831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b602080825282518282018190526000919060409081850190868401855b8281101561162957815180518552868101518786015285015185850152606090930192908501906001016115fa565b5091979650505050505050565b80356001600160a01b038116811461164d57600080fd5b919050565b6000806040838503121561166557600080fd5b8235915061167560208401611636565b90509250929050565b60006020828403121561169057600080fd5b5035919050565b6000602082840312156116a957600080fd5b6116b282611636565b9392505050565b600080604083850312156116cc57600080fd5b6116d583611636565b946020939093013593505050565b634e487b7160e01b600052601160045260246000fd5b8181038181111561170c5761170c6116e3565b92915050565b60006020828403121561172457600080fd5b815180151581146116b257600080fd5b60006020828403121561174657600080fd5b5051919050565b634e487b7160e01b600052603260045260246000fd5b8082018082111561170c5761170c6116e356fea26469706673582212204975992194a495af9b518b7fdd6e6eb6e769e2098187371e8e69e798b032acf064736f6c63430008110033000000000000000000000000dcb72ae4d5dc6ae274461d57e65db8d50d0a33ad
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106101515760003560e01c8063817b1cd2116100cd578063cfe2284a11610081578063e74727f711610066578063e74727f7146102bc578063f2fde38b146102ea578063f94090c8146102fd57600080fd5b8063cfe2284a14610296578063dba45877146102a957600080fd5b80638f3bbb9f116100b25780638f3bbb9f14610267578063922f21231461027a578063b8221bc41461028d57600080fd5b8063817b1cd21461023f5780638da5cb5b1461025657600080fd5b80634bb9a48211610124578063715018a611610109578063715018a6146101de5780637a766460146101e65780637b5b11571461022c57600080fd5b80634bb9a482146101b85780635a2e2f47146101cb57600080fd5b80630a7dcd75146101565780631f1d74031461018657806327c2ad4c1461019b5780633ccfd60b146101b0575b600080fd5b600354610169906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b61018e610310565b60405161017d91906115dd565b6101ae6101a9366004611652565b61038d565b005b6101ae610730565b6101ae6101c636600461167e565b6107f3565b6101ae6101d9366004611697565b6108d8565b6101ae610975565b6101f96101f4366004611697565b610989565b60405161017d91908151815260208083015190820152604080830151908201526060918201519181019190915260800190565b6101ae61023a36600461167e565b610a02565b61024860045481565b60405190815260200161017d565b6000546001600160a01b0316610169565b6101ae6102753660046116b9565b610a85565b6101ae61028836600461167e565b610de8565b61024860055481565b6101ae6102a4366004611652565b610f50565b600254610169906001600160a01b031681565b6102cf6102ca36600461167e565b611191565b6040805193845260208401929092529082015260600161017d565b6101ae6102f8366004611697565b6111c4565b6101ae61030b366004611697565b611254565b60606006805480602002602001604051908101604052809291908181526020016000905b828210156103845783829060005260206000209060030201604051806060016040529081600082015481526020016001820154815260200160028201548152505081526020019060010190610334565b50505050905090565b6003546001600160a01b0316336001600160a01b03161461041b5760405162461bcd60e51b815260206004820152603860248201527f52616461725374616b653a204f6e6c7920746865205374616b696e674c6f676960448201527f6320636f6e74726163742063616e2063616c6c2074686973000000000000000060648201526084015b60405180910390fd5b600082116104915760405162461bcd60e51b815260206004820152602960248201527f52616461725374616b653a20416d6f756e742063616e6e6f74206265206c6f7760448201527f6572207468616e203000000000000000000000000000000000000000000000006064820152608401610412565b6001600160a01b0381166104f75760405162461bcd60e51b815260206004820152602760248201527f52616461725374616b653a2043616e6e6f742075736520746865206e756c6c206044820152666164647265737360c81b6064820152608401610412565b6001600160a01b038116600090815260076020908152604091829020825160808101845281548082526001830154938201939093526002820154938101939093526003015460608301528311156105b65760405162461bcd60e51b815260206004820152603860248201527f52616461725374616b653a20596f752063616e6e6f7420756e7374616b65206d60448201527f6f7265207468616e20796f752068617665207374616b656400000000000000006064820152608401610412565b82600454101561062e5760405162461bcd60e51b815260206004820152603760248201527f52616461725374616b653a2043616e6e6f7420756e7374616b65206d6f72652060448201527f7468616e206973207374616b656420696e20746f74616c0000000000000000006064820152608401610412565b8051839003610669576001600160a01b03821660009081526007602052604081208181556001810182905560028101829055600301556106d5565b604051806080016040528084836000015161068491906116f9565b8152426020808301919091526000604080840182905260609384018290526001600160a01b038716825260078352908190208451815591840151600183015583015160028201559101516003909101555b82600460008282546106e791906116f9565b90915550506040518381526001600160a01b038316907fa952f29b693be45a22ce3b4af46afdf4576cbaa7ffb0d205f77d3b8bb53f1855906020015b60405180910390a2505050565b610738611526565b47600061074d6000546001600160a01b031690565b6001600160a01b03168260405160006040518083038185875af1925050503d8060008114610797576040519150601f19603f3d011682016040523d82523d6000602084013e61079c565b606091505b505080915050806107ef5760405162461bcd60e51b815260206004820181905260248201527f52616461725374616b653a204661696c656420746f2073656e642066756e64736044820152606401610412565b5050565b6107fb611526565b6000811161085f5760405162461bcd60e51b815260206004820152602b60248201527f52616461725374616b653a20416d6f756e742068617320746f2062652067726560448201526a061746572207468616e20360ac1b6064820152608401610412565b60025460035460405163095ea7b360e01b81526001600160a01b0391821660048201526024810184905291169063095ea7b3906044016020604051808303816000875af11580156108b4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107ef9190611712565b6108e0611526565b6001600160a01b0381166109465760405162461bcd60e51b815260206004820152602760248201527f52616461725374616b653a2043616e6e6f742075736520746865206e756c6c206044820152666164647265737360c81b6064820152608401610412565b6003805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b61097d611526565b6109876000611580565b565b6109b46040518060800160405280600081526020016000815260200160008152602001600081525090565b506001600160a01b0316600090815260076020908152604091829020825160808101845281548152600182015492810192909252600281015492820192909252600390910154606082015290565b610a0a611526565b60008111610a805760405162461bcd60e51b815260206004820152602260248201527f52616461725374616b653a20416d6f756e74206d7573742062652061626f766560448201527f20300000000000000000000000000000000000000000000000000000000000006064820152608401610412565b600555565b610a8d611526565b6001600160a01b038216610af35760405162461bcd60e51b815260206004820152602760248201527f52616461725374616b653a2043616e6e6f742075736520746865206e756c6c206044820152666164647265737360c81b6064820152608401610412565b60008111610b575760405162461bcd60e51b815260206004820152602b60248201527f52616461725374616b653a20416d6f756e742068617320746f2062652067726560448201526a061746572207468616e20360ac1b6064820152608401610412565b6002546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916001600160a01b0316906370a0823190602401602060405180830381865afa158015610bb9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bdd9190611734565b905081811015610c555760405162461bcd60e51b815260206004820152603260248201527f52616461725374616b653a2043616e6e6f74207769746864726177206d6f726560448201527f207468616e20697320617661696c61626c6500000000000000000000000000006064820152608401610412565b600454610c6283836116f9565b1015610cd65760405162461bcd60e51b815260206004820152602f60248201527f52616461725374616b653a2043616e6e6f74207769746864726177206d6f726560448201527f207468616e206973207374616b656400000000000000000000000000000000006064820152608401610412565b60025460405163095ea7b360e01b8152306004820152602481018490526001600160a01b039091169063095ea7b3906044016020604051808303816000875af1158015610d27573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d4b9190611712565b506002546040517f23b872dd0000000000000000000000000000000000000000000000000000000081523060048201526001600160a01b03858116602483015260448201859052909116906323b872dd906064016020604051808303816000875af1158015610dbe573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610de29190611712565b50505050565b610df0611526565b60008111610e665760405162461bcd60e51b815260206004820152602660248201527f52616461725374616b653a204150522063616e6e6f74206265206c6f7765722060448201527f7468616e203000000000000000000000000000000000000000000000000000006064820152608401610412565b60065415610ead576006805460009190610e82906001906116f9565b81548110610e9257610e9261174d565b90600052602060002090600302019050428160010181905550505b6040805160608101825242815260006020820181815292820193845260068054600181018255915290517ff652222313e28459528d920b65115c16c04f3efc82aaedc97be59f3f377c0d3f60039092029182015590517ff652222313e28459528d920b65115c16c04f3efc82aaedc97be59f3f377c0d4082015590517ff652222313e28459528d920b65115c16c04f3efc82aaedc97be59f3f377c0d4190910155565b6003546001600160a01b0316336001600160a01b031614610fd95760405162461bcd60e51b815260206004820152603860248201527f52616461725374616b653a204f6e6c7920746865205374616b696e674c6f676960448201527f6320636f6e74726163742063616e2063616c6c207468697300000000000000006064820152608401610412565b6001600160a01b03811661103f5760405162461bcd60e51b815260206004820152602760248201527f52616461725374616b653a2043616e6e6f742075736520746865206e756c6c206044820152666164647265737360c81b6064820152608401610412565b60065461108e5760405162461bcd60e51b815260206004820152601660248201527f52616461725374616b653a204e6f2041505220736574000000000000000000006044820152606401610412565b6001600160a01b0381166000908152600760209081526040918290208251608080820185528254825260018301549382019390935260028201548185015260039091015460608201528251918201909252815181906110ee908690611763565b8152426020808301919091526000604080840182905260609384018290526001600160a01b038716825260078352808220855181559285015160018401558401516002830155929091015160039091015560048054859290611151908490611763565b90915550506040518381526001600160a01b038316907f7bbf6a19a8b550713b9d9b9d38e56fd83d58218685b4d39e2ed965d777598df190602001610723565b600681815481106111a157600080fd5b600091825260209091206003909102018054600182015460029092015490925083565b6111cc611526565b6001600160a01b0381166112485760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610412565b61125181611580565b50565b6003546001600160a01b0316336001600160a01b0316146112dd5760405162461bcd60e51b815260206004820152603860248201527f52616461725374616b653a204f6e6c7920746865205374616b696e674c6f676960448201527f6320636f6e74726163742063616e2063616c6c207468697300000000000000006064820152608401610412565b6001600160a01b0381166113435760405162461bcd60e51b815260206004820152602760248201527f52616461725374616b653a2043616e6e6f742075736520746865206e756c6c206044820152666164647265737360c81b6064820152608401610412565b6000600554116113bb5760405162461bcd60e51b815260206004820152603260248201527f52616461725374616b653a20436f6f6c646f776e207365636f6e6473206d757360448201527f7420626520626967676572207468616e203000000000000000000000000000006064820152608401610412565b6001600160a01b03811660009081526007602090815260409182902082516080810184528154815260018201549281019290925260028101549282019290925260039091015460608201819052156114a15760405162461bcd60e51b815260206004820152604560248201527f52616461725374616b653a20436f6f6c646f776e20697320616c72656164792060448201527f696e2070726f6772657373202d2063616e6e6f7420747269676765722069742060648201527f616761696e000000000000000000000000000000000000000000000000000000608482015260a401610412565b60058054604083810191825242606085019081526001600160a01b03861660008181526007602090815290849020875181558188015160018201559451600286015591516003909401939093559254905190815290917fdd9ec76fd04aab7ee6b385c04a7bdf966620500e72b134bfc3f19654fae20f25910160405180910390a25050565b6000546001600160a01b031633146109875760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610412565b600080546001600160a01b0383811673ffffffffffffffffffffffffffffffffffffffff19831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b602080825282518282018190526000919060409081850190868401855b8281101561162957815180518552868101518786015285015185850152606090930192908501906001016115fa565b5091979650505050505050565b80356001600160a01b038116811461164d57600080fd5b919050565b6000806040838503121561166557600080fd5b8235915061167560208401611636565b90509250929050565b60006020828403121561169057600080fd5b5035919050565b6000602082840312156116a957600080fd5b6116b282611636565b9392505050565b600080604083850312156116cc57600080fd5b6116d583611636565b946020939093013593505050565b634e487b7160e01b600052601160045260246000fd5b8181038181111561170c5761170c6116e3565b92915050565b60006020828403121561172457600080fd5b815180151581146116b257600080fd5b60006020828403121561174657600080fd5b5051919050565b634e487b7160e01b600052603260045260246000fd5b8082018082111561170c5761170c6116e356fea26469706673582212204975992194a495af9b518b7fdd6e6eb6e769e2098187371e8e69e798b032acf064736f6c63430008110033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000dcb72ae4d5dc6ae274461d57e65db8d50d0a33ad
-----Decoded View---------------
Arg [0] : radarTokenContractAddr (address): 0xdCb72AE4d5dc6Ae274461d57E65dB8D50d0a33AD
-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 000000000000000000000000dcb72ae4d5dc6ae274461d57e65db8d50d0a33ad
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 31 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
[ 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.