code-423n4 / 2024-03-saltyio-mitigation-findings

0 stars 0 forks source link

M-09 MitigationConfirmed #14

Open c4-bot-1 opened 7 months ago

c4-bot-1 commented 7 months ago

Lines of code

Vulnerability details

Lines of code

https://github.com/othernet-global/salty-io/blob/main/src/pools/Pools.sol#L201

Vulnerability details

Summary

M-09 highlighted the typo error where reserve0 was used twice and reserve1 was missing:

    require((reserves.reserve0 >= PoolUtils.DUST) && (reserves.reserve0 >= PoolUtils.DUST), "Insufficient reserves after liquidity removal");

Mitigation

This has been corrected now on L201:

    require((reserves.reserve0 >= PoolUtils.DUST) && (reserves.reserve1 >= PoolUtils.DUST), "Insufficient reserves after liquidity removal");

Fixed.

c4-judge commented 7 months ago

Picodes marked the issue as satisfactory

c4-judge commented 7 months ago

Picodes marked the issue as confirmed for report