Transaction Hash:
Block:
18212172 at Sep-25-2023 10:21:35 AM +UTC
Transaction Fee:
0.001360371247659975 ETH
$3.90
Gas Used:
190,815 Gas / 7.129267865 Gwei
Account State Difference:
Address | Before | After | State Difference | ||
---|---|---|---|---|---|
0x83927E6d...655Dd22B0 |
0.046756901196154406 Eth
Nonce: 2
|
0.045396529948494431 Eth
Nonce: 3
| 0.001360371247659975 | ||
0xDAFEA492...692c98Bc5
Miner
| (Flashbots: Builder) | 1.386435278427958768 Eth | 1.386491867488737778 Eth | 0.00005658906077901 |
Execution Trace
ETH 0.020742447766377632
WooCrossChainRouterV2.crossSwap( refId=806071695637289392, to=0x83927E6d27967Da8FCcE9A2FE6079B5655Dd22B0, srcInfos=[{name:fromToken, type:address, order:1, indexed:false, value:0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE, valueString:0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE}, {name:bridgeToken, type:address, order:2, indexed:false, value:0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2, valueString:0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2}, {name:fromAmount, type:uint256, order:3, indexed:false, value:20000000000000000, valueString:20000000000000000}, {name:minBridgeAmount, type:uint256, order:4, indexed:false, value:20000000000000000, valueString:20000000000000000}], dstInfos=[{name:chainId, type:uint16, order:1, indexed:false, value:184, valueString:184}, {name:toToken, type:address, order:2, indexed:false, value:0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE, valueString:0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE}, {name:bridgeToken, type:address, order:3, indexed:false, value:0x4200000000000000000000000000000000000006, valueString:0x4200000000000000000000000000000000000006}, {name:minToAmount, type:uint256, order:4, indexed:false, value:19799009999999999, valueString:19799009999999999}, {name:airdropNativeAmount, type:uint256, order:5, indexed:false, value:0, valueString:0}] )
- ETH 0.02
WETH9.CALL( )
-
WETH9.balanceOf( 0x9D1A92e601db0901e69bd810029F2C14bCCA3128 ) => ( 20000000000000000 )
WETH9.withdraw( wad=20000000000000000 )
- ETH 0.02
WooCrossChainRouterV2.CALL( )
- ETH 0.02
- ETH 0.02
StargateEthVault.CALL( )
-
StargateEthVault.approve( guy=0xeCc19E177d24551aA7ed6Bc6FE566eCa726CC8a9, wad=20000000000000000 ) => ( True )
- ETH 0.000742447766377632
StargateComposer.swap( _dstChainId=184, _srcPoolId=13, _dstPoolId=13, _refundAddress=0x83927E6d27967Da8FCcE9A2FE6079B5655Dd22B0, _amountLD=20000000000000000, _minAmountLD=19800000000000000, _lzTxParams=[{name:dstGasForCall, type:uint256, order:1, indexed:false, value:360000, valueString:360000}, {name:dstNativeAmount, type:uint256, order:2, indexed:false, value:0, valueString:0}, {name:dstNativeAddr, type:bytes, order:3, indexed:false, value:0x83927E6D27967DA8FCCE9A2FE6079B5655DD22B0, valueString:0x83927E6D27967DA8FCCE9A2FE6079B5655DD22B0}], _to=0xF314FA27066BDDE92E6122059B103E8899D0A096, _payload=0x0000000000000000000000000000000000000000000000000B2FBDEFB9F519B000000000000000000000000083927E6D27967DA8FCCE9A2FE6079B5655DD22B0000000000000000000000000EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE000000000000000000000000000000000000000000000000004657183DF453FF )
crossSwap[WooCrossChainRouterV2 (ln:56)]
deposit[WooCrossChainRouterV2 (ln:75)]
safeTransferFrom[WooCrossChainRouterV2 (ln:78)]
call[TransferHelper (ln:811)]
encodeWithSelector[TransferHelper (ln:811)]
decode[TransferHelper (ln:813)]
contains[WooCrossChainRouterV2 (ln:84)]
safeApprove[WooCrossChainRouterV2 (ln:85)]
call[TransferHelper (ln:786)]
encodeWithSelector[TransferHelper (ln:786)]
decode[TransferHelper (ln:788)]
swap[WooCrossChainRouterV2 (ln:86)]
payable[WooCrossChainRouterV2 (ln:91)]
balanceOf[WooCrossChainRouterV2 (ln:102)]
_bridgeByOFT[WooCrossChainRouterV2 (ln:109)]
token[WooCrossChainRouterV2 (ln:304)]
safeApprove[WooCrossChainRouterV2 (ln:309)]
call[TransferHelper (ln:786)]
encodeWithSelector[TransferHelper (ln:786)]
decode[TransferHelper (ln:788)]
encode[WooCrossChainRouterV2 (ln:314)]
_getDstGasForCall[WooCrossChainRouterV2 (ln:315)]
_getAdapterParams[WooCrossChainRouterV2 (ln:318)]
minDstGasLookup[WooCrossChainRouterV2 (ln:277)]
LzCallParams[WooCrossChainRouterV2 (ln:319)]
payable[WooCrossChainRouterV2 (ln:320)]
sendAndCall[WooCrossChainRouterV2 (ln:326)]
_bridgeByStargate[WooCrossChainRouterV2 (ln:111)]
encode[WooCrossChainRouterV2 (ln:349)]
_getLzTxObj[WooCrossChainRouterV2 (ln:352)]
_getDstGasForCall[WooCrossChainRouterV2 (ln:288)]
lzTxObj[WooCrossChainRouterV2 (ln:289)]
withdraw[WooCrossChainRouterV2 (ln:354)]
deposit[WooCrossChainRouterV2 (ln:356)]
safeApprove[WooCrossChainRouterV2 (ln:357)]
call[TransferHelper (ln:786)]
encodeWithSelector[TransferHelper (ln:786)]
decode[TransferHelper (ln:788)]
safeApprove[WooCrossChainRouterV2 (ln:359)]
call[TransferHelper (ln:786)]
encodeWithSelector[TransferHelper (ln:786)]
decode[TransferHelper (ln:788)]
swap[WooCrossChainRouterV2 (ln:361)]
payable[WooCrossChainRouterV2 (ln:365)]
_msgSender[WooCrossChainRouterV2 (ln:365)]
WooCrossSwapOnSrcChain[WooCrossChainRouterV2 (ln:113)]
_msgSender[WooCrossChainRouterV2 (ln:115)]
File 1 of 4: WooCrossChainRouterV2
File 2 of 4: WETH9
File 3 of 4: StargateEthVault
File 4 of 4: StargateComposer
12345678910111213141516// SPDX-License-Identifier: MITpragma solidity =0.8.14;// OpenZeppelin Contractsimport {IERC20} from "@openzeppelin/contracts/token/ERC20/IERC20.sol";import {Ownable} from "@openzeppelin/contracts/access/Ownable.sol";import {ReentrancyGuard} from "@openzeppelin/contracts/security/ReentrancyGuard.sol";import {EnumerableSet} from "@openzeppelin/contracts/utils/structs/EnumerableSet.sol";import {ICommonOFT, IOFTWithFee} from "@layerzerolabs/solidity-examples/contracts/token/oft/v2/fee/IOFTWithFee.sol";// Local Contractsimport {IWETH} from "./interfaces/IWETH.sol";import {IWooCrossChainRouterV2} from "./interfaces/IWooCrossChainRouterV2.sol";import {IWooRouterV2} from "./interfaces/IWooRouterV2.sol";import {IStargateEthVault} from "./interfaces/Stargate/IStargateEthVault.sol";import {IStargateRouter} from "./interfaces/Stargate/IStargateRouter.sol";import {ILzApp} from "./interfaces/LayerZero/ILzApp.sol";import {TransferHelper} from "./libraries/TransferHelper.sol";
File 2 of 4: WETH9
12345678910111213141516// Copyright (C) 2015, 2016, 2017 Dapphub// This program is free software: you can redistribute it and/or modify// it under the terms of the GNU General Public License as published by// the Free Software Foundation, either version 3 of the License, or// (at your option) any later version.// This program is distributed in the hope that it will be useful,// but WITHOUT ANY WARRANTY; without even the implied warranty of// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the// GNU General Public License for more details.// You should have received a copy of the GNU General Public License// along with this program. If not, see <http://www.gnu.org/licenses/>.pragma solidity ^0.4.18;
File 3 of 4: StargateEthVault
12345678910111213141516// Copyright (C) 2015, 2016, 2017 Dapphub// This program is free software: you can redistribute it and/or modify// it under the terms of the GNU General Public License as published by// the Free Software Foundation, either version 3 of the License, or// (at your option) any later version.// This program is distributed in the hope that it will be useful,// but WITHOUT ANY WARRANTY; without even the implied warranty of// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the// GNU General Public License for more details.// You should have received a copy of the GNU General Public License// along with this program. If not, see <http://www.gnu.org/licenses/>.pragma solidity ^0.7.6;import "@openzeppelin/contracts/access/Ownable.sol";import "@openzeppelin/contracts/utils/ReentrancyGuard.sol";import "./interfaces/IStargateEthVault.sol";// This contract always UNWRAPS the erc20 for native gas token on transfer + transferFrom.
File 4 of 4: StargateComposer
12345678910111213141516// SPDX-License-Identifier: UNLICENSEDpragma solidity 0.7.6;pragma abicoder v2;import "@openzeppelin/contracts/utils/ReentrancyGuard.sol";import "@openzeppelin/contracts/access/Ownable.sol";import "@openzeppelin/contracts/utils/Address.sol";import "@openzeppelin/contracts/token/ERC20/IERC20.sol";import "@openzeppelin/contracts/token/ERC20/SafeERC20.sol";import "@openzeppelin/contracts/math/SafeMath.sol";import "./interfaces/IStargateRouter.sol";import "./interfaces/IStargateReceiver.sol";import "./interfaces/IStargateEthVault.sol";import "./util/BytesLib.sol";import "./util/SafeCall.sol";interface IStargateBridge {function quoteLayerZeroFee(