The _rebalanceLiquidity function fails to rebalance liquidity when the reserve token enforces a strict zero-approval policy (e.g., USDT). The _depositIntoVault function directly approves the curveVault without resetting approval to zero, causing perpetual transaction reverts if a previous approval exists.
In the _depositIntoVault function:
Tokens like USDT and KNC require resetting approvals to zero before granting a new one.
If reserve.reserveAssetAddress is USDT and a non-zero approval already exists, the approve call reverts.
This halts liquidity rebalancing, preventing excess liquidity from being deposited into the Curve vault.
Liquidity Management Disruption: Protocol fails to maintain the desired liquidity buffer.
Manual code review.
Update _depositIntoVault to handle tokens with strict approval policies:
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.