Commit 1e02b203 authored by Maurelian's avatar Maurelian

contracts: Fix OZ-N-01 ETH can be stolen

parent 82108382
...@@ -175,6 +175,7 @@ contract L2StandardBridge is StandardBridge { ...@@ -175,6 +175,7 @@ contract L2StandardBridge is StandardBridge {
) internal { ) internal {
address l1Token = OptimismMintableERC20(_l2Token).l1Token(); address l1Token = OptimismMintableERC20(_l2Token).l1Token();
if (_l2Token == Lib_PredeployAddresses.OVM_ETH) { if (_l2Token == Lib_PredeployAddresses.OVM_ETH) {
require(msg.value == _amount, "ETH withdrawals must include sufficient ETH value.");
_initiateBridgeETH(_from, _to, _amount, _minGasLimit, _data); _initiateBridgeETH(_from, _to, _amount, _minGasLimit, _data);
} else { } else {
_initiateBridgeERC20(_l2Token, l1Token, _from, _to, _amount, _minGasLimit, _data); _initiateBridgeERC20(_l2Token, l1Token, _from, _to, _amount, _minGasLimit, _data);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment