Inconsistencies of WETH across chains can cause incorrect functionality of the protocol #429
Labels
3 (High Risk)
Assets can be stolen/lost/compromised directly
bug
Something isn't working
duplicate-333
sufficient quality report
This report is of sufficient quality
unsatisfactory
does not satisfy C4 submission criteria; not eligible for awards
Lines of code
https://github.com/code-423n4/2024-01-decent/blob/07ef78215e3d246d47a410651906287c6acec3ef/src/UTB.sol#L8
Vulnerability details
Proof of Concept
According to the README and sponsors, the codebase is expected to support all chains (EVM and non-EVM) that LayerZero supports.
Although all chains are expected to be supported, there are some inconsistencies of the WETH token across these chains. These inconsistencies can cause incorrect functionality of the protocol, DOS of the protocol and failed deployments.
Here are the inconsistencies:
WETH is not deployed on all chains that LayerZero supports
The contracts below are compared to this WETH contract on Ethereum mainnet.
Binance => BEP20 => does not have WETH but BEP20, no deposit/withdraw functions
Avalanche => WETH => no deposit/withdraw functions
Aptos (non-evm) => zWETH => Uses Layerzero Wrapped Ether (zWETH), uses 6 decimals not 18
Polygon => WETH => function signature for deposit() function is different and can only be called by ChildChainManager
Fantom => no WETH contract, it has fETH
Moonbeam => WETH => no deposit/withdraw functions
Fuse => WETH => no deposit/withdraw functions
Gnosis chain => WETH => no deposit/withdraw functions
zkSync era => WETH => no deposit/withdraw functions
Tenet => WETH => no deposit/withdraw functions
Astar => WETH => no deposit/withdraw functions
Horizen EON => WETH => no deposit/withdraw functions
Impacts of the inconsistencies:
LayerZero supported chains which work fine with WETH:
Note: I've manually confirmed each of these inconsistencies on every LayerZero supported chain through block explorers. To ensure no chain is missed out, consider cross-checking the WETH contracts.
Tools Used
Manual Review
Recommended Mitigation Steps
Assessed type
Other
The text was updated successfully, but these errors were encountered: