The LendingPool::_withdrawFromVault() function incorrectly sets the owner parameter of the Curve vault.withdraw() function to msg.sender. According to the Curve Vault implementation, the owner parameter should be the address holding the vault shares, which is the LendingPool contract itself (address(this)). This incorrect integration causes withdrawals from the Curve Vault to fail.
In _depositIntoVault(), vault shares are sent to the LendingPool contract (address(this)):
The owner parameter in the curveVault.withdraw() function is set to msg.sender, but it should be address(this) (the LendingPool contract) because the LendingPool is the owner of the vault shares. This mismatch prevents the withdrawal from succeeding, as the Curve Vault expects the share owner to authorize the withdrawal:
Withdrawals from the Curve Vault will fail, preventing the LendingPool from retrieving assets from the Curve vault.
vscode
Update the _withdrawFromVault() function to set the owner parameter to address(this) (the LendingPool contract).
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.