Source Code
Latest 25 from a total of 1,602 transactions
| Transaction Hash |
|
Block
|
From
|
To
|
|||||
|---|---|---|---|---|---|---|---|---|---|
| Zap | 41302466 | 1 hr ago | IN | 0.001 ETH | 0.00000785 | ||||
| Zap | 41302444 | 1 hr ago | IN | 0.001 ETH | 0.00000852 | ||||
| Zap | 41298048 | 3 hrs ago | IN | 0.00007 ETH | 0.00000257 | ||||
| Zap | 41289964 | 8 hrs ago | IN | 0.001 ETH | 0.0003114 | ||||
| Zap | 41267675 | 20 hrs ago | IN | 0.001 ETH | 0.00000194 | ||||
| Zap | 41265038 | 22 hrs ago | IN | 0.0005 ETH | 0.00000229 | ||||
| Zap | 41260033 | 25 hrs ago | IN | 0.00004 ETH | 0.00000265 | ||||
| Zap | 41258317 | 25 hrs ago | IN | 0.000085 ETH | 0.00000344 | ||||
| Zap | 41257706 | 26 hrs ago | IN | 0.00001 ETH | 0.0000035 | ||||
| Zap | 41257634 | 26 hrs ago | IN | 0.0001 ETH | 0.00000305 | ||||
| Zap | 41257020 | 26 hrs ago | IN | 0.00001 ETH | 0.00000228 | ||||
| Zap | 41255333 | 27 hrs ago | IN | 0.001 ETH | 0.00000224 | ||||
| Zap | 41255054 | 27 hrs ago | IN | 0.001 ETH | 0.0000022 | ||||
| Zap | 41251896 | 29 hrs ago | IN | 0.00004 ETH | 0.00000151 | ||||
| Zap | 41250861 | 30 hrs ago | IN | 0.0001 ETH | 0.00000244 | ||||
| Zap | 41250193 | 30 hrs ago | IN | 0.0001 ETH | 0.00000354 | ||||
| Zap | 41246332 | 32 hrs ago | IN | 0.00005 ETH | 0.00000227 | ||||
| Zap | 41243670 | 34 hrs ago | IN | 0.001 ETH | 0.0000032 | ||||
| Zap | 41243659 | 34 hrs ago | IN | 0.001 ETH | 0.00000338 | ||||
| Zap | 41240356 | 35 hrs ago | IN | 0.00007 ETH | 0.00000305 | ||||
| Zap | 41240195 | 36 hrs ago | IN | 0.00005 ETH | 0.00000366 | ||||
| Zap | 41232697 | 40 hrs ago | IN | 0.00011 ETH | 0.00000198 | ||||
| Zap | 41220069 | 47 hrs ago | IN | 0.0037 ETH | 0.00000171 | ||||
| Zap | 41219965 | 47 hrs ago | IN | 0.0003 ETH | 0.00000177 | ||||
| Zap | 41219927 | 47 hrs ago | IN | 0.004 ETH | 0.00000175 |
Latest 25 internal transactions (View All)
| Parent Transaction Hash | Block | From | To | |||
|---|---|---|---|---|---|---|
| 41302466 | 1 hr ago | 0.001 ETH | ||||
| 41302444 | 1 hr ago | 0.001 ETH | ||||
| 41301006 | 2 hrs ago | 0.001 ETH | ||||
| 41301006 | 2 hrs ago | 0.001 ETH | ||||
| 41298048 | 3 hrs ago | 0.00007 ETH | ||||
| 41289964 | 8 hrs ago | 0.001 ETH | ||||
| 41267675 | 20 hrs ago | 0.001 ETH | ||||
| 41265038 | 22 hrs ago | 0.0005 ETH | ||||
| 41260033 | 25 hrs ago | 0.00004 ETH | ||||
| 41258317 | 25 hrs ago | 0.000085 ETH | ||||
| 41257706 | 26 hrs ago | 0.00001 ETH | ||||
| 41257634 | 26 hrs ago | 0.0001 ETH | ||||
| 41257020 | 26 hrs ago | 0.00001 ETH | ||||
| 41255333 | 27 hrs ago | 0.001 ETH | ||||
| 41255054 | 27 hrs ago | 0.001 ETH | ||||
| 41251896 | 29 hrs ago | 0.00004 ETH | ||||
| 41250861 | 30 hrs ago | 0.0001 ETH | ||||
| 41250193 | 30 hrs ago | 0.0001 ETH | ||||
| 41246332 | 32 hrs ago | 0.00005 ETH | ||||
| 41243670 | 34 hrs ago | 0.001 ETH | ||||
| 41243659 | 34 hrs ago | 0.001 ETH | ||||
| 41240356 | 35 hrs ago | 0.00007 ETH | ||||
| 41240195 | 36 hrs ago | 0.00005 ETH | ||||
| 41232697 | 40 hrs ago | 0.00011 ETH | ||||
| 41220069 | 47 hrs ago | 0.0037 ETH |
Cross-Chain Transactions
Loading...
Loading
Contract Name:
StremeZapDual
Compiler Version
v0.8.26+commit.8a97fa7a
Optimization Enabled:
Yes with 2000 runs
Other Settings:
paris EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.25;
pragma abicoder v2;
import {ERC20, IERC20} from "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "./interfaces/Path.sol";
interface ISwapRouter {
struct ExactInputSingleParams {
address tokenIn;
address tokenOut;
uint24 fee;
address recipient;
uint256 amountIn;
uint256 amountOutMinimum;
uint160 sqrtPriceLimitX96;
}
function exactInputSingle(ExactInputSingleParams calldata params) external payable returns (uint256 amountOut);
}
interface IWETH9 is IERC20 {
function deposit() external payable;
function withdraw(uint256 wad) external;
function transfer(address to, uint256 value) external returns (bool);
}
interface ISETH is IERC20 {
function upgradeByETH() external payable;
function upgradeByETHTo(address to) external payable;
function downgradeToETH(uint wad) external;
}
interface IStremeStaking {
function stake(address to, uint256 amount) external;
}
interface ICLPoolFactory {
function getPool(address tokenA, address tokenB, int24 tickSpacing) external view returns (address pool);
}
interface ILPFactoryAero {
function pool(address token) external view returns (address);
}
interface ICLPool {
function swap(
address recipient,
bool zeroForOne,
int256 amountSpecified,
uint160 sqrtPriceLimitX96,
bytes calldata data
) external returns (int256 amount0, int256 amount1);
function token0() external view returns (address);
function token1() external view returns (address);
}
contract StremeZapDual {
using Path for bytes;
ISwapRouter public immutable uniSwapRouter;
address public weth;
address public ethx;
uint24 public constant uniPoolFee = 10000;
int24 public constant aeroTickSpacing = 500;
ILPFactoryAero public lpFactoryAero;
struct SwapCallbackData {
bytes path;
address payer;
}
/// @dev The maximum value that can be returned from #getSqrtRatioAtTick. Equivalent to getSqrtRatioAtTick(MAX_TICK)
uint160 internal constant MAX_SQRT_RATIO = 1461446703485210103287273052203988822378723970342;
constructor(ISwapRouter _swapRouter, address _weth, address _ethx, ILPFactoryAero _lpFactoryAero) {
uniSwapRouter = _swapRouter;
weth = _weth;
ethx = _ethx;
lpFactoryAero = _lpFactoryAero;
ISETH(ethx).approve(address(uniSwapRouter), type(uint256).max);
}
function zap(address stremeCoin, uint256 amountIn, uint256 amountOutMin, address stakingContract) external payable returns (uint256 amountOut) {
require(msg.value == amountIn, "msg.value must be equal to amountIn");
address recipient = (stakingContract != address(0)) ? address(this) : msg.sender;
address aeroPool = lpFactoryAero.pool(stremeCoin);
if (aeroPool != address(0)) {
amountOut = _aeroZap(weth, stremeCoin, amountIn, amountOutMin, recipient, aeroPool);
} else {
amountOut = _uniZap(weth, stremeCoin, amountIn, amountOutMin, recipient);
}
if (stakingContract != address(0)) {
// approve the staking contract to spend the amountOut:
IERC20(stremeCoin).approve(stakingContract, amountOut);
IStremeStaking(stakingContract).stake(msg.sender, amountOut);
}
}
function zapETHx(address stremeCoin, uint256 amountIn, uint256 amountOutMin, address stakingContract) external payable returns (uint256 amountOut) {
require(msg.value == amountIn, "msg.value must be equal to amountIn");
ISETH(ethx).upgradeByETH{value: msg.value}();
address recipient = (stakingContract != address(0)) ? address(this) : msg.sender;
address aeroPool = lpFactoryAero.pool(stremeCoin);
if (aeroPool != address(0)) {
amountOut = _aeroZap(ethx, stremeCoin, amountIn, amountOutMin, recipient, aeroPool);
} else {
amountOut = _uniZap(ethx, stremeCoin, amountIn, amountOutMin, recipient);
}
if (stakingContract != address(0)) {
// approve the staking contract to spend the amountOut:
IERC20(stremeCoin).approve(stakingContract, amountOut);
IStremeStaking(stakingContract).stake(msg.sender, amountOut);
}
}
function _uniZap(address tokenIn, address tokenOut, uint256 amountIn, uint256 amountOutMin, address recipient) internal returns (uint256 amountOut) {
ISwapRouter.ExactInputSingleParams memory params =
ISwapRouter.ExactInputSingleParams({
tokenIn: tokenIn,
tokenOut: tokenOut,
fee: uniPoolFee,
recipient: recipient,
amountIn: amountIn,
amountOutMinimum: amountOutMin,
sqrtPriceLimitX96: 0
});
amountOut = uniSwapRouter.exactInputSingle{value: msg.value}(params);
}
function _aeroZap(address tokenIn, address stremeCoin, uint256 amountIn, uint256 amountOutMin, address recipient, address pool) internal returns (uint256 amountOut) {
bytes memory path = abi.encodePacked(tokenIn, aeroTickSpacing, stremeCoin);
SwapCallbackData memory data = SwapCallbackData({
path: path,
payer: msg.sender
});
(int256 amount0, ) = ICLPool(pool).swap(
recipient,
false,
int256(amountIn),
MAX_SQRT_RATIO - 1,
abi.encode(data)
);
amountOut = uint256(-(amount0));
require(amountOut >= amountOutMin, "Too little received");
}
function uniswapV3SwapCallback(int256 amount0Delta, int256 amount1Delta, bytes calldata _data) external {
require(amount0Delta > 0 || amount1Delta > 0); // swaps entirely within 0-liquidity regions are not supported
SwapCallbackData memory data = abi.decode(_data, (SwapCallbackData));
( , address tokenOut, ) = data.path.decodeFirstPool();
address pool = lpFactoryAero.pool(tokenOut);
require(msg.sender == pool, "Callback only from pool");
if (address(this).balance >= uint256(amount1Delta)) {
IWETH9(weth).deposit{value: uint256(amount1Delta)}();
}
IWETH9(weth).transfer(msg.sender, uint256(amount1Delta));
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (interfaces/draft-IERC6093.sol)
pragma solidity ^0.8.20;
/**
* @dev Standard ERC-20 Errors
* Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC-20 tokens.
*/
interface IERC20Errors {
/**
* @dev Indicates an error related to the current `balance` of a `sender`. Used in transfers.
* @param sender Address whose tokens are being transferred.
* @param balance Current balance for the interacting account.
* @param needed Minimum amount required to perform a transfer.
*/
error ERC20InsufficientBalance(address sender, uint256 balance, uint256 needed);
/**
* @dev Indicates a failure with the token `sender`. Used in transfers.
* @param sender Address whose tokens are being transferred.
*/
error ERC20InvalidSender(address sender);
/**
* @dev Indicates a failure with the token `receiver`. Used in transfers.
* @param receiver Address to which tokens are being transferred.
*/
error ERC20InvalidReceiver(address receiver);
/**
* @dev Indicates a failure with the `spender`’s `allowance`. Used in transfers.
* @param spender Address that may be allowed to operate on tokens without being their owner.
* @param allowance Amount of tokens a `spender` is allowed to operate with.
* @param needed Minimum amount required to perform a transfer.
*/
error ERC20InsufficientAllowance(address spender, uint256 allowance, uint256 needed);
/**
* @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals.
* @param approver Address initiating an approval operation.
*/
error ERC20InvalidApprover(address approver);
/**
* @dev Indicates a failure with the `spender` to be approved. Used in approvals.
* @param spender Address that may be allowed to operate on tokens without being their owner.
*/
error ERC20InvalidSpender(address spender);
}
/**
* @dev Standard ERC-721 Errors
* Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC-721 tokens.
*/
interface IERC721Errors {
/**
* @dev Indicates that an address can't be an owner. For example, `address(0)` is a forbidden owner in ERC-20.
* Used in balance queries.
* @param owner Address of the current owner of a token.
*/
error ERC721InvalidOwner(address owner);
/**
* @dev Indicates a `tokenId` whose `owner` is the zero address.
* @param tokenId Identifier number of a token.
*/
error ERC721NonexistentToken(uint256 tokenId);
/**
* @dev Indicates an error related to the ownership over a particular token. Used in transfers.
* @param sender Address whose tokens are being transferred.
* @param tokenId Identifier number of a token.
* @param owner Address of the current owner of a token.
*/
error ERC721IncorrectOwner(address sender, uint256 tokenId, address owner);
/**
* @dev Indicates a failure with the token `sender`. Used in transfers.
* @param sender Address whose tokens are being transferred.
*/
error ERC721InvalidSender(address sender);
/**
* @dev Indicates a failure with the token `receiver`. Used in transfers.
* @param receiver Address to which tokens are being transferred.
*/
error ERC721InvalidReceiver(address receiver);
/**
* @dev Indicates a failure with the `operator`’s approval. Used in transfers.
* @param operator Address that may be allowed to operate on tokens without being their owner.
* @param tokenId Identifier number of a token.
*/
error ERC721InsufficientApproval(address operator, uint256 tokenId);
/**
* @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals.
* @param approver Address initiating an approval operation.
*/
error ERC721InvalidApprover(address approver);
/**
* @dev Indicates a failure with the `operator` to be approved. Used in approvals.
* @param operator Address that may be allowed to operate on tokens without being their owner.
*/
error ERC721InvalidOperator(address operator);
}
/**
* @dev Standard ERC-1155 Errors
* Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC-1155 tokens.
*/
interface IERC1155Errors {
/**
* @dev Indicates an error related to the current `balance` of a `sender`. Used in transfers.
* @param sender Address whose tokens are being transferred.
* @param balance Current balance for the interacting account.
* @param needed Minimum amount required to perform a transfer.
* @param tokenId Identifier number of a token.
*/
error ERC1155InsufficientBalance(address sender, uint256 balance, uint256 needed, uint256 tokenId);
/**
* @dev Indicates a failure with the token `sender`. Used in transfers.
* @param sender Address whose tokens are being transferred.
*/
error ERC1155InvalidSender(address sender);
/**
* @dev Indicates a failure with the token `receiver`. Used in transfers.
* @param receiver Address to which tokens are being transferred.
*/
error ERC1155InvalidReceiver(address receiver);
/**
* @dev Indicates a failure with the `operator`’s approval. Used in transfers.
* @param operator Address that may be allowed to operate on tokens without being their owner.
* @param owner Address of the current owner of a token.
*/
error ERC1155MissingApprovalForAll(address operator, address owner);
/**
* @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals.
* @param approver Address initiating an approval operation.
*/
error ERC1155InvalidApprover(address approver);
/**
* @dev Indicates a failure with the `operator` to be approved. Used in approvals.
* @param operator Address that may be allowed to operate on tokens without being their owner.
*/
error ERC1155InvalidOperator(address operator);
/**
* @dev Indicates an array length mismatch between ids and values in a safeBatchTransferFrom operation.
* Used in batch transfers.
* @param idsLength Length of the array of token identifiers
* @param valuesLength Length of the array of token amounts
*/
error ERC1155InvalidArrayLength(uint256 idsLength, uint256 valuesLength);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.2.0) (token/ERC20/ERC20.sol)
pragma solidity ^0.8.20;
import {IERC20} from "./IERC20.sol";
import {IERC20Metadata} from "./extensions/IERC20Metadata.sol";
import {Context} from "../../utils/Context.sol";
import {IERC20Errors} from "../../interfaces/draft-IERC6093.sol";
/**
* @dev Implementation of the {IERC20} interface.
*
* This implementation is agnostic to the way tokens are created. This means
* that a supply mechanism has to be added in a derived contract using {_mint}.
*
* TIP: For a detailed writeup see our guide
* https://forum.openzeppelin.com/t/how-to-implement-erc20-supply-mechanisms/226[How
* to implement supply mechanisms].
*
* The default value of {decimals} is 18. To change this, you should override
* this function so it returns a different value.
*
* We have followed general OpenZeppelin Contracts guidelines: functions revert
* instead returning `false` on failure. This behavior is nonetheless
* conventional and does not conflict with the expectations of ERC-20
* applications.
*/
abstract contract ERC20 is Context, IERC20, IERC20Metadata, IERC20Errors {
mapping(address account => uint256) private _balances;
mapping(address account => mapping(address spender => uint256)) private _allowances;
uint256 private _totalSupply;
string private _name;
string private _symbol;
/**
* @dev Sets the values for {name} and {symbol}.
*
* All two of these values are immutable: they can only be set once during
* construction.
*/
constructor(string memory name_, string memory symbol_) {
_name = name_;
_symbol = symbol_;
}
/**
* @dev Returns the name of the token.
*/
function name() public view virtual returns (string memory) {
return _name;
}
/**
* @dev Returns the symbol of the token, usually a shorter version of the
* name.
*/
function symbol() public view virtual returns (string memory) {
return _symbol;
}
/**
* @dev Returns the number of decimals used to get its user representation.
* For example, if `decimals` equals `2`, a balance of `505` tokens should
* be displayed to a user as `5.05` (`505 / 10 ** 2`).
*
* Tokens usually opt for a value of 18, imitating the relationship between
* Ether and Wei. This is the default value returned by this function, unless
* it's overridden.
*
* NOTE: This information is only used for _display_ purposes: it in
* no way affects any of the arithmetic of the contract, including
* {IERC20-balanceOf} and {IERC20-transfer}.
*/
function decimals() public view virtual returns (uint8) {
return 18;
}
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSupply() public view virtual returns (uint256) {
return _totalSupply;
}
/**
* @dev See {IERC20-balanceOf}.
*/
function balanceOf(address account) public view virtual returns (uint256) {
return _balances[account];
}
/**
* @dev See {IERC20-transfer}.
*
* Requirements:
*
* - `to` cannot be the zero address.
* - the caller must have a balance of at least `value`.
*/
function transfer(address to, uint256 value) public virtual returns (bool) {
address owner = _msgSender();
_transfer(owner, to, value);
return true;
}
/**
* @dev See {IERC20-allowance}.
*/
function allowance(address owner, address spender) public view virtual returns (uint256) {
return _allowances[owner][spender];
}
/**
* @dev See {IERC20-approve}.
*
* NOTE: If `value` is the maximum `uint256`, the allowance is not updated on
* `transferFrom`. This is semantically equivalent to an infinite approval.
*
* Requirements:
*
* - `spender` cannot be the zero address.
*/
function approve(address spender, uint256 value) public virtual returns (bool) {
address owner = _msgSender();
_approve(owner, spender, value);
return true;
}
/**
* @dev See {IERC20-transferFrom}.
*
* Skips emitting an {Approval} event indicating an allowance update. This is not
* required by the ERC. See {xref-ERC20-_approve-address-address-uint256-bool-}[_approve].
*
* NOTE: Does not update the allowance if the current allowance
* is the maximum `uint256`.
*
* Requirements:
*
* - `from` and `to` cannot be the zero address.
* - `from` must have a balance of at least `value`.
* - the caller must have allowance for ``from``'s tokens of at least
* `value`.
*/
function transferFrom(address from, address to, uint256 value) public virtual returns (bool) {
address spender = _msgSender();
_spendAllowance(from, spender, value);
_transfer(from, to, value);
return true;
}
/**
* @dev Moves a `value` amount of tokens from `from` to `to`.
*
* This internal function is equivalent to {transfer}, and can be used to
* e.g. implement automatic token fees, slashing mechanisms, etc.
*
* Emits a {Transfer} event.
*
* NOTE: This function is not virtual, {_update} should be overridden instead.
*/
function _transfer(address from, address to, uint256 value) internal {
if (from == address(0)) {
revert ERC20InvalidSender(address(0));
}
if (to == address(0)) {
revert ERC20InvalidReceiver(address(0));
}
_update(from, to, value);
}
/**
* @dev Transfers a `value` amount of tokens from `from` to `to`, or alternatively mints (or burns) if `from`
* (or `to`) is the zero address. All customizations to transfers, mints, and burns should be done by overriding
* this function.
*
* Emits a {Transfer} event.
*/
function _update(address from, address to, uint256 value) internal virtual {
if (from == address(0)) {
// Overflow check required: The rest of the code assumes that totalSupply never overflows
_totalSupply += value;
} else {
uint256 fromBalance = _balances[from];
if (fromBalance < value) {
revert ERC20InsufficientBalance(from, fromBalance, value);
}
unchecked {
// Overflow not possible: value <= fromBalance <= totalSupply.
_balances[from] = fromBalance - value;
}
}
if (to == address(0)) {
unchecked {
// Overflow not possible: value <= totalSupply or value <= fromBalance <= totalSupply.
_totalSupply -= value;
}
} else {
unchecked {
// Overflow not possible: balance + value is at most totalSupply, which we know fits into a uint256.
_balances[to] += value;
}
}
emit Transfer(from, to, value);
}
/**
* @dev Creates a `value` amount of tokens and assigns them to `account`, by transferring it from address(0).
* Relies on the `_update` mechanism
*
* Emits a {Transfer} event with `from` set to the zero address.
*
* NOTE: This function is not virtual, {_update} should be overridden instead.
*/
function _mint(address account, uint256 value) internal {
if (account == address(0)) {
revert ERC20InvalidReceiver(address(0));
}
_update(address(0), account, value);
}
/**
* @dev Destroys a `value` amount of tokens from `account`, lowering the total supply.
* Relies on the `_update` mechanism.
*
* Emits a {Transfer} event with `to` set to the zero address.
*
* NOTE: This function is not virtual, {_update} should be overridden instead
*/
function _burn(address account, uint256 value) internal {
if (account == address(0)) {
revert ERC20InvalidSender(address(0));
}
_update(account, address(0), value);
}
/**
* @dev Sets `value` as the allowance of `spender` over the `owner` s tokens.
*
* This internal function is equivalent to `approve`, and can be used to
* e.g. set automatic allowances for certain subsystems, etc.
*
* Emits an {Approval} event.
*
* Requirements:
*
* - `owner` cannot be the zero address.
* - `spender` cannot be the zero address.
*
* Overrides to this logic should be done to the variant with an additional `bool emitEvent` argument.
*/
function _approve(address owner, address spender, uint256 value) internal {
_approve(owner, spender, value, true);
}
/**
* @dev Variant of {_approve} with an optional flag to enable or disable the {Approval} event.
*
* By default (when calling {_approve}) the flag is set to true. On the other hand, approval changes made by
* `_spendAllowance` during the `transferFrom` operation set the flag to false. This saves gas by not emitting any
* `Approval` event during `transferFrom` operations.
*
* Anyone who wishes to continue emitting `Approval` events on the`transferFrom` operation can force the flag to
* true using the following override:
*
* ```solidity
* function _approve(address owner, address spender, uint256 value, bool) internal virtual override {
* super._approve(owner, spender, value, true);
* }
* ```
*
* Requirements are the same as {_approve}.
*/
function _approve(address owner, address spender, uint256 value, bool emitEvent) internal virtual {
if (owner == address(0)) {
revert ERC20InvalidApprover(address(0));
}
if (spender == address(0)) {
revert ERC20InvalidSpender(address(0));
}
_allowances[owner][spender] = value;
if (emitEvent) {
emit Approval(owner, spender, value);
}
}
/**
* @dev Updates `owner` s allowance for `spender` based on spent `value`.
*
* Does not update the allowance value in case of infinite allowance.
* Revert if not enough allowance is available.
*
* Does not emit an {Approval} event.
*/
function _spendAllowance(address owner, address spender, uint256 value) internal virtual {
uint256 currentAllowance = allowance(owner, spender);
if (currentAllowance < type(uint256).max) {
if (currentAllowance < value) {
revert ERC20InsufficientAllowance(spender, currentAllowance, value);
}
unchecked {
_approve(owner, spender, currentAllowance - value, false);
}
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (token/ERC20/extensions/IERC20Metadata.sol)
pragma solidity ^0.8.20;
import {IERC20} from "../IERC20.sol";
/**
* @dev Interface for the optional metadata functions from the ERC-20 standard.
*/
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 (last updated v5.1.0) (token/ERC20/IERC20.sol)
pragma solidity ^0.8.20;
/**
* @dev Interface of the ERC-20 standard as defined in the ERC.
*/
interface IERC20 {
/**
* @dev Emitted when `value` tokens are moved from one account (`from`) to
* another (`to`).
*
* Note that `value` may be zero.
*/
event Transfer(address indexed from, address indexed to, uint256 value);
/**
* @dev Emitted when the allowance of a `spender` for an `owner` is set by
* a call to {approve}. `value` is the new allowance.
*/
event Approval(address indexed owner, address indexed spender, uint256 value);
/**
* @dev Returns the value of tokens in existence.
*/
function totalSupply() external view returns (uint256);
/**
* @dev Returns the value of tokens owned by `account`.
*/
function balanceOf(address account) external view returns (uint256);
/**
* @dev Moves a `value` amount of tokens from the caller's account to `to`.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/
function transfer(address to, uint256 value) external returns (bool);
/**
* @dev Returns the remaining number of tokens that `spender` will be
* allowed to spend on behalf of `owner` through {transferFrom}. This is
* zero by default.
*
* This value changes when {approve} or {transferFrom} are called.
*/
function allowance(address owner, address spender) external view returns (uint256);
/**
* @dev Sets a `value` amount of tokens as the allowance of `spender` over the
* caller's tokens.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* IMPORTANT: Beware that changing an allowance with this method brings the risk
* that someone may use both the old and the new allowance by unfortunate
* transaction ordering. One possible solution to mitigate this race
* condition is to first reduce the spender's allowance to 0 and set the
* desired value afterwards:
* https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
*
* Emits an {Approval} event.
*/
function approve(address spender, uint256 value) external returns (bool);
/**
* @dev Moves a `value` amount of tokens from `from` to `to` using the
* allowance mechanism. `value` is then deducted from the caller's
* allowance.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/
function transferFrom(address from, address to, uint256 value) external returns (bool);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.1) (utils/Context.sol)
pragma solidity ^0.8.20;
/**
* @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;
}
function _contextSuffixLength() internal view virtual returns (uint256) {
return 0;
}
}// SPDX-License-Identifier: GPL-2.0-or-later /* * @title Solidity Bytes Arrays Utils * @author Gonçalo Sá <[email protected]> * * @dev Bytes tightly packed arrays utility library for ethereum contracts written in Solidity. * The library lets you concatenate, slice and type cast bytes arrays both in memory and storage. */ //pragma solidity >=0.5.0 <0.8.0; pragma solidity ^0.8.25; library BytesLib { function slice(bytes memory _bytes, uint256 _start, uint256 _length) internal pure returns (bytes memory) { require(_length + 31 >= _length, "SO"); // slice overflow require(_start + _length >= _start, "SO"); // slice overflow require(_bytes.length >= _start + _length, "SOB"); // slice out of bounds bytes memory tempBytes; assembly { switch iszero(_length) case 0 { // Get a location of some free memory and store it in tempBytes as // Solidity does for memory variables. tempBytes := mload(0x40) // The first word of the slice result is potentially a partial // word read from the original array. To read it, we calculate // the length of that partial word and start copying that many // bytes into the array. The first word we copy will start with // data we don't care about, but the last `lengthmod` bytes will // land at the beginning of the contents of the new array. When // we're done copying, we overwrite the full first word with // the actual length of the slice. let lengthmod := and(_length, 31) // The multiplication in the next line is necessary // because when slicing multiples of 32 bytes (lengthmod == 0) // the following copy loop was copying the origin's length // and then ending prematurely not copying everything it should. let mc := add(add(tempBytes, lengthmod), mul(0x20, iszero(lengthmod))) let end := add(mc, _length) for { // The multiplication in the next line has the same exact purpose // as the one above. let cc := add(add(add(_bytes, lengthmod), mul(0x20, iszero(lengthmod))), _start) } lt(mc, end) { mc := add(mc, 0x20) cc := add(cc, 0x20) } { mstore(mc, mload(cc)) } mstore(tempBytes, _length) //update free-memory pointer //allocating the array padded to 32 bytes like the compiler does now mstore(0x40, and(add(mc, 31), not(31))) } //if we want a zero-length slice let's just return a zero-length array default { tempBytes := mload(0x40) //zero out the 32 bytes slice we are about to return //we need to do it because Solidity does not garbage collect mstore(tempBytes, 0) mstore(0x40, add(tempBytes, 0x20)) } } return tempBytes; } function toAddress(bytes memory _bytes, uint256 _start) internal pure returns (address) { require(_start + 20 >= _start, "AO"); // to address overflow require(_bytes.length >= _start + 20, "AOB"); // to address out of bounds address tempAddress; assembly { tempAddress := div(mload(add(add(_bytes, 0x20), _start)), 0x1000000000000000000000000) } return tempAddress; } function toInt24(bytes memory _bytes, uint256 _start) internal pure returns (int24) { require(_start + 3 >= _start, "UO"); // uint24 overflow require(_bytes.length >= _start + 3, "UOB"); // uint24 out of bounds uint24 tempUint; assembly { tempUint := mload(add(add(_bytes, 0x3), _start)) } require(tempUint <= uint24(type(int24).max), "IO"); // int24 overflow return int24(tempUint); } }
// SPDX-License-Identifier: GPL-2.0-or-later
pragma solidity >=0.6.0;
import "./BytesLib.sol";
/// @title Functions for manipulating path data for multihop swaps
library Path {
using BytesLib for bytes;
/// @dev The length of the bytes encoded address
uint256 private constant ADDR_SIZE = 20;
/// @dev The length of the bytes encoded fee
uint256 private constant FEE_SIZE = 3;
/// @dev The offset of a single token address and pool fee
uint256 private constant NEXT_OFFSET = ADDR_SIZE + FEE_SIZE;
/// @dev The offset of an encoded pool key
uint256 private constant POP_OFFSET = NEXT_OFFSET + ADDR_SIZE;
/// @dev The minimum length of an encoding that contains 2 or more pools
uint256 private constant MULTIPLE_POOLS_MIN_LENGTH = POP_OFFSET + NEXT_OFFSET;
/// @notice Returns true iff the path contains two or more pools
/// @param path The encoded swap path
/// @return True if path contains two or more pools, otherwise false
function hasMultiplePools(bytes memory path) internal pure returns (bool) {
return path.length >= MULTIPLE_POOLS_MIN_LENGTH;
}
/// @notice Returns the number of pools in the path
/// @param path The encoded swap path
/// @return The number of pools in the path
function numPools(bytes memory path) internal pure returns (uint256) {
// Ignore the first token address. From then on every tick spacing and token offset indicates a pool.
return ((path.length - ADDR_SIZE) / NEXT_OFFSET);
}
/// @notice Decodes the first pool in path
/// @param path The bytes encoded swap path
/// @return tokenA The first token of the given pool
/// @return tokenB The second token of the given pool
/// @return tickSpacing The tick spacing of the pool
function decodeFirstPool(bytes memory path)
internal
pure
returns (address tokenA, address tokenB, int24 tickSpacing)
{
tokenA = path.toAddress(0);
tickSpacing = path.toInt24(ADDR_SIZE);
tokenB = path.toAddress(NEXT_OFFSET);
}
/// @notice Gets the segment corresponding to the first pool in the path
/// @param path The bytes encoded swap path
/// @return The segment containing all data necessary to target the first pool in the path
function getFirstPool(bytes memory path) internal pure returns (bytes memory) {
return path.slice(0, POP_OFFSET);
}
/// @notice Skips a token + fee element from the buffer and returns the remainder
/// @param path The swap path
/// @return The remaining token + fee elements in the path
function skipToken(bytes memory path) internal pure returns (bytes memory) {
return path.slice(NEXT_OFFSET, path.length - NEXT_OFFSET);
}
}{
"viaIR": true,
"optimizer": {
"enabled": true,
"runs": 2000
},
"evmVersion": "paris",
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[{"internalType":"contract ISwapRouter","name":"_swapRouter","type":"address"},{"internalType":"address","name":"_weth","type":"address"},{"internalType":"address","name":"_ethx","type":"address"},{"internalType":"contract ILPFactoryAero","name":"_lpFactoryAero","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"aeroTickSpacing","outputs":[{"internalType":"int24","name":"","type":"int24"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"ethx","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"lpFactoryAero","outputs":[{"internalType":"contract ILPFactoryAero","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"uniPoolFee","outputs":[{"internalType":"uint24","name":"","type":"uint24"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"uniSwapRouter","outputs":[{"internalType":"contract ISwapRouter","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"int256","name":"amount0Delta","type":"int256"},{"internalType":"int256","name":"amount1Delta","type":"int256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"uniswapV3SwapCallback","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"weth","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"stremeCoin","type":"address"},{"internalType":"uint256","name":"amountIn","type":"uint256"},{"internalType":"uint256","name":"amountOutMin","type":"uint256"},{"internalType":"address","name":"stakingContract","type":"address"}],"name":"zap","outputs":[{"internalType":"uint256","name":"amountOut","type":"uint256"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"stremeCoin","type":"address"},{"internalType":"uint256","name":"amountIn","type":"uint256"},{"internalType":"uint256","name":"amountOutMin","type":"uint256"},{"internalType":"address","name":"stakingContract","type":"address"}],"name":"zapETHx","outputs":[{"internalType":"uint256","name":"amountOut","type":"uint256"}],"stateMutability":"payable","type":"function"}]Contract Creation Code
60a080604052346101325760808161119c803803809161001f828561014b565b8339810103126101325780516001600160a01b0381168082036101325761004860208401610184565b91606061005760408601610184565b9401516001600160a01b038116929083900361013257608091909152600080546001600160a01b03199081166001600160a01b03958616178255600180548216959096169485179095556002805490951690921790935560405163095ea7b360e01b81526004810193909352600019602484015260209183916044918391905af1801561013f57610102575b604051611003908161019982396080518181816104260152610b070152f35b6020813d602011610137575b8161011b6020938361014b565b8101031261013257518015150361013257386100e3565b600080fd5b3d915061010e565b6040513d6000823e3d90fd5b601f909101601f19168101906001600160401b0382119082101761016e57604052565b634e487b7160e01b600052604160045260246000fd5b51906001600160a01b03821682036101325756fe6080604052600436101561001257600080fd5b60003560e01c806306ab1cf2146100a757806335d88456146100a25780633fc8cef31461009d57806355c0dd39146100985780635d01ff3d14610093578063b60347a31461008e578063df9467c314610089578063e7e1305a146100845763fa461e331461007f57600080fd5b61057d565b610556565b61052f565b61044a565b610406565b6103e9565b6103c2565b610122565b346100c45760006003193601126100c4576101f460805260206080f35b600080fd5b60009103126100c457565b6001600160a01b038116036100c457565b35906100f0826100d4565b565b60031960809101126100c45760043561010a816100d4565b90602435906044359060643561011f816100d4565b90565b61012b366100f2565b9192909161013a3485146105e1565b61015e6101526101526001546001600160a01b031690565b6001600160a01b031690565b803b156100c4576000600491604051928380927fcf81464b00000000000000000000000000000000000000000000000000000000825234905af1801561031f576103ad575b506001600160a01b038116938415801594906103a757305b6101d06101526002546001600160a01b031690565b6040516302aca45560e31b81526001600160a01b03871660048201529290602090849060249082905afa92831561031f57600093610376575b506001600160a01b038316156103515761023593866102306001546001600160a01b031690565b610cca565b925b61024b575b604051838152602090f35b0390f35b6040517f095ea7b30000000000000000000000000000000000000000000000000000000081526001600160a01b039182166004820152602481018490529160209183916044918391600091165af1801561031f57610324575b50813b156100c4576040517fadc9772e00000000000000000000000000000000000000000000000000000000815233600482015260248101829052916000908390604490829084905af191821561031f5761024792610304575b8061023c565b806103136000610319936106a2565b806100c9565b386102fe565b6106c5565b6103459060203d60201161034a575b61033d81836106a2565b8101906106e6565b6102a4565b503d610333565b909150610370928561036b6001546001600160a01b031690565b610a0f565b92610237565b61039991935060203d6020116103a0575b61039181836106a2565b8101906106d1565b9138610209565b503d610387565b336101bb565b8061031360006103bc936106a2565b386101a3565b346100c45760006003193601126100c45760206001600160a01b0360005416604051908152f35b346100c45760006003193601126100c45760206040516127108152f35b346100c45760006003193601126100c45760206040516001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000168152f35b610453366100f2565b919290916104623485146105e1565b6001600160a01b0381169384158015949061052957305b61048e6101526002546001600160a01b031690565b6040516302aca45560e31b81526001600160a01b03871660048201529290602090849060249082905afa92831561031f57600093610508575b506001600160a01b038316156104ee5761023593866102306000546001600160a01b031690565b909150610370928561036b6000546001600160a01b031690565b61052291935060203d6020116103a05761039181836106a2565b91386104c7565b33610479565b346100c45760006003193601126100c45760206001600160a01b0360015416604051908152f35b346100c45760006003193601126100c45760206001600160a01b0360025416604051908152f35b346100c45760606003193601126100c45760443560243560043567ffffffffffffffff83116100c457366023840112156100c45782600401359167ffffffffffffffff83116100c45736602484860101116100c45760246105df94019161081f565b005b156105e857565b608460405162461bcd60e51b815260206004820152602360248201527f6d73672e76616c7565206d75737420626520657175616c20746f20616d6f756e60448201527f74496e00000000000000000000000000000000000000000000000000000000006064820152fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040810190811067ffffffffffffffff82111761069d57604052565b610652565b90601f601f19910116810190811067ffffffffffffffff82111761069d57604052565b6040513d6000823e3d90fd5b908160209103126100c4575161011f816100d4565b908160209103126100c4575180151581036100c45790565b156100c457565b604051906100f060e0836106a2565b604051906100f06040836106a2565b6020818303126100c45780359067ffffffffffffffff82116100c45701906040828203126100c4576040519161075883610681565b803567ffffffffffffffff81116100c45781019082601f830112156100c45781359267ffffffffffffffff841161069d57604051906107a16020601f19601f88011601836106a2565b848252602085850101116100c45760006020856107cc968280970183860137830101528452016100e5565b602082015290565b156107db57565b606460405162461bcd60e51b815260206004820152601760248201527f43616c6c6261636b206f6e6c792066726f6d20706f6f6c0000000000000000006044820152fd5b6108496108929360209395600061084f941380156109f6575b610841906106fe565b810190610723565b51610e35565b5090506108676101526002546001600160a01b031690565b60405180809581946302aca45560e31b8352600483019190916001600160a01b036020820193169052565b03915afa90811561031f576108bb916001600160a01b03916000916109d7575b501633146107d4565b80471015610953575b60206109276000926108e361015261015286546001600160a01b031690565b6040517fa9059cbb00000000000000000000000000000000000000000000000000000000815233600482015260248101929092529093849283919082906044820190565b03925af1801561031f576109385750565b6109509060203d60201161034a5761033d81836106a2565b50565b61096b6101526101526000546001600160a01b031690565b803b156100c457600082916004604051809481937fd0e30db00000000000000000000000000000000000000000000000000000000083525af1801561031f57600092602092610927926109c3575b50925050506108c4565b80610313866109d1936106a2565b386109b9565b6109f0915060203d6020116103a05761039181836106a2565b386108b2565b5060008713610838565b908160209103126100c4575190565b91610a5f610afa95610a4760209694610a38610a29610705565b6001600160a01b039098168852565b6001600160a01b031686880152565b61271060408601526001600160a01b03166060850152565b608083015260a0820152600060c0820152604051809381927f04e45aaf0000000000000000000000000000000000000000000000000000000083526004830191909160c06001600160a01b038160e084019582815116855282602082015116602086015262ffffff60408201511660408601528260608201511660608601526080810151608086015260a081015160a0860152015116910152565b0381346001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000165af190811561031f57600091610b3b575090565b61011f915060203d602011610b5d575b610b5581836106a2565b810190610a00565b503d610b4b565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082519283825260005b848110610bbf575050601f19601f8460006020809697860101520116010190565b80602080928401015182828601015201610b9e565b6020815260406001600160a01b036020610bf8855184838701526060860190610b93565b9401511691015290565b91908260409103126100c4576020825192015190565b9061011f949360a0936001600160a01b0380931684526000602085015260408401521660608201528160808201520190610b93565b7f80000000000000000000000000000000000000000000000000000000000000008114610c7a5760000390565b610b64565b15610c8657565b606460405162461bcd60e51b815260206004820152601360248201527f546f6f206c6974746c65207265636569766564000000000000000000000000006044820152fd5b9160006001600160a01b03610d9496610d5c6040979a999596610d4e89519889926020840190602b927fffffffffffffffffffffffffffffffffffffffff000000000000000000000000809260601b1683527e01f40000000000000000000000000000000000000000000000000000000000601484015260601b1660178201520190565b03601f1981018852876106a2565b610d64610714565b958652336020870152610da273fffd8963efd1fc6a506488495d951d5263988d25968851998a9160208301610bd4565b03601f1981018a52896106a2565b610dda8751988997889687947f128acb0800000000000000000000000000000000000000000000000000000000865260048601610c18565b0393165af190811561031f576100f091610dfc91600091610e05575b50610c4d565b92831015610c7f565b610e27915060403d604011610e2e575b610e1f81836106a2565b810190610c02565b5038610df6565b503d610e15565b90610e4860146000845190501015610ec7565b602082015160601c916017815110610e8357610e80601762ffffff8184015116610e77627fffff821115610f82565b60020b92610f12565b91565b606460405162461bcd60e51b815260206004820152600360248201527f554f4200000000000000000000000000000000000000000000000000000000006044820152fd5b15610ece57565b606460405162461bcd60e51b815260206004820152600360248201527f414f4200000000000000000000000000000000000000000000000000000000006044820152fd5b906014810191828211610c7a57818310610f3e57610f3560209382511015610ec7565b01015160601c90565b606460405162461bcd60e51b815260206004820152600260248201527f414f0000000000000000000000000000000000000000000000000000000000006044820152fd5b15610f8957565b606460405162461bcd60e51b815260206004820152600260248201527f494f0000000000000000000000000000000000000000000000000000000000006044820152fdfea2646970667358221220422507679b78ca473946decf4816ce4c06b6ca8e29a123b345b5ff65765b0c7764736f6c634300081a00330000000000000000000000002626664c2603336e57b271c5c0b26f421741e481000000000000000000000000420000000000000000000000000000000000000600000000000000000000000046fd5cfb4c12d87acd3a13e92baa53240c661d930000000000000000000000003f0b1d98576cba9f6318dbff7cd17f03069dd9b2
Deployed Bytecode
0x6080604052600436101561001257600080fd5b60003560e01c806306ab1cf2146100a757806335d88456146100a25780633fc8cef31461009d57806355c0dd39146100985780635d01ff3d14610093578063b60347a31461008e578063df9467c314610089578063e7e1305a146100845763fa461e331461007f57600080fd5b61057d565b610556565b61052f565b61044a565b610406565b6103e9565b6103c2565b610122565b346100c45760006003193601126100c4576101f460805260206080f35b600080fd5b60009103126100c457565b6001600160a01b038116036100c457565b35906100f0826100d4565b565b60031960809101126100c45760043561010a816100d4565b90602435906044359060643561011f816100d4565b90565b61012b366100f2565b9192909161013a3485146105e1565b61015e6101526101526001546001600160a01b031690565b6001600160a01b031690565b803b156100c4576000600491604051928380927fcf81464b00000000000000000000000000000000000000000000000000000000825234905af1801561031f576103ad575b506001600160a01b038116938415801594906103a757305b6101d06101526002546001600160a01b031690565b6040516302aca45560e31b81526001600160a01b03871660048201529290602090849060249082905afa92831561031f57600093610376575b506001600160a01b038316156103515761023593866102306001546001600160a01b031690565b610cca565b925b61024b575b604051838152602090f35b0390f35b6040517f095ea7b30000000000000000000000000000000000000000000000000000000081526001600160a01b039182166004820152602481018490529160209183916044918391600091165af1801561031f57610324575b50813b156100c4576040517fadc9772e00000000000000000000000000000000000000000000000000000000815233600482015260248101829052916000908390604490829084905af191821561031f5761024792610304575b8061023c565b806103136000610319936106a2565b806100c9565b386102fe565b6106c5565b6103459060203d60201161034a575b61033d81836106a2565b8101906106e6565b6102a4565b503d610333565b909150610370928561036b6001546001600160a01b031690565b610a0f565b92610237565b61039991935060203d6020116103a0575b61039181836106a2565b8101906106d1565b9138610209565b503d610387565b336101bb565b8061031360006103bc936106a2565b386101a3565b346100c45760006003193601126100c45760206001600160a01b0360005416604051908152f35b346100c45760006003193601126100c45760206040516127108152f35b346100c45760006003193601126100c45760206040516001600160a01b037f0000000000000000000000002626664c2603336e57b271c5c0b26f421741e481168152f35b610453366100f2565b919290916104623485146105e1565b6001600160a01b0381169384158015949061052957305b61048e6101526002546001600160a01b031690565b6040516302aca45560e31b81526001600160a01b03871660048201529290602090849060249082905afa92831561031f57600093610508575b506001600160a01b038316156104ee5761023593866102306000546001600160a01b031690565b909150610370928561036b6000546001600160a01b031690565b61052291935060203d6020116103a05761039181836106a2565b91386104c7565b33610479565b346100c45760006003193601126100c45760206001600160a01b0360015416604051908152f35b346100c45760006003193601126100c45760206001600160a01b0360025416604051908152f35b346100c45760606003193601126100c45760443560243560043567ffffffffffffffff83116100c457366023840112156100c45782600401359167ffffffffffffffff83116100c45736602484860101116100c45760246105df94019161081f565b005b156105e857565b608460405162461bcd60e51b815260206004820152602360248201527f6d73672e76616c7565206d75737420626520657175616c20746f20616d6f756e60448201527f74496e00000000000000000000000000000000000000000000000000000000006064820152fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040810190811067ffffffffffffffff82111761069d57604052565b610652565b90601f601f19910116810190811067ffffffffffffffff82111761069d57604052565b6040513d6000823e3d90fd5b908160209103126100c4575161011f816100d4565b908160209103126100c4575180151581036100c45790565b156100c457565b604051906100f060e0836106a2565b604051906100f06040836106a2565b6020818303126100c45780359067ffffffffffffffff82116100c45701906040828203126100c4576040519161075883610681565b803567ffffffffffffffff81116100c45781019082601f830112156100c45781359267ffffffffffffffff841161069d57604051906107a16020601f19601f88011601836106a2565b848252602085850101116100c45760006020856107cc968280970183860137830101528452016100e5565b602082015290565b156107db57565b606460405162461bcd60e51b815260206004820152601760248201527f43616c6c6261636b206f6e6c792066726f6d20706f6f6c0000000000000000006044820152fd5b6108496108929360209395600061084f941380156109f6575b610841906106fe565b810190610723565b51610e35565b5090506108676101526002546001600160a01b031690565b60405180809581946302aca45560e31b8352600483019190916001600160a01b036020820193169052565b03915afa90811561031f576108bb916001600160a01b03916000916109d7575b501633146107d4565b80471015610953575b60206109276000926108e361015261015286546001600160a01b031690565b6040517fa9059cbb00000000000000000000000000000000000000000000000000000000815233600482015260248101929092529093849283919082906044820190565b03925af1801561031f576109385750565b6109509060203d60201161034a5761033d81836106a2565b50565b61096b6101526101526000546001600160a01b031690565b803b156100c457600082916004604051809481937fd0e30db00000000000000000000000000000000000000000000000000000000083525af1801561031f57600092602092610927926109c3575b50925050506108c4565b80610313866109d1936106a2565b386109b9565b6109f0915060203d6020116103a05761039181836106a2565b386108b2565b5060008713610838565b908160209103126100c4575190565b91610a5f610afa95610a4760209694610a38610a29610705565b6001600160a01b039098168852565b6001600160a01b031686880152565b61271060408601526001600160a01b03166060850152565b608083015260a0820152600060c0820152604051809381927f04e45aaf0000000000000000000000000000000000000000000000000000000083526004830191909160c06001600160a01b038160e084019582815116855282602082015116602086015262ffffff60408201511660408601528260608201511660608601526080810151608086015260a081015160a0860152015116910152565b0381346001600160a01b037f0000000000000000000000002626664c2603336e57b271c5c0b26f421741e481165af190811561031f57600091610b3b575090565b61011f915060203d602011610b5d575b610b5581836106a2565b810190610a00565b503d610b4b565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082519283825260005b848110610bbf575050601f19601f8460006020809697860101520116010190565b80602080928401015182828601015201610b9e565b6020815260406001600160a01b036020610bf8855184838701526060860190610b93565b9401511691015290565b91908260409103126100c4576020825192015190565b9061011f949360a0936001600160a01b0380931684526000602085015260408401521660608201528160808201520190610b93565b7f80000000000000000000000000000000000000000000000000000000000000008114610c7a5760000390565b610b64565b15610c8657565b606460405162461bcd60e51b815260206004820152601360248201527f546f6f206c6974746c65207265636569766564000000000000000000000000006044820152fd5b9160006001600160a01b03610d9496610d5c6040979a999596610d4e89519889926020840190602b927fffffffffffffffffffffffffffffffffffffffff000000000000000000000000809260601b1683527e01f40000000000000000000000000000000000000000000000000000000000601484015260601b1660178201520190565b03601f1981018852876106a2565b610d64610714565b958652336020870152610da273fffd8963efd1fc6a506488495d951d5263988d25968851998a9160208301610bd4565b03601f1981018a52896106a2565b610dda8751988997889687947f128acb0800000000000000000000000000000000000000000000000000000000865260048601610c18565b0393165af190811561031f576100f091610dfc91600091610e05575b50610c4d565b92831015610c7f565b610e27915060403d604011610e2e575b610e1f81836106a2565b810190610c02565b5038610df6565b503d610e15565b90610e4860146000845190501015610ec7565b602082015160601c916017815110610e8357610e80601762ffffff8184015116610e77627fffff821115610f82565b60020b92610f12565b91565b606460405162461bcd60e51b815260206004820152600360248201527f554f4200000000000000000000000000000000000000000000000000000000006044820152fd5b15610ece57565b606460405162461bcd60e51b815260206004820152600360248201527f414f4200000000000000000000000000000000000000000000000000000000006044820152fd5b906014810191828211610c7a57818310610f3e57610f3560209382511015610ec7565b01015160601c90565b606460405162461bcd60e51b815260206004820152600260248201527f414f0000000000000000000000000000000000000000000000000000000000006044820152fd5b15610f8957565b606460405162461bcd60e51b815260206004820152600260248201527f494f0000000000000000000000000000000000000000000000000000000000006044820152fdfea2646970667358221220422507679b78ca473946decf4816ce4c06b6ca8e29a123b345b5ff65765b0c7764736f6c634300081a0033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
0000000000000000000000002626664c2603336e57b271c5c0b26f421741e481000000000000000000000000420000000000000000000000000000000000000600000000000000000000000046fd5cfb4c12d87acd3a13e92baa53240c661d930000000000000000000000003f0b1d98576cba9f6318dbff7cd17f03069dd9b2
-----Decoded View---------------
Arg [0] : _swapRouter (address): 0x2626664c2603336E57B271c5C0b26F421741e481
Arg [1] : _weth (address): 0x4200000000000000000000000000000000000006
Arg [2] : _ethx (address): 0x46fd5cfB4c12D87acD3a13e92BAa53240C661D93
Arg [3] : _lpFactoryAero (address): 0x3f0B1d98576CBA9f6318DbfF7Cd17F03069DD9B2
-----Encoded View---------------
4 Constructor Arguments found :
Arg [0] : 0000000000000000000000002626664c2603336e57b271c5c0b26f421741e481
Arg [1] : 0000000000000000000000004200000000000000000000000000000000000006
Arg [2] : 00000000000000000000000046fd5cfb4c12d87acd3a13e92baa53240c661d93
Arg [3] : 0000000000000000000000003f0b1d98576cba9f6318dbff7cd17f03069dd9b2
Loading...
Loading
Loading...
Loading
Loading...
Loading
Net Worth in USD
$0.00
Net Worth in ETH
0
Multichain Portfolio | 35 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|
Loading...
Loading
Loading...
Loading
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.