File tree 1 file changed +18
-0
lines changed
1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -14,6 +14,24 @@ import "./interfaces/SpokePoolInterface.sol";
14
14
contract SpokePoolVerifier {
15
15
using Address for address ;
16
16
17
+ /**
18
+ * @notice Passthrough function to `deposit()` on the SpokePool contract.
19
+ * @dev Protects the caller from losing their ETH (or other native token) by reverting if the SpokePool address
20
+ * they intended to call does not exist on this chain. Because this contract can be deployed at the same address
21
+ * everywhere callers should be protected even if the transaction is submitted to an unintended network.
22
+ * This contract should only be used for native token deposits, as this problem only exists for native tokens.
23
+ * @param spokePool Address of the SpokePool contract that the user is intending to call.
24
+ * @param recipient Address to receive funds at on destination chain.
25
+ * @param originToken Token to lock into this contract to initiate deposit.
26
+ * @param amount Amount of tokens to deposit. Will be amount of tokens to receive less fees.
27
+ * @param destinationChainId Denotes network where user will receive funds from SpokePool by a relayer.
28
+ * @param relayerFeePct % of deposit amount taken out to incentivize a fast relayer.
29
+ * @param quoteTimestamp Timestamp used by relayers to compute this deposit's realizedLPFeePct which is paid
30
+ * to LP pool on HubPool.
31
+ * @param message Arbitrary data that can be used to pass additional information to the recipient along with the tokens.
32
+ * Note: this is intended to be used to pass along instructions for how a contract should use or allocate the tokens.
33
+ * @param maxCount used to protect the depositor from frontrunning to guarantee their quote remains valid.
34
+ */
17
35
function deposit (
18
36
SpokePoolInterface spokePool ,
19
37
address recipient ,
You can’t perform that action at this time.
0 commit comments