# Lido Bridge Contract
###### tags: `Aztec Connect`, `Public`
Lido is a protocol that allows users to stake ETH against the ETH 2.0 beacon chain.
They allow users to deposit less than the 32 ETH minimum for a validator and give the users a liquid representation of their staked ETH stETH.
### Pre-notes
This document describes one user flow. Later on we may want to use a second flow that may save gas costs for Lido via batching deposits to the Deposit Contract.
### wstETH Flow
As stETH is a re-balancing token, we must use wstETH. This gives users a stable balance and allow the tokens to go inside the rollup. A more complicated flow would be to use virtual assets, and have the bridge contract use the funds. This was ruled out as the virtual assets are not fungible with other bridge contracts.
As a result this flow will return wstETH to the user on Aztec.
**User Flow**
1. User has ETH on Aztec.
2. User creates a DeFi deposit proof on Aztec to interact with the Lido DeFi bridge with a portion of their shielded ETH.
3. This bridge is synchronous and will return wstETH to the user.
4. A rollup provider will batch 28 transactions over a 6 hour period, and send these in a rollup.
5. User receives their pro-rata share of wstETH on Aztec.
When the bridge contract receives an aggregated transaction from the rollup contract, the following will happen:
1. The bridge contract will send the ETH to the wstETH contract which has a shortcut to auto wrap.
2. The bridge contract will return the change in balance of wstETH to the rollup.
Gas analysis
| Item | Gas | User Share |
| ------------------------ | ------ | ---------- |
| JoinSplit for chaining | 7,500 | 1 |
| DeFi Bridge Deposit | 7,500 | 1 |
| Lido transfer(auto wrap) | 75,000 | 1/n |
| Transfer wstETH to rollup | 50,000 | 1/n |
| DeFi claim proof | 7,500 | 1 |
Main-net: ~85,000
Batch Size 10: gas = 35,000 ~2.2x
Batch Size 50: gas = 25,00 ~3x
Batch Size 100: gas = 23,750 ~4x
**Pros**
1. Very simple
2. Doesn't require virtual assets.
**Cons**
1. If the user wants to do a DeFi action involving stETH the bridge will need to unwrap wstETH > stETH. This is a 90k gas overhead. This is okay with batches of 10+.
2. Liquidity mining LDO tokens can't be given to the user. These will be owned by the bridge contract. They could be used to subsidise tx costs.
----- Notes From Call
12pm utc oracle update 24 hours