Function: bridgeTokenConnext(address token, address arbEscrow, uint256 amount, uint256 slippage, uint256 relayerFee)
The function is called by the owner after the break timestamp to bridge Renzo restaked ETH tokens to the L2.
Inputs
tokenControl: Fully controlled by the caller.
Constraints: No constraints.
Impact: Address of the token contract.
arbEscrowControl: Fully controlled by the caller.
Constraints: No constraints.
Impact: Address receiving the funds on the destination.
amountControl: Fully controlled by the caller.
Constraints: No constraints.
Impact: Amount of tokens to transfer.
slippageControl: Fully controlled by the caller.
Constraints: No constraints.
Impact: The maximum amount of slippage the user will accept in BPS (e.g., 30 = 0.3%).
relayerFeeControl: Fully controlled by the caller.
Constraints: No constraints.
Impact: The fee payed to the relayer.
Branches and code coverage
Intended branches
Increases the allowance for the
tokenof therenzoLockboxcontract and deposits the token amount to that contract.Increases the allowance for the
xtokenof theconnextcontract and callsconnext.xcallto start the bridging.
Negative behavior
N/A.
Function call analysis
SafeERC20.safeIncreaseAllowance(IERC20(token), address(this.renzoLockbox), amount)What is controllable?
tokenandamount.If the return value is controllable, how is it used and how can it go wrong? N/A.
What happens if it reverts, reenters or does other unusual control flow? If it reverts, the entire transaction would revert — no reentrancy scenario.
this.renzoLockbox.deposit(amount)What is controllable?
amount.If the return value is controllable, how is it used and how can it go wrong? N/A.
What happens if it reverts, reenters or does other unusual control flow? If it reverts, the entire transaction would revert — no reentrancy scenario.
SafeERC20.safeIncreaseAllowance(IERC20(address(xToken)), address(this.connext), amount)What is controllable?
amount.If the return value is controllable, how is it used and how can it go wrong? N/A.
What happens if it reverts, reenters or does other unusual control flow? If it reverts, the entire transaction would revert — no reentrancy scenario.
this.connext.xcall{value: relayerFee}(1634886255,arbEscrow,address(xToken),msg.sender,amount,slippage,bytes(""))What is controllable?
arbEscrow,msg.sender,amount, andslippage.If the return value is controllable, how is it used and how can it go wrong? N/A.
What happens if it reverts, reenters or does other unusual control flow? If it reverts, the entire transaction would revert — no reentrancy scenario.