The _withdrawFromVault function in the LendingPool contract attempts to withdraw assets from the Curve vault without first approving the vault to spend the shares owned by the lending pool. Since shares are minted to the lending pool (address(this)), the contract needs to approve the vault to spend its shares before withdrawal.
The issue occurs because:
During deposit, shares are minted to address(this) (LendingPool)
When withdrawing, the contract needs to approve the vault to spend its shares
No approval is given before calling withdraw()
The transaction will revert due to insufficient allowance
All withdrawals from Curve vault will fail
Protocol cannot access deposited assets
Could lead to locked funds in Curve vault
Add share approval before withdrawal:
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.