Overview
ETH Balance
ETH Value
$0.00Latest 25 from a total of 5,819 transactions
| Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
|---|---|---|---|---|---|---|---|---|---|
| Redeem | 82057883 | 970 days ago | IN | 0 ETH | 0.00005892 | ||||
| Redeem All | 82057203 | 970 days ago | IN | 0 ETH | 0.00004754 | ||||
| Set Paused | 78355527 | 981 days ago | IN | 0 ETH | 0.00003565 | ||||
| Deposit | 78341961 | 981 days ago | IN | 0 ETH | 0.00006902 | ||||
| Deposit | 78335021 | 981 days ago | IN | 0 ETH | 0.0000722 | ||||
| Deposit | 78313550 | 981 days ago | IN | 0 ETH | 0.0000713 | ||||
| Deposit | 78312892 | 981 days ago | IN | 0 ETH | 0.00007164 | ||||
| Redeem | 78310133 | 981 days ago | IN | 0 ETH | 0.00008753 | ||||
| Deposit | 78272885 | 981 days ago | IN | 0 ETH | 0.00006883 | ||||
| Deposit | 78233418 | 981 days ago | IN | 0 ETH | 0.00007049 | ||||
| Deposit | 78205192 | 981 days ago | IN | 0 ETH | 0.00007072 | ||||
| Redeem | 78136008 | 982 days ago | IN | 0 ETH | 0.00009463 | ||||
| Deposit | 78087320 | 982 days ago | IN | 0 ETH | 0.0000807 | ||||
| Redeem | 78079772 | 982 days ago | IN | 0 ETH | 0.00009552 | ||||
| Redeem | 78041358 | 982 days ago | IN | 0 ETH | 0.00009922 | ||||
| Deposit | 78028077 | 982 days ago | IN | 0 ETH | 0.0000907 | ||||
| Deposit | 78025727 | 982 days ago | IN | 0 ETH | 0.00009459 | ||||
| Deposit | 78021339 | 982 days ago | IN | 0 ETH | 0.00011153 | ||||
| Redeem | 78021271 | 982 days ago | IN | 0 ETH | 0.00012878 | ||||
| Deposit | 78007034 | 982 days ago | IN | 0 ETH | 0.00007652 | ||||
| Redeem | 77987584 | 982 days ago | IN | 0 ETH | 0.00009689 | ||||
| Deposit | 77971080 | 982 days ago | IN | 0 ETH | 0.00007588 | ||||
| Redeem | 77944649 | 982 days ago | IN | 0 ETH | 0.00008882 | ||||
| Redeem | 77938699 | 982 days ago | IN | 0 ETH | 0.00008938 | ||||
| Deposit | 77887247 | 982 days ago | IN | 0 ETH | 0.00007078 |
Latest 25 internal transactions (View All)
| Parent Transaction Hash | Block | From | To | |||
|---|---|---|---|---|---|---|
| 72066509 | 999 days ago | 0 ETH | ||||
| 72066509 | 999 days ago | 0 ETH | ||||
| 72066509 | 999 days ago | 0 ETH | ||||
| 72066509 | 999 days ago | 0 ETH | ||||
| 72066509 | 999 days ago | 0 ETH | ||||
| 72066488 | 999 days ago | 0 ETH | ||||
| 72066488 | 999 days ago | 0 ETH | ||||
| 72066488 | 999 days ago | 0 ETH | ||||
| 72066488 | 999 days ago | 0 ETH | ||||
| 72066488 | 999 days ago | 0 ETH | ||||
| 72059282 | 999 days ago | 0 ETH | ||||
| 72059282 | 999 days ago | 0 ETH | ||||
| 72059282 | 999 days ago | 0 ETH | ||||
| 72059282 | 999 days ago | 0 ETH | ||||
| 72059282 | 999 days ago | 0 ETH | ||||
| 72059282 | 999 days ago | 0 ETH | ||||
| 72059282 | 999 days ago | 0 ETH | ||||
| 72058359 | 999 days ago | 0 ETH | ||||
| 72058359 | 999 days ago | 0 ETH | ||||
| 72058359 | 999 days ago | 0 ETH | ||||
| 72058359 | 999 days ago | 0 ETH | ||||
| 72058359 | 999 days ago | 0 ETH | ||||
| 72043348 | 999 days ago | 0 ETH | ||||
| 72043348 | 999 days ago | 0 ETH | ||||
| 72043348 | 999 days ago | 0 ETH |
Cross-Chain Transactions
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: BUSL-1.1
pragma solidity 0.8.9;
import '@openzeppelin/contracts/security/Pausable.sol';
import '@openzeppelin/contracts/token/ERC20/IERC20.sol';
import '@openzeppelin/contracts/interfaces/IERC4626.sol';
import '@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol';
import './utils/OwnableWithRetrieve.sol';
import '../interfaces/ITokenMinter.sol';
import { IWhitelist } from '../Whitelist.sol';
contract GlpDepositor is OwnableWithRetrieve, Pausable {
using SafeERC20 for IERC20;
uint256 private constant FEE_DIVISOR = 1e4;
IERC20 public constant fsGLP = IERC20(0x1aDDD80E6039594eE970E5872D247bf0414C8903); // balance query
IERC20 public constant sGLP = IERC20(0x2F546AD4eDD93B956C8999Be404cdCAFde3E89AE); // transfers
struct PartnerInfo {
bool isActive;
uint32 exitFee; // in bp
uint32 rebate; // in bp of {exitFee}
}
address public immutable minter; // plsGLP
address public immutable staker;
address public immutable vault; // plvGLP
address private exitFeeCollector;
mapping(address => PartnerInfo) private partners;
uint32 public defaultExitFee;
uint32 public defaultVaultRebate;
IWhitelist public whitelist;
constructor(
address _minter,
address _staker,
address _vault,
address _exitFeeCollector,
address _whitelist
) {
minter = _minter;
staker = _staker;
vault = _vault;
exitFeeCollector = _exitFeeCollector;
whitelist = IWhitelist(_whitelist);
defaultExitFee = 200; // fee in bp - 2%
defaultVaultRebate = 2500; // rebate in bp of {exitFee} - 25%
IERC20(minter).approve(_vault, type(uint256).max);
}
function deposit(uint256 _amount) public whenNotPaused {
_isEligibleSender();
_deposit(msg.sender, _amount);
}
function redeem(uint256 _amount) public whenNotPaused {
_isEligibleSender();
PartnerInfo memory partner = partners[msg.sender];
uint256 exitFee = partner.isActive ? partner.exitFee : defaultExitFee;
uint256 rebate = partner.isActive ? partner.rebate : defaultVaultRebate;
_redeem(msg.sender, _amount, exitFee, rebate);
}
function previewRedeem(address _addr, uint256 _shares)
external
view
returns (
uint256 _exitFeeLessRebate,
uint256 _rebateAmount,
uint256 _assetsLessFee
)
{
PartnerInfo memory partner = partners[_addr];
uint256 exitFee = partner.isActive ? partner.exitFee : defaultExitFee;
uint256 rebate = partner.isActive ? partner.rebate : defaultVaultRebate;
uint256 assets = IERC4626(vault).previewRedeem(_shares);
uint256 _exitFee;
(_exitFee, _assetsLessFee) = _calculateFee(assets, exitFee);
(_rebateAmount, _exitFeeLessRebate) = _calculateFee(_exitFee, rebate);
}
function getFeeBp(address _addr) external view returns (uint256 _exitFee, uint256 _rebate) {
PartnerInfo memory partner = partners[_addr];
_exitFee = partner.isActive ? partner.exitFee : defaultExitFee;
_rebate = partner.isActive ? partner.rebate : defaultVaultRebate;
}
///@notice Deposit _assets
function depositAll() external {
deposit(fsGLP.balanceOf(msg.sender));
}
///@notice Withdraw _shares
function redeemAll() external {
redeem(IERC20(vault).balanceOf(msg.sender));
}
function donate(uint256 _assets) external {
sGLP.safeTransferFrom(msg.sender, staker, _assets);
ITokenMinter(minter).mint(vault, _assets);
}
/** PRIVATE FUNCTIONS */
function _deposit(address _user, uint256 _assets) private {
if (_assets < 1 ether) revert UNDER_MIN_AMOUNT();
// unstake for _user, stake in staker
// requires approval in user for depositor to spend
sGLP.safeTransferFrom(_user, staker, _assets);
// mint appropriate plsGLP to depositor
ITokenMinter(minter).mint(address(this), _assets);
// deposit plsGLP into vault for plvGLP
// already max approved in constructor
uint256 _shares = IERC4626(vault).deposit(_assets, _user);
emit Deposited(_user, _assets, _shares);
_validateInvariants();
}
function _redeem(
address _user,
uint256 _shares,
uint256 exitFee,
uint256 rebate
) private {
if (_shares < 1 ether) revert UNDER_MIN_AMOUNT();
// redeem plvGLP for plsGLP to address(this)
uint256 _assets = IERC4626(vault).redeem(_shares, address(this), _user);
(uint256 _exitFee, uint256 _assetsLessFee) = _calculateFee(_assets, exitFee);
(uint256 _rebateAmount, uint256 _exitFeeLessRebate) = _calculateFee(_exitFee, rebate);
// burn redeemed plsGLP less rebate
ITokenMinter(minter).burn(address(this), _assets - _rebateAmount);
// transfer rebate to vault
SafeERC20.safeTransfer(IERC20(minter), vault, _rebateAmount);
// requires approval in staker for depositor to spend
sGLP.safeTransferFrom(staker, _user, _assetsLessFee);
sGLP.safeTransferFrom(staker, exitFeeCollector, _exitFeeLessRebate);
emit Withdrawed(_user, _shares, _assetsLessFee, _rebateAmount, _exitFeeLessRebate);
_validateInvariants();
}
function _calculateFee(uint256 _totalAmount, uint256 _feeInBp)
private
pure
returns (uint256 _fee, uint256 _amountLessFee)
{
unchecked {
_fee = (_totalAmount * _feeInBp) / FEE_DIVISOR;
_amountLessFee = _totalAmount - _fee;
}
}
function _isEligibleSender() private view {
if (
msg.sender != tx.origin && whitelist.isWhitelisted(msg.sender) == false && partners[msg.sender].isActive == false
) revert UNAUTHORIZED();
}
function _validateInvariants() private view {
/**
* Invariants:
* 1. staker fsGLP balance must always equal plsGLP.totalSupply()
* 2. plsGLP can only be held by vault
*/
if (fsGLP.balanceOf(staker) != IERC20(minter).balanceOf(vault)) revert INVARIANT_VIOLATION();
}
/** OWNER FUNCTIONS */
function setExitFee(uint32 _newFee, uint32 _vaultRebate) external onlyOwner {
if (_newFee > FEE_DIVISOR || _vaultRebate > FEE_DIVISOR) revert BAD_FEE();
emit FeeUpdated(_newFee, _vaultRebate);
defaultExitFee = _newFee;
defaultVaultRebate = _vaultRebate;
}
///@dev _partnerAddr needs to have an approval for this contract to spend sGLP
function updatePartner(
address _partnerAddr,
uint32 _exitFee,
uint32 _rebate,
bool _isActive
) external onlyOwner {
partners[_partnerAddr] = PartnerInfo({ isActive: _isActive, exitFee: _exitFee, rebate: _rebate });
emit PartnerUpdated(_partnerAddr, _exitFee, _rebate, _isActive);
}
function setFeeCollector(address _newFeeCollector) external onlyOwner {
emit FeeCollectorUpdated(_newFeeCollector, exitFeeCollector);
exitFeeCollector = _newFeeCollector;
}
function setWhitelist(address _whitelist) external onlyOwner {
emit WhitelistUpdated(_whitelist, address(whitelist));
whitelist = IWhitelist(_whitelist);
}
function setPaused(bool _pauseContract) external onlyOwner {
if (_pauseContract) {
_pause();
} else {
_unpause();
}
}
event WhitelistUpdated(address _new, address _old);
event FeeCollectorUpdated(address _new, address _old);
event FeeUpdated(uint256 _newFee, uint256 _vaultRebate);
event PartnerUpdated(address _partner, uint32 _exitFee, uint32 _rebate, bool _isActive);
event Deposited(address indexed _user, uint256 _assets, uint256 _shares);
event Withdrawed(address indexed _user, uint256 _shares, uint256 _assetsLessFee, uint256 _vaultRebate, uint256 _fee);
event InvariantsViolated(uint256 _blockNumber, uint256 _fsGLPSupply, uint256 _plsGLPSupply, uint256 _plvGLPSupply);
error UNDER_MIN_AMOUNT();
error UNAUTHORIZED();
error INVARIANT_VIOLATION();
error BAD_FEE();
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (security/Pausable.sol)
pragma solidity ^0.8.0;
import "../utils/Context.sol";
/**
* @dev Contract module which allows children to implement an emergency stop
* mechanism that can be triggered by an authorized account.
*
* This module is used through inheritance. It will make available the
* modifiers `whenNotPaused` and `whenPaused`, which can be applied to
* the functions of your contract. Note that they will not be pausable by
* simply including this module, only once the modifiers are put in place.
*/
abstract contract Pausable is Context {
/**
* @dev Emitted when the pause is triggered by `account`.
*/
event Paused(address account);
/**
* @dev Emitted when the pause is lifted by `account`.
*/
event Unpaused(address account);
bool private _paused;
/**
* @dev Initializes the contract in unpaused state.
*/
constructor() {
_paused = false;
}
/**
* @dev Modifier to make a function callable only when the contract is not paused.
*
* Requirements:
*
* - The contract must not be paused.
*/
modifier whenNotPaused() {
_requireNotPaused();
_;
}
/**
* @dev Modifier to make a function callable only when the contract is paused.
*
* Requirements:
*
* - The contract must be paused.
*/
modifier whenPaused() {
_requirePaused();
_;
}
/**
* @dev Returns true if the contract is paused, and false otherwise.
*/
function paused() public view virtual returns (bool) {
return _paused;
}
/**
* @dev Throws if the contract is paused.
*/
function _requireNotPaused() internal view virtual {
require(!paused(), "Pausable: paused");
}
/**
* @dev Throws if the contract is not paused.
*/
function _requirePaused() internal view virtual {
require(paused(), "Pausable: not paused");
}
/**
* @dev Triggers stopped state.
*
* Requirements:
*
* - The contract must not be paused.
*/
function _pause() internal virtual whenNotPaused {
_paused = true;
emit Paused(_msgSender());
}
/**
* @dev Returns to normal state.
*
* Requirements:
*
* - The contract must be paused.
*/
function _unpause() internal virtual whenPaused {
_paused = false;
emit Unpaused(_msgSender());
}
}// 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 (last updated v4.7.0) (interfaces/IERC4626.sol)
pragma solidity ^0.8.0;
import "../token/ERC20/IERC20.sol";
import "../token/ERC20/extensions/IERC20Metadata.sol";
/**
* @dev Interface of the ERC4626 "Tokenized Vault Standard", as defined in
* https://eips.ethereum.org/EIPS/eip-4626[ERC-4626].
*
* _Available since v4.7._
*/
interface IERC4626 is IERC20, IERC20Metadata {
event Deposit(address indexed caller, address indexed owner, uint256 assets, uint256 shares);
event Withdraw(
address indexed caller,
address indexed receiver,
address indexed owner,
uint256 assets,
uint256 shares
);
/**
* @dev Returns the address of the underlying token used for the Vault for accounting, depositing, and withdrawing.
*
* - MUST be an ERC-20 token contract.
* - MUST NOT revert.
*/
function asset() external view returns (address assetTokenAddress);
/**
* @dev Returns the total amount of the underlying asset that is “managed” by Vault.
*
* - SHOULD include any compounding that occurs from yield.
* - MUST be inclusive of any fees that are charged against assets in the Vault.
* - MUST NOT revert.
*/
function totalAssets() external view returns (uint256 totalManagedAssets);
/**
* @dev Returns the amount of shares that the Vault would exchange for the amount of assets provided, in an ideal
* scenario where all the conditions are met.
*
* - MUST NOT be inclusive of any fees that are charged against assets in the Vault.
* - MUST NOT show any variations depending on the caller.
* - MUST NOT reflect slippage or other on-chain conditions, when performing the actual exchange.
* - MUST NOT revert.
*
* NOTE: This calculation MAY NOT reflect the “per-user” price-per-share, and instead should reflect the
* “average-user’s” price-per-share, meaning what the average user should expect to see when exchanging to and
* from.
*/
function convertToShares(uint256 assets) external view returns (uint256 shares);
/**
* @dev Returns the amount of assets that the Vault would exchange for the amount of shares provided, in an ideal
* scenario where all the conditions are met.
*
* - MUST NOT be inclusive of any fees that are charged against assets in the Vault.
* - MUST NOT show any variations depending on the caller.
* - MUST NOT reflect slippage or other on-chain conditions, when performing the actual exchange.
* - MUST NOT revert.
*
* NOTE: This calculation MAY NOT reflect the “per-user” price-per-share, and instead should reflect the
* “average-user’s” price-per-share, meaning what the average user should expect to see when exchanging to and
* from.
*/
function convertToAssets(uint256 shares) external view returns (uint256 assets);
/**
* @dev Returns the maximum amount of the underlying asset that can be deposited into the Vault for the receiver,
* through a deposit call.
*
* - MUST return a limited value if receiver is subject to some deposit limit.
* - MUST return 2 ** 256 - 1 if there is no limit on the maximum amount of assets that may be deposited.
* - MUST NOT revert.
*/
function maxDeposit(address receiver) external view returns (uint256 maxAssets);
/**
* @dev Allows an on-chain or off-chain user to simulate the effects of their deposit at the current block, given
* current on-chain conditions.
*
* - MUST return as close to and no more than the exact amount of Vault shares that would be minted in a deposit
* call in the same transaction. I.e. deposit should return the same or more shares as previewDeposit if called
* in the same transaction.
* - MUST NOT account for deposit limits like those returned from maxDeposit and should always act as though the
* deposit would be accepted, regardless if the user has enough tokens approved, etc.
* - MUST be inclusive of deposit fees. Integrators should be aware of the existence of deposit fees.
* - MUST NOT revert.
*
* NOTE: any unfavorable discrepancy between convertToShares and previewDeposit SHOULD be considered slippage in
* share price or some other type of condition, meaning the depositor will lose assets by depositing.
*/
function previewDeposit(uint256 assets) external view returns (uint256 shares);
/**
* @dev Mints shares Vault shares to receiver by depositing exactly amount of underlying tokens.
*
* - MUST emit the Deposit event.
* - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the
* deposit execution, and are accounted for during deposit.
* - MUST revert if all of assets cannot be deposited (due to deposit limit being reached, slippage, the user not
* approving enough underlying tokens to the Vault contract, etc).
*
* NOTE: most implementations will require pre-approval of the Vault with the Vault’s underlying asset token.
*/
function deposit(uint256 assets, address receiver) external returns (uint256 shares);
/**
* @dev Returns the maximum amount of the Vault shares that can be minted for the receiver, through a mint call.
* - MUST return a limited value if receiver is subject to some mint limit.
* - MUST return 2 ** 256 - 1 if there is no limit on the maximum amount of shares that may be minted.
* - MUST NOT revert.
*/
function maxMint(address receiver) external view returns (uint256 maxShares);
/**
* @dev Allows an on-chain or off-chain user to simulate the effects of their mint at the current block, given
* current on-chain conditions.
*
* - MUST return as close to and no fewer than the exact amount of assets that would be deposited in a mint call
* in the same transaction. I.e. mint should return the same or fewer assets as previewMint if called in the
* same transaction.
* - MUST NOT account for mint limits like those returned from maxMint and should always act as though the mint
* would be accepted, regardless if the user has enough tokens approved, etc.
* - MUST be inclusive of deposit fees. Integrators should be aware of the existence of deposit fees.
* - MUST NOT revert.
*
* NOTE: any unfavorable discrepancy between convertToAssets and previewMint SHOULD be considered slippage in
* share price or some other type of condition, meaning the depositor will lose assets by minting.
*/
function previewMint(uint256 shares) external view returns (uint256 assets);
/**
* @dev Mints exactly shares Vault shares to receiver by depositing amount of underlying tokens.
*
* - MUST emit the Deposit event.
* - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the mint
* execution, and are accounted for during mint.
* - MUST revert if all of shares cannot be minted (due to deposit limit being reached, slippage, the user not
* approving enough underlying tokens to the Vault contract, etc).
*
* NOTE: most implementations will require pre-approval of the Vault with the Vault’s underlying asset token.
*/
function mint(uint256 shares, address receiver) external returns (uint256 assets);
/**
* @dev Returns the maximum amount of the underlying asset that can be withdrawn from the owner balance in the
* Vault, through a withdraw call.
*
* - MUST return a limited value if owner is subject to some withdrawal limit or timelock.
* - MUST NOT revert.
*/
function maxWithdraw(address owner) external view returns (uint256 maxAssets);
/**
* @dev Allows an on-chain or off-chain user to simulate the effects of their withdrawal at the current block,
* given current on-chain conditions.
*
* - MUST return as close to and no fewer than the exact amount of Vault shares that would be burned in a withdraw
* call in the same transaction. I.e. withdraw should return the same or fewer shares as previewWithdraw if
* called
* in the same transaction.
* - MUST NOT account for withdrawal limits like those returned from maxWithdraw and should always act as though
* the withdrawal would be accepted, regardless if the user has enough shares, etc.
* - MUST be inclusive of withdrawal fees. Integrators should be aware of the existence of withdrawal fees.
* - MUST NOT revert.
*
* NOTE: any unfavorable discrepancy between convertToShares and previewWithdraw SHOULD be considered slippage in
* share price or some other type of condition, meaning the depositor will lose assets by depositing.
*/
function previewWithdraw(uint256 assets) external view returns (uint256 shares);
/**
* @dev Burns shares from owner and sends exactly assets of underlying tokens to receiver.
*
* - MUST emit the Withdraw event.
* - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the
* withdraw execution, and are accounted for during withdraw.
* - MUST revert if all of assets cannot be withdrawn (due to withdrawal limit being reached, slippage, the owner
* not having enough shares, etc).
*
* Note that some implementations will require pre-requesting to the Vault before a withdrawal may be performed.
* Those methods should be performed separately.
*/
function withdraw(
uint256 assets,
address receiver,
address owner
) external returns (uint256 shares);
/**
* @dev Returns the maximum amount of Vault shares that can be redeemed from the owner balance in the Vault,
* through a redeem call.
*
* - MUST return a limited value if owner is subject to some withdrawal limit or timelock.
* - MUST return balanceOf(owner) if owner is not subject to any withdrawal limit or timelock.
* - MUST NOT revert.
*/
function maxRedeem(address owner) external view returns (uint256 maxShares);
/**
* @dev Allows an on-chain or off-chain user to simulate the effects of their redeemption at the current block,
* given current on-chain conditions.
*
* - MUST return as close to and no more than the exact amount of assets that would be withdrawn in a redeem call
* in the same transaction. I.e. redeem should return the same or more assets as previewRedeem if called in the
* same transaction.
* - MUST NOT account for redemption limits like those returned from maxRedeem and should always act as though the
* redemption would be accepted, regardless if the user has enough shares, etc.
* - MUST be inclusive of withdrawal fees. Integrators should be aware of the existence of withdrawal fees.
* - MUST NOT revert.
*
* NOTE: any unfavorable discrepancy between convertToAssets and previewRedeem SHOULD be considered slippage in
* share price or some other type of condition, meaning the depositor will lose assets by redeeming.
*/
function previewRedeem(uint256 shares) external view returns (uint256 assets);
/**
* @dev Burns exactly shares from owner and sends assets of underlying tokens to receiver.
*
* - MUST emit the Withdraw event.
* - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the
* redeem execution, and are accounted for during redeem.
* - MUST revert if all of shares cannot be redeemed (due to withdrawal limit being reached, slippage, the owner
* not having enough shares, etc).
*
* NOTE: some implementations will require pre-requesting to the Vault before a withdrawal may be performed.
* Those methods should be performed separately.
*/
function redeem(
uint256 shares,
address receiver,
address owner
) external returns (uint256 assets);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC20/utils/SafeERC20.sol)
pragma solidity ^0.8.0;
import "../IERC20.sol";
import "../extensions/draft-IERC20Permit.sol";
import "../../../utils/Address.sol";
/**
* @title SafeERC20
* @dev Wrappers around ERC20 operations that throw on failure (when the token
* contract returns false). Tokens that return no value (and instead revert or
* throw on failure) are also supported, non-reverting calls are assumed to be
* successful.
* To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract,
* which allows you to call the safe operations as `token.safeTransfer(...)`, etc.
*/
library SafeERC20 {
using Address for address;
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));
}
/**
* @dev Deprecated. This function has issues similar to the ones found in
* {IERC20-approve}, and its usage is discouraged.
*
* Whenever possible, use {safeIncreaseAllowance} and
* {safeDecreaseAllowance} instead.
*/
function safeApprove(
IERC20 token,
address spender,
uint256 value
) internal {
// safeApprove should only be called when setting an initial allowance,
// or when resetting it to zero. To increase and decrease it, use
// 'safeIncreaseAllowance' and 'safeDecreaseAllowance'
require(
(value == 0) || (token.allowance(address(this), spender) == 0),
"SafeERC20: approve from non-zero to non-zero allowance"
);
_callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));
}
function safeIncreaseAllowance(
IERC20 token,
address spender,
uint256 value
) internal {
uint256 newAllowance = token.allowance(address(this), spender) + value;
_callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
}
function safeDecreaseAllowance(
IERC20 token,
address spender,
uint256 value
) internal {
unchecked {
uint256 oldAllowance = token.allowance(address(this), spender);
require(oldAllowance >= value, "SafeERC20: decreased allowance below zero");
uint256 newAllowance = oldAllowance - value;
_callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
}
}
function safePermit(
IERC20Permit token,
address owner,
address spender,
uint256 value,
uint256 deadline,
uint8 v,
bytes32 r,
bytes32 s
) internal {
uint256 nonceBefore = token.nonces(owner);
token.permit(owner, spender, value, deadline, v, r, s);
uint256 nonceAfter = token.nonces(owner);
require(nonceAfter == nonceBefore + 1, "SafeERC20: permit did not succeed");
}
/**
* @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement
* on the return value: the return value is optional (but if data is returned, it must not be false).
* @param token The token targeted by the call.
* @param data The call data (encoded using abi.encode or one of its variants).
*/
function _callOptionalReturn(IERC20 token, bytes memory data) private {
// We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since
// we're implementing it ourselves. We use {Address.functionCall} to perform this call, which verifies that
// the target address contains contract code and also asserts for success in the low-level call.
bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed");
if (returndata.length > 0) {
// Return data is optional
require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed");
}
}
}// SPDX-License-Identifier: MIT
pragma solidity 0.8.9;
import '@openzeppelin/contracts/token/ERC20/IERC20.sol';
import '@openzeppelin/contracts/access/Ownable.sol';
abstract contract OwnableWithRetrieve is Ownable {
/**
Retrieve stuck funds. Will also send any native ETH in contract to owner()
*/
function retrieve(IERC20 token) external onlyOwner {
if ((address(this).balance) != 0) {
owner().call{ value: address(this).balance }('');
}
token.transfer(owner(), token.balanceOf(address(this)));
}
}// SPDX-License-Identifier: MIT
pragma solidity 0.8.9;
interface ITokenMinter {
function mint(address, uint256) external;
function burn(address, uint256) external;
}// SPDX-License-Identifier: MIT
pragma solidity 0.8.9;
import '@openzeppelin/contracts/access/Ownable.sol';
interface IWhitelist {
function isWhitelisted(address) external view returns (bool);
}
contract Whitelist is IWhitelist, Ownable {
mapping(address => bool) public isWhitelisted;
constructor(address _gov) {
transferOwnership(_gov);
}
function whitelistAdd(address _addr) external onlyOwner {
isWhitelisted[_addr] = true;
emit AddedToWhitelist(_addr);
}
function whitelistRemove(address _addr) external onlyOwner {
isWhitelisted[_addr] = false;
emit RemovedFromWhitelist(_addr);
}
event RemovedFromWhitelist(address indexed _addr);
event AddedToWhitelist(address indexed _addr);
}// 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 v4.4.1 (token/ERC20/extensions/IERC20Metadata.sol)
pragma solidity ^0.8.0;
import "../IERC20.sol";
/**
* @dev Interface for the optional metadata functions from the ERC20 standard.
*
* _Available since v4.1._
*/
interface IERC20Metadata is IERC20 {
/**
* @dev Returns the name of the token.
*/
function name() external view returns (string memory);
/**
* @dev Returns the symbol of the token.
*/
function symbol() external view returns (string memory);
/**
* @dev Returns the decimals places of the token.
*/
function decimals() external view returns (uint8);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/draft-IERC20Permit.sol)
pragma solidity ^0.8.0;
/**
* @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in
* https://eips.ethereum.org/EIPS/eip-2612[EIP-2612].
*
* Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by
* presenting a message signed by the account. By not relying on {IERC20-approve}, the token holder account doesn't
* need to send a transaction, and thus is not required to hold Ether at all.
*/
interface IERC20Permit {
/**
* @dev Sets `value` as the allowance of `spender` over ``owner``'s tokens,
* given ``owner``'s signed approval.
*
* IMPORTANT: The same issues {IERC20-approve} has related to transaction
* ordering also apply here.
*
* Emits an {Approval} event.
*
* Requirements:
*
* - `spender` cannot be the zero address.
* - `deadline` must be a timestamp in the future.
* - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner`
* over the EIP712-formatted function arguments.
* - the signature must use ``owner``'s current nonce (see {nonces}).
*
* For more information on the signature format, see the
* https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP
* section].
*/
function permit(
address owner,
address spender,
uint256 value,
uint256 deadline,
uint8 v,
bytes32 r,
bytes32 s
) external;
/**
* @dev Returns the current nonce for `owner`. This value must be
* included whenever a signature is generated for {permit}.
*
* Every successful call to {permit} increases ``owner``'s nonce by one. This
* prevents a signature from being used multiple times.
*/
function nonces(address owner) external view returns (uint256);
/**
* @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}.
*/
// solhint-disable-next-line func-name-mixedcase
function DOMAIN_SEPARATOR() external view returns (bytes32);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (utils/Address.sol)
pragma solidity ^0.8.1;
/**
* @dev Collection of functions related to the address type
*/
library Address {
/**
* @dev Returns true if `account` is a contract.
*
* [IMPORTANT]
* ====
* It is unsafe to assume that an address for which this function returns
* false is an externally-owned account (EOA) and not a contract.
*
* Among others, `isContract` will return false for the following
* types of addresses:
*
* - an externally-owned account
* - a contract in construction
* - an address where a contract will be created
* - an address where a contract lived, but was destroyed
* ====
*
* [IMPORTANT]
* ====
* You shouldn't rely on `isContract` to protect against flash loan attacks!
*
* Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets
* like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract
* constructor.
* ====
*/
function isContract(address account) internal view returns (bool) {
// This method relies on extcodesize/address.code.length, which returns 0
// for contracts in construction, since the code is only stored at the end
// of the constructor execution.
return account.code.length > 0;
}
/**
* @dev Replacement for Solidity's `transfer`: sends `amount` wei to
* `recipient`, forwarding all available gas and reverting on errors.
*
* https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
* of certain opcodes, possibly making contracts go over the 2300 gas limit
* imposed by `transfer`, making them unable to receive funds via
* `transfer`. {sendValue} removes this limitation.
*
* https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
*
* IMPORTANT: because control is transferred to `recipient`, care must be
* taken to not create reentrancy vulnerabilities. Consider using
* {ReentrancyGuard} or the
* https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
*/
function sendValue(address payable recipient, uint256 amount) internal {
require(address(this).balance >= amount, "Address: insufficient balance");
(bool success, ) = recipient.call{value: amount}("");
require(success, "Address: unable to send value, recipient may have reverted");
}
/**
* @dev Performs a Solidity function call using a low level `call`. A
* plain `call` is an unsafe replacement for a function call: use this
* function instead.
*
* If `target` reverts with a revert reason, it is bubbled up by this
* function (like regular Solidity function calls).
*
* Returns the raw returned data. To convert to the expected return value,
* use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
*
* Requirements:
*
* - `target` must be a contract.
* - calling `target` with `data` must not revert.
*
* _Available since v3.1._
*/
function functionCall(address target, bytes memory data) internal returns (bytes memory) {
return functionCall(target, data, "Address: low-level call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
* `errorMessage` as a fallback revert reason when `target` reverts.
*
* _Available since v3.1._
*/
function functionCall(
address target,
bytes memory data,
string memory errorMessage
) internal returns (bytes memory) {
return functionCallWithValue(target, data, 0, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but also transferring `value` wei to `target`.
*
* Requirements:
*
* - the calling contract must have an ETH balance of at least `value`.
* - the called Solidity function must be `payable`.
*
* _Available since v3.1._
*/
function functionCallWithValue(
address target,
bytes memory data,
uint256 value
) internal returns (bytes memory) {
return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
}
/**
* @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
* with `errorMessage` as a fallback revert reason when `target` reverts.
*
* _Available since v3.1._
*/
function functionCallWithValue(
address target,
bytes memory data,
uint256 value,
string memory errorMessage
) internal returns (bytes memory) {
require(address(this).balance >= value, "Address: insufficient balance for call");
require(isContract(target), "Address: call to non-contract");
(bool success, bytes memory returndata) = target.call{value: value}(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a static call.
*
* _Available since v3.3._
*/
function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
return functionStaticCall(target, data, "Address: low-level static call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
* but performing a static call.
*
* _Available since v3.3._
*/
function functionStaticCall(
address target,
bytes memory data,
string memory errorMessage
) internal view returns (bytes memory) {
require(isContract(target), "Address: static call to non-contract");
(bool success, bytes memory returndata) = target.staticcall(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a delegate call.
*
* _Available since v3.4._
*/
function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
return functionDelegateCall(target, data, "Address: low-level delegate call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
* but performing a delegate call.
*
* _Available since v3.4._
*/
function functionDelegateCall(
address target,
bytes memory data,
string memory errorMessage
) internal returns (bytes memory) {
require(isContract(target), "Address: delegate call to non-contract");
(bool success, bytes memory returndata) = target.delegatecall(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the
* revert reason using the provided one.
*
* _Available since v4.3._
*/
function verifyCallResult(
bool success,
bytes memory returndata,
string memory errorMessage
) internal pure returns (bytes memory) {
if (success) {
return returndata;
} else {
// Look for revert reason and bubble it up if present
if (returndata.length > 0) {
// The easiest way to bubble the revert reason is using memory via assembly
/// @solidity memory-safe-assembly
assembly {
let returndata_size := mload(returndata)
revert(add(32, returndata), returndata_size)
}
} else {
revert(errorMessage);
}
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (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);
}
}{
"optimizer": {
"enabled": true,
"runs": 1000
},
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
},
"libraries": {}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[{"internalType":"address","name":"_minter","type":"address"},{"internalType":"address","name":"_staker","type":"address"},{"internalType":"address","name":"_vault","type":"address"},{"internalType":"address","name":"_exitFeeCollector","type":"address"},{"internalType":"address","name":"_whitelist","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"BAD_FEE","type":"error"},{"inputs":[],"name":"INVARIANT_VIOLATION","type":"error"},{"inputs":[],"name":"UNAUTHORIZED","type":"error"},{"inputs":[],"name":"UNDER_MIN_AMOUNT","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_user","type":"address"},{"indexed":false,"internalType":"uint256","name":"_assets","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_shares","type":"uint256"}],"name":"Deposited","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_new","type":"address"},{"indexed":false,"internalType":"address","name":"_old","type":"address"}],"name":"FeeCollectorUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_newFee","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_vaultRebate","type":"uint256"}],"name":"FeeUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_blockNumber","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_fsGLPSupply","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_plsGLPSupply","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_plvGLPSupply","type":"uint256"}],"name":"InvariantsViolated","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":false,"internalType":"address","name":"_partner","type":"address"},{"indexed":false,"internalType":"uint32","name":"_exitFee","type":"uint32"},{"indexed":false,"internalType":"uint32","name":"_rebate","type":"uint32"},{"indexed":false,"internalType":"bool","name":"_isActive","type":"bool"}],"name":"PartnerUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_new","type":"address"},{"indexed":false,"internalType":"address","name":"_old","type":"address"}],"name":"WhitelistUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_user","type":"address"},{"indexed":false,"internalType":"uint256","name":"_shares","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_assetsLessFee","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_vaultRebate","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_fee","type":"uint256"}],"name":"Withdrawed","type":"event"},{"inputs":[],"name":"defaultExitFee","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"defaultVaultRebate","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"depositAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_assets","type":"uint256"}],"name":"donate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"fsGLP","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_addr","type":"address"}],"name":"getFeeBp","outputs":[{"internalType":"uint256","name":"_exitFee","type":"uint256"},{"internalType":"uint256","name":"_rebate","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"minter","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_addr","type":"address"},{"internalType":"uint256","name":"_shares","type":"uint256"}],"name":"previewRedeem","outputs":[{"internalType":"uint256","name":"_exitFeeLessRebate","type":"uint256"},{"internalType":"uint256","name":"_rebateAmount","type":"uint256"},{"internalType":"uint256","name":"_assetsLessFee","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"redeem","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"redeemAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"token","type":"address"}],"name":"retrieve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"sGLP","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"_newFee","type":"uint32"},{"internalType":"uint32","name":"_vaultRebate","type":"uint32"}],"name":"setExitFee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_newFeeCollector","type":"address"}],"name":"setFeeCollector","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_pauseContract","type":"bool"}],"name":"setPaused","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_whitelist","type":"address"}],"name":"setWhitelist","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"staker","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_partnerAddr","type":"address"},{"internalType":"uint32","name":"_exitFee","type":"uint32"},{"internalType":"uint32","name":"_rebate","type":"uint32"},{"internalType":"bool","name":"_isActive","type":"bool"}],"name":"updatePartner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"vault","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"whitelist","outputs":[{"internalType":"contract IWhitelist","name":"","type":"address"}],"stateMutability":"view","type":"function"}]Contract Creation Code
60e06040523480156200001157600080fd5b50604051620020d4380380620020d48339810160408190526200003491620001d3565b6200003f3362000166565b6000805460ff60a01b191690556001600160a01b03858116608081905285821660a05284821660c0819052600180546001600160a01b0319168685161790556003805460c87fffffffff0000000000000000000000000000000000000000ffffffff00000000909116680100000000000000009587169590950263ffffffff1916949094179390931763ffffffff60201b19166509c4000000001790925560405163095ea7b360e01b8152600481019290925260001960248301529063095ea7b390604401602060405180830381600087803b1580156200011f57600080fd5b505af115801562000134573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200015a919062000243565b5050505050506200026e565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b80516001600160a01b0381168114620001ce57600080fd5b919050565b600080600080600060a08688031215620001ec57600080fd5b620001f786620001b6565b94506200020760208701620001b6565b93506200021760408701620001b6565b92506200022760608701620001b6565b91506200023760808701620001b6565b90509295509295909350565b6000602082840312156200025657600080fd5b815180151581146200026757600080fd5b9392505050565b60805160a05160c051611dbf6200031560003960008181610406015281816106cd01528181610ace01528181610d2b0152818161122101528181611363015281816114ce015261170801526000818161029901528181610cef0152818161113b0152818161150d0152818161155201526117c10152600081816101ad01528181610d5a0152818161117c015281816113fa015281816114ad01526117300152611dbf6000f3fe608060405234801561001057600080fd5b50600436106101a35760003560e01c8063854cff2f116100ee578063b6b55f2511610097578063de5f626811610071578063de5f6268146103d3578063f14faf6f146103db578063f2fde38b146103ee578063fbfa77cf1461040157600080fd5b8063b6b55f251461037f578063cbe52ae314610392578063db006a75146103c057600080fd5b8063a42dce80116100c8578063a42dce8014610329578063a8d774121461033c578063ace1487f1461035757600080fd5b8063854cff2f146102e65780638da5cb5b146102f957806393e59dc11461030a57600080fd5b80632f4350c211610150578063715018a61161012a578063715018a6146102bb5780637d655a5e146102c357806383418c4b146102d357600080fd5b80632f4350c21461026f5780635c975abb146102775780635ebaf1db1461029457600080fd5b8063103c5e1c11610181578063103c5e1c1461022e578063143d51f61461024157806316c38b3c1461025c57600080fd5b806307546172146101a85780630a79309b146101ec5780630f7327a114610201575b600080fd5b6101cf7f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020015b60405180910390f35b6101ff6101fa366004611b69565b610428565b005b60035461021990640100000000900463ffffffff1681565b60405163ffffffff90911681526020016101e3565b6101ff61023c366004611b9f565b6105c7565b6101cf731addd80e6039594ee970e5872d247bf0414c890381565b6101ff61026a366004611be0565b610693565b6101ff6106b4565b600054600160a01b900460ff1660405190151581526020016101e3565b6101cf7f000000000000000000000000000000000000000000000000000000000000000081565b6101ff610751565b6003546102199063ffffffff1681565b6101ff6102e1366004611bfd565b610763565b6101ff6102f4366004611b69565b61083b565b6000546001600160a01b03166101cf565b6003546101cf906801000000000000000090046001600160a01b031681565b6101ff610337366004611b69565b6108dd565b6101cf732f546ad4edd93b956c8999be404cdcafde3e89ae81565b61036a610365366004611b69565b61095b565b604080519283526020830191909152016101e3565b6101ff61038d366004611c55565b610a05565b6103a56103a0366004611c6e565b610a1f565b604080519384526020840192909252908201526060016101e3565b6101ff6103ce366004611c55565b610b8f565b6101ff610c4e565b6101ff6103e9366004611c55565b610cd4565b6101ff6103fc366004611b69565b610db9565b6101cf7f000000000000000000000000000000000000000000000000000000000000000081565b610430610e4b565b4715610495576000546001600160a01b03166001600160a01b03164760405160006040518083038185875af1925050503d806000811461048c576040519150601f19603f3d011682016040523d82523d6000602084013e610491565b606091505b5050505b806001600160a01b031663a9059cbb6104b66000546001600160a01b031690565b6040516370a0823160e01b81523060048201526001600160a01b038516906370a082319060240160206040518083038186803b1580156104f557600080fd5b505afa158015610509573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061052d9190611c9a565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b1681526001600160a01b0390921660048301526024820152604401602060405180830381600087803b15801561058b57600080fd5b505af115801561059f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105c39190611cb3565b5050565b6105cf610e4b565b6127108263ffffffff1611806105ec57506127108163ffffffff16115b15610623576040517f49cefafe00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805163ffffffff8085168252831660208201527f528d9479e9f9889a87a3c30c7f7ba537e5e59c4c85a37733b16e57c62df61302910160405180910390a16003805463ffffffff9283166401000000000267ffffffffffffffff199091169290931691909117919091179055565b61069b610e4b565b80156106ac576106a9610ea5565b50565b6106a9610f05565b6040516370a0823160e01b815233600482015261074f907f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316906370a082319060240160206040518083038186803b15801561071757600080fd5b505afa15801561072b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103ce9190611c9a565b565b610759610e4b565b61074f6000610f41565b61076b610e4b565b604080516060808201835283151580835263ffffffff87811660208086018281528984168789018181526001600160a01b038e166000818152600286528b902099518a549451925164ffffffffff1990951690151564ffffffff00191617610100928816929092029190911768ffffffff00000000001916650100000000009390961692909202949094179096558651958652850152838501529082015290517fed29f66bf0ad62d28362b3cb5c228127062feffd8fc91b5a169d55e3cee129229181900360800190a150505050565b610843610e4b565b600354604080516001600160a01b0380851682526801000000000000000090930490921660208301527f0b00a1112524b562c52fd702a5b927f07a0b1bafa6243b83cf3b78a9316bb1a7910160405180910390a1600380546001600160a01b0390921668010000000000000000027fffffffff0000000000000000000000000000000000000000ffffffffffffffff909216919091179055565b6108e5610e4b565b600154604080516001600160a01b03808516825290921660208301527f5d16ad41baeb009cd23eb8f6c7cde5c2e0cd5acf4a33926ab488875c37c37f38910160405180910390a16001805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b6001600160a01b03811660009081526002602090815260408083208151606081018352905460ff8116151580835263ffffffff6101008304811695840195909552650100000000009091049093169181019190915282916109c45760035463ffffffff166109ca565b80602001515b63ffffffff16925080600001516109f157600354640100000000900463ffffffff166109f7565b80604001515b63ffffffff16915050915091565b610a0d610f9e565b610a15610ff8565b6106a933826110f7565b6001600160a01b03821660009081526002602090815260408083208151606081018352905460ff8116151580835263ffffffff6101008304811695840195909552650100000000009091049093169181019190915282918291908290610a8d5760035463ffffffff16610a93565b81602001515b63ffffffff16905060008260000151610abc57600354640100000000900463ffffffff16610ac2565b82604001515b63ffffffff16905060007f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316634cdad506896040518263ffffffff1660e01b8152600401610b1a91815260200190565b60206040518083038186803b158015610b3257600080fd5b505afa158015610b46573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b6a9190611c9a565b612710938102849004928302939093048083039a909950919092039650945050505050565b610b97610f9e565b610b9f610ff8565b3360009081526002602090815260408083208151606081018352905460ff8116151580835263ffffffff610100830481169584019590955265010000000000909104909316918101919091529190610bff5760035463ffffffff16610c05565b81602001515b63ffffffff16905060008260000151610c2e57600354640100000000900463ffffffff16610c34565b82604001515b63ffffffff169050610c48338584846112f2565b50505050565b6040516370a0823160e01b815233600482015261074f90731addd80e6039594ee970e5872d247bf0414c8903906370a082319060240160206040518083038186803b158015610c9c57600080fd5b505afa158015610cb0573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061038d9190611c9a565b610d14732f546ad4edd93b956c8999be404cdcafde3e89ae337f0000000000000000000000000000000000000000000000000000000000000000846115e7565b6040516340c10f1960e01b81526001600160a01b037f000000000000000000000000000000000000000000000000000000000000000081166004830152602482018390527f000000000000000000000000000000000000000000000000000000000000000016906340c10f1990604401600060405180830381600087803b158015610d9e57600080fd5b505af1158015610db2573d6000803e3d6000fd5b5050505050565b610dc1610e4b565b6001600160a01b038116610e425760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084015b60405180910390fd5b6106a981610f41565b6000546001600160a01b0316331461074f5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610e39565b610ead610f9e565b6000805460ff60a01b1916600160a01b1790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258610ee83390565b6040516001600160a01b03909116815260200160405180910390a1565b610f0d611698565b6000805460ff60a01b191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa33610ee8565b600080546001600160a01b0383811673ffffffffffffffffffffffffffffffffffffffff19831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b600054600160a01b900460ff161561074f5760405162461bcd60e51b815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610e39565b3332148015906110a457506003546040517f3af32abf000000000000000000000000000000000000000000000000000000008152336004820152680100000000000000009091046001600160a01b031690633af32abf9060240160206040518083038186803b15801561106a57600080fd5b505afa15801561107e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110a29190611cb3565b155b80156110c057503360009081526002602052604090205460ff16155b1561074f576040517f075fd2b100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b670de0b6b3a7640000811015611120576040516358ae113960e01b815260040160405180910390fd5b611160732f546ad4edd93b956c8999be404cdcafde3e89ae837f0000000000000000000000000000000000000000000000000000000000000000846115e7565b6040516340c10f1960e01b8152306004820152602481018290527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316906340c10f1990604401600060405180830381600087803b1580156111c857600080fd5b505af11580156111dc573d6000803e3d6000fd5b50506040517f6e553f65000000000000000000000000000000000000000000000000000000008152600481018490526001600160a01b038581166024830152600093507f0000000000000000000000000000000000000000000000000000000000000000169150636e553f6590604401602060405180830381600087803b15801561126657600080fd5b505af115801561127a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061129e9190611c9a565b60408051848152602081018390529192506001600160a01b038516917f73a19dd210f1a7f902193214c0ee91dd35ee5b4d920cba8d519eca65a7b488ca910160405180910390a26112ed6116f1565b505050565b670de0b6b3a764000083101561131b576040516358ae113960e01b815260040160405180910390fd5b6040517fba087652000000000000000000000000000000000000000000000000000000008152600481018490523060248201526001600160a01b0385811660448301526000917f00000000000000000000000000000000000000000000000000000000000000009091169063ba08765290606401602060405180830381600087803b1580156113a957600080fd5b505af11580156113bd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113e19190611c9a565b90506127108382028190049081830390848302048083037f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316639dc29fac306114328589611cd0565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b1681526001600160a01b0390921660048301526024820152604401600060405180830381600087803b15801561149057600080fd5b505af11580156114a4573d6000803e3d6000fd5b505050506114f37f00000000000000000000000000000000000000000000000000000000000000007f00000000000000000000000000000000000000000000000000000000000000008461188c565b611533732f546ad4edd93b956c8999be404cdcafde3e89ae7f00000000000000000000000000000000000000000000000000000000000000008b866115e7565b60015461158190732f546ad4edd93b956c8999be404cdcafde3e89ae907f0000000000000000000000000000000000000000000000000000000000000000906001600160a01b0316846115e7565b6040805189815260208101859052908101839052606081018290526001600160a01b038a16907fd0e963b9659aaed7d09a087716c4bda20404e056037b8a879d057cc0748a78de9060800160405180910390a26115dc6116f1565b505050505050505050565b6040516001600160a01b0380851660248301528316604482015260648101829052610c489085907f23b872dd00000000000000000000000000000000000000000000000000000000906084015b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000909316929092179091526118d5565b600054600160a01b900460ff1661074f5760405162461bcd60e51b815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610e39565b6040516370a0823160e01b81526001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000811660048301527f000000000000000000000000000000000000000000000000000000000000000016906370a082319060240160206040518083038186803b15801561177257600080fd5b505afa158015611786573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117aa9190611c9a565b6040516370a0823160e01b81526001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000166004820152731addd80e6039594ee970e5872d247bf0414c8903906370a082319060240160206040518083038186803b15801561181d57600080fd5b505afa158015611831573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118559190611c9a565b1461074f576040517f5a824c0300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040516001600160a01b0383166024820152604481018290526112ed9084907fa9059cbb0000000000000000000000000000000000000000000000000000000090606401611634565b600061192a826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166119ba9092919063ffffffff16565b8051909150156112ed57808060200190518101906119489190611cb3565b6112ed5760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f742073756363656564000000000000000000000000000000000000000000006064820152608401610e39565b60606119c984846000856119d3565b90505b9392505050565b606082471015611a4b5760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c00000000000000000000000000000000000000000000000000006064820152608401610e39565b6001600160a01b0385163b611aa25760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610e39565b600080866001600160a01b03168587604051611abe9190611d3a565b60006040518083038185875af1925050503d8060008114611afb576040519150601f19603f3d011682016040523d82523d6000602084013e611b00565b606091505b5091509150611b10828286611b1b565b979650505050505050565b60608315611b2a5750816119cc565b825115611b3a5782518084602001fd5b8160405162461bcd60e51b8152600401610e399190611d56565b6001600160a01b03811681146106a957600080fd5b600060208284031215611b7b57600080fd5b81356119cc81611b54565b803563ffffffff81168114611b9a57600080fd5b919050565b60008060408385031215611bb257600080fd5b611bbb83611b86565b9150611bc960208401611b86565b90509250929050565b80151581146106a957600080fd5b600060208284031215611bf257600080fd5b81356119cc81611bd2565b60008060008060808587031215611c1357600080fd5b8435611c1e81611b54565b9350611c2c60208601611b86565b9250611c3a60408601611b86565b91506060850135611c4a81611bd2565b939692955090935050565b600060208284031215611c6757600080fd5b5035919050565b60008060408385031215611c8157600080fd5b8235611c8c81611b54565b946020939093013593505050565b600060208284031215611cac57600080fd5b5051919050565b600060208284031215611cc557600080fd5b81516119cc81611bd2565b600082821015611d09577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b500390565b60005b83811015611d29578181015183820152602001611d11565b83811115610c485750506000910152565b60008251611d4c818460208701611d0e565b9190910192915050565b6020815260008251806020840152611d75816040850160208701611d0e565b601f01601f1916919091016040019291505056fea2646970667358221220e67c824e3aee16c04a63e94a2e23109596051fd150a64e5fa36dbd47cb6bc51564736f6c63430008090033000000000000000000000000530f1cbb2ebd71bec58d351dcd3768148986a467000000000000000000000000bec7635c7a475cbe081698ea110ef411e40f8dd90000000000000000000000005326e71ff593ecc2cf7acae5fe57582d6e74cff100000000000000000000000084d152e8cb68a94ebcf50ce6f17af7f2c1f891eb000000000000000000000000440b15954545fe2590a3693cffe1f2b132891f61
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106101a35760003560e01c8063854cff2f116100ee578063b6b55f2511610097578063de5f626811610071578063de5f6268146103d3578063f14faf6f146103db578063f2fde38b146103ee578063fbfa77cf1461040157600080fd5b8063b6b55f251461037f578063cbe52ae314610392578063db006a75146103c057600080fd5b8063a42dce80116100c8578063a42dce8014610329578063a8d774121461033c578063ace1487f1461035757600080fd5b8063854cff2f146102e65780638da5cb5b146102f957806393e59dc11461030a57600080fd5b80632f4350c211610150578063715018a61161012a578063715018a6146102bb5780637d655a5e146102c357806383418c4b146102d357600080fd5b80632f4350c21461026f5780635c975abb146102775780635ebaf1db1461029457600080fd5b8063103c5e1c11610181578063103c5e1c1461022e578063143d51f61461024157806316c38b3c1461025c57600080fd5b806307546172146101a85780630a79309b146101ec5780630f7327a114610201575b600080fd5b6101cf7f000000000000000000000000530f1cbb2ebd71bec58d351dcd3768148986a46781565b6040516001600160a01b0390911681526020015b60405180910390f35b6101ff6101fa366004611b69565b610428565b005b60035461021990640100000000900463ffffffff1681565b60405163ffffffff90911681526020016101e3565b6101ff61023c366004611b9f565b6105c7565b6101cf731addd80e6039594ee970e5872d247bf0414c890381565b6101ff61026a366004611be0565b610693565b6101ff6106b4565b600054600160a01b900460ff1660405190151581526020016101e3565b6101cf7f000000000000000000000000bec7635c7a475cbe081698ea110ef411e40f8dd981565b6101ff610751565b6003546102199063ffffffff1681565b6101ff6102e1366004611bfd565b610763565b6101ff6102f4366004611b69565b61083b565b6000546001600160a01b03166101cf565b6003546101cf906801000000000000000090046001600160a01b031681565b6101ff610337366004611b69565b6108dd565b6101cf732f546ad4edd93b956c8999be404cdcafde3e89ae81565b61036a610365366004611b69565b61095b565b604080519283526020830191909152016101e3565b6101ff61038d366004611c55565b610a05565b6103a56103a0366004611c6e565b610a1f565b604080519384526020840192909252908201526060016101e3565b6101ff6103ce366004611c55565b610b8f565b6101ff610c4e565b6101ff6103e9366004611c55565b610cd4565b6101ff6103fc366004611b69565b610db9565b6101cf7f0000000000000000000000005326e71ff593ecc2cf7acae5fe57582d6e74cff181565b610430610e4b565b4715610495576000546001600160a01b03166001600160a01b03164760405160006040518083038185875af1925050503d806000811461048c576040519150601f19603f3d011682016040523d82523d6000602084013e610491565b606091505b5050505b806001600160a01b031663a9059cbb6104b66000546001600160a01b031690565b6040516370a0823160e01b81523060048201526001600160a01b038516906370a082319060240160206040518083038186803b1580156104f557600080fd5b505afa158015610509573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061052d9190611c9a565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b1681526001600160a01b0390921660048301526024820152604401602060405180830381600087803b15801561058b57600080fd5b505af115801561059f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105c39190611cb3565b5050565b6105cf610e4b565b6127108263ffffffff1611806105ec57506127108163ffffffff16115b15610623576040517f49cefafe00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805163ffffffff8085168252831660208201527f528d9479e9f9889a87a3c30c7f7ba537e5e59c4c85a37733b16e57c62df61302910160405180910390a16003805463ffffffff9283166401000000000267ffffffffffffffff199091169290931691909117919091179055565b61069b610e4b565b80156106ac576106a9610ea5565b50565b6106a9610f05565b6040516370a0823160e01b815233600482015261074f907f0000000000000000000000005326e71ff593ecc2cf7acae5fe57582d6e74cff16001600160a01b0316906370a082319060240160206040518083038186803b15801561071757600080fd5b505afa15801561072b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103ce9190611c9a565b565b610759610e4b565b61074f6000610f41565b61076b610e4b565b604080516060808201835283151580835263ffffffff87811660208086018281528984168789018181526001600160a01b038e166000818152600286528b902099518a549451925164ffffffffff1990951690151564ffffffff00191617610100928816929092029190911768ffffffff00000000001916650100000000009390961692909202949094179096558651958652850152838501529082015290517fed29f66bf0ad62d28362b3cb5c228127062feffd8fc91b5a169d55e3cee129229181900360800190a150505050565b610843610e4b565b600354604080516001600160a01b0380851682526801000000000000000090930490921660208301527f0b00a1112524b562c52fd702a5b927f07a0b1bafa6243b83cf3b78a9316bb1a7910160405180910390a1600380546001600160a01b0390921668010000000000000000027fffffffff0000000000000000000000000000000000000000ffffffffffffffff909216919091179055565b6108e5610e4b565b600154604080516001600160a01b03808516825290921660208301527f5d16ad41baeb009cd23eb8f6c7cde5c2e0cd5acf4a33926ab488875c37c37f38910160405180910390a16001805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b6001600160a01b03811660009081526002602090815260408083208151606081018352905460ff8116151580835263ffffffff6101008304811695840195909552650100000000009091049093169181019190915282916109c45760035463ffffffff166109ca565b80602001515b63ffffffff16925080600001516109f157600354640100000000900463ffffffff166109f7565b80604001515b63ffffffff16915050915091565b610a0d610f9e565b610a15610ff8565b6106a933826110f7565b6001600160a01b03821660009081526002602090815260408083208151606081018352905460ff8116151580835263ffffffff6101008304811695840195909552650100000000009091049093169181019190915282918291908290610a8d5760035463ffffffff16610a93565b81602001515b63ffffffff16905060008260000151610abc57600354640100000000900463ffffffff16610ac2565b82604001515b63ffffffff16905060007f0000000000000000000000005326e71ff593ecc2cf7acae5fe57582d6e74cff16001600160a01b0316634cdad506896040518263ffffffff1660e01b8152600401610b1a91815260200190565b60206040518083038186803b158015610b3257600080fd5b505afa158015610b46573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b6a9190611c9a565b612710938102849004928302939093048083039a909950919092039650945050505050565b610b97610f9e565b610b9f610ff8565b3360009081526002602090815260408083208151606081018352905460ff8116151580835263ffffffff610100830481169584019590955265010000000000909104909316918101919091529190610bff5760035463ffffffff16610c05565b81602001515b63ffffffff16905060008260000151610c2e57600354640100000000900463ffffffff16610c34565b82604001515b63ffffffff169050610c48338584846112f2565b50505050565b6040516370a0823160e01b815233600482015261074f90731addd80e6039594ee970e5872d247bf0414c8903906370a082319060240160206040518083038186803b158015610c9c57600080fd5b505afa158015610cb0573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061038d9190611c9a565b610d14732f546ad4edd93b956c8999be404cdcafde3e89ae337f000000000000000000000000bec7635c7a475cbe081698ea110ef411e40f8dd9846115e7565b6040516340c10f1960e01b81526001600160a01b037f0000000000000000000000005326e71ff593ecc2cf7acae5fe57582d6e74cff181166004830152602482018390527f000000000000000000000000530f1cbb2ebd71bec58d351dcd3768148986a46716906340c10f1990604401600060405180830381600087803b158015610d9e57600080fd5b505af1158015610db2573d6000803e3d6000fd5b5050505050565b610dc1610e4b565b6001600160a01b038116610e425760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084015b60405180910390fd5b6106a981610f41565b6000546001600160a01b0316331461074f5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610e39565b610ead610f9e565b6000805460ff60a01b1916600160a01b1790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258610ee83390565b6040516001600160a01b03909116815260200160405180910390a1565b610f0d611698565b6000805460ff60a01b191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa33610ee8565b600080546001600160a01b0383811673ffffffffffffffffffffffffffffffffffffffff19831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b600054600160a01b900460ff161561074f5760405162461bcd60e51b815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610e39565b3332148015906110a457506003546040517f3af32abf000000000000000000000000000000000000000000000000000000008152336004820152680100000000000000009091046001600160a01b031690633af32abf9060240160206040518083038186803b15801561106a57600080fd5b505afa15801561107e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110a29190611cb3565b155b80156110c057503360009081526002602052604090205460ff16155b1561074f576040517f075fd2b100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b670de0b6b3a7640000811015611120576040516358ae113960e01b815260040160405180910390fd5b611160732f546ad4edd93b956c8999be404cdcafde3e89ae837f000000000000000000000000bec7635c7a475cbe081698ea110ef411e40f8dd9846115e7565b6040516340c10f1960e01b8152306004820152602481018290527f000000000000000000000000530f1cbb2ebd71bec58d351dcd3768148986a4676001600160a01b0316906340c10f1990604401600060405180830381600087803b1580156111c857600080fd5b505af11580156111dc573d6000803e3d6000fd5b50506040517f6e553f65000000000000000000000000000000000000000000000000000000008152600481018490526001600160a01b038581166024830152600093507f0000000000000000000000005326e71ff593ecc2cf7acae5fe57582d6e74cff1169150636e553f6590604401602060405180830381600087803b15801561126657600080fd5b505af115801561127a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061129e9190611c9a565b60408051848152602081018390529192506001600160a01b038516917f73a19dd210f1a7f902193214c0ee91dd35ee5b4d920cba8d519eca65a7b488ca910160405180910390a26112ed6116f1565b505050565b670de0b6b3a764000083101561131b576040516358ae113960e01b815260040160405180910390fd5b6040517fba087652000000000000000000000000000000000000000000000000000000008152600481018490523060248201526001600160a01b0385811660448301526000917f0000000000000000000000005326e71ff593ecc2cf7acae5fe57582d6e74cff19091169063ba08765290606401602060405180830381600087803b1580156113a957600080fd5b505af11580156113bd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113e19190611c9a565b90506127108382028190049081830390848302048083037f000000000000000000000000530f1cbb2ebd71bec58d351dcd3768148986a4676001600160a01b0316639dc29fac306114328589611cd0565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b1681526001600160a01b0390921660048301526024820152604401600060405180830381600087803b15801561149057600080fd5b505af11580156114a4573d6000803e3d6000fd5b505050506114f37f000000000000000000000000530f1cbb2ebd71bec58d351dcd3768148986a4677f0000000000000000000000005326e71ff593ecc2cf7acae5fe57582d6e74cff18461188c565b611533732f546ad4edd93b956c8999be404cdcafde3e89ae7f000000000000000000000000bec7635c7a475cbe081698ea110ef411e40f8dd98b866115e7565b60015461158190732f546ad4edd93b956c8999be404cdcafde3e89ae907f000000000000000000000000bec7635c7a475cbe081698ea110ef411e40f8dd9906001600160a01b0316846115e7565b6040805189815260208101859052908101839052606081018290526001600160a01b038a16907fd0e963b9659aaed7d09a087716c4bda20404e056037b8a879d057cc0748a78de9060800160405180910390a26115dc6116f1565b505050505050505050565b6040516001600160a01b0380851660248301528316604482015260648101829052610c489085907f23b872dd00000000000000000000000000000000000000000000000000000000906084015b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000909316929092179091526118d5565b600054600160a01b900460ff1661074f5760405162461bcd60e51b815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610e39565b6040516370a0823160e01b81526001600160a01b037f0000000000000000000000005326e71ff593ecc2cf7acae5fe57582d6e74cff1811660048301527f000000000000000000000000530f1cbb2ebd71bec58d351dcd3768148986a46716906370a082319060240160206040518083038186803b15801561177257600080fd5b505afa158015611786573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117aa9190611c9a565b6040516370a0823160e01b81526001600160a01b037f000000000000000000000000bec7635c7a475cbe081698ea110ef411e40f8dd9166004820152731addd80e6039594ee970e5872d247bf0414c8903906370a082319060240160206040518083038186803b15801561181d57600080fd5b505afa158015611831573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118559190611c9a565b1461074f576040517f5a824c0300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040516001600160a01b0383166024820152604481018290526112ed9084907fa9059cbb0000000000000000000000000000000000000000000000000000000090606401611634565b600061192a826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166119ba9092919063ffffffff16565b8051909150156112ed57808060200190518101906119489190611cb3565b6112ed5760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f742073756363656564000000000000000000000000000000000000000000006064820152608401610e39565b60606119c984846000856119d3565b90505b9392505050565b606082471015611a4b5760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c00000000000000000000000000000000000000000000000000006064820152608401610e39565b6001600160a01b0385163b611aa25760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610e39565b600080866001600160a01b03168587604051611abe9190611d3a565b60006040518083038185875af1925050503d8060008114611afb576040519150601f19603f3d011682016040523d82523d6000602084013e611b00565b606091505b5091509150611b10828286611b1b565b979650505050505050565b60608315611b2a5750816119cc565b825115611b3a5782518084602001fd5b8160405162461bcd60e51b8152600401610e399190611d56565b6001600160a01b03811681146106a957600080fd5b600060208284031215611b7b57600080fd5b81356119cc81611b54565b803563ffffffff81168114611b9a57600080fd5b919050565b60008060408385031215611bb257600080fd5b611bbb83611b86565b9150611bc960208401611b86565b90509250929050565b80151581146106a957600080fd5b600060208284031215611bf257600080fd5b81356119cc81611bd2565b60008060008060808587031215611c1357600080fd5b8435611c1e81611b54565b9350611c2c60208601611b86565b9250611c3a60408601611b86565b91506060850135611c4a81611bd2565b939692955090935050565b600060208284031215611c6757600080fd5b5035919050565b60008060408385031215611c8157600080fd5b8235611c8c81611b54565b946020939093013593505050565b600060208284031215611cac57600080fd5b5051919050565b600060208284031215611cc557600080fd5b81516119cc81611bd2565b600082821015611d09577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b500390565b60005b83811015611d29578181015183820152602001611d11565b83811115610c485750506000910152565b60008251611d4c818460208701611d0e565b9190910192915050565b6020815260008251806020840152611d75816040850160208701611d0e565b601f01601f1916919091016040019291505056fea2646970667358221220e67c824e3aee16c04a63e94a2e23109596051fd150a64e5fa36dbd47cb6bc51564736f6c63430008090033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000530f1cbb2ebd71bec58d351dcd3768148986a467000000000000000000000000bec7635c7a475cbe081698ea110ef411e40f8dd90000000000000000000000005326e71ff593ecc2cf7acae5fe57582d6e74cff100000000000000000000000084d152e8cb68a94ebcf50ce6f17af7f2c1f891eb000000000000000000000000440b15954545fe2590a3693cffe1f2b132891f61
-----Decoded View---------------
Arg [0] : _minter (address): 0x530F1CbB2ebD71bec58D351DCD3768148986A467
Arg [1] : _staker (address): 0xbec7635c7A475CbE081698ea110eF411e40f8dd9
Arg [2] : _vault (address): 0x5326E71Ff593Ecc2CF7AcaE5Fe57582D6e74CFF1
Arg [3] : _exitFeeCollector (address): 0x84D152e8Cb68a94ebCf50cE6F17Af7F2c1F891EB
Arg [4] : _whitelist (address): 0x440B15954545FE2590a3693cFFE1F2b132891f61
-----Encoded View---------------
5 Constructor Arguments found :
Arg [0] : 000000000000000000000000530f1cbb2ebd71bec58d351dcd3768148986a467
Arg [1] : 000000000000000000000000bec7635c7a475cbe081698ea110ef411e40f8dd9
Arg [2] : 0000000000000000000000005326e71ff593ecc2cf7acae5fe57582d6e74cff1
Arg [3] : 00000000000000000000000084d152e8cb68a94ebcf50ce6f17af7f2c1f891eb
Arg [4] : 000000000000000000000000440b15954545fe2590a3693cffe1f2b132891f61
Multichain Portfolio | 34 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|
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.