Lack of slippage and deadline protection in deposit(), withdraw() and redeem()
The vault's deposit, withdraw and redeem functions do not let users set a minimum acceptable amount of shares or assets, nor a deadline. An attacker or ordinary price movement could cause a user to receive fewer shares or assets than expected, or have a transaction execute later than intended.
t0x1c Follow with anchabadze, Aristos and 5 others
Originally disclosed on Code4rena
Submitted by t0x1c, also found by anchabadze, Aristos, falconhoof, harsh123, hezze, NexusAudits, and RaOne
Description
- When users deposit funds, those assets are allocated to one or more underlying ERC4626 markets according to the supply queue.
- When withdrawing or redeeming, assets are pulled from the underlying markets according to the withdraw queue and shares burned.
None of these actions allow the user to specify any acceptable slippage or deadline.
- The vault interacts with multiple ERC4626 vaults. Share price in these underlying vaults can change between transaction submission and execution.
- During deposit, the protocol might need to distribute assets across multiple markets based on their caps. This multi-step process could expose users to price changes.
- During withdrawals or redemptions, the protocol attempts to pull assets from markets in a specific order. If a market has insufficient liquidity, the next market is tried, which might have different share pricing.
- The _accrueFee() function is called during both deposit and withdrawal, which can change the conversion rate between shares and assets.
Additionally, there’s a risk of transactions getting stuck in the mempool during periods of network congestion and hence deadline protection is needed.
Impact
User may recieve less than expected shares or assets due to unfavourable price movement or execution delays.
Recommendation
Allow the user to specify paramaters like minShares, minAssets while calling these functions.
IhorSF (Silo Finance) disputed
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the functions lack parameters for minimum output (slippage tolerance) and a transaction deadline, so execution depends entirely on whatever price exists when the transaction is mined.
Impact
A user may receive fewer shares or assets than expected due to price movement or delayed execution; the report does not show a concrete exploit and the finding was disputed by the project.
What the attacker needed
User interacts with the vault; price changes before execution
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
When you put money into a shared investment pool, the number of 'shares' you get depends on the current price. If the price changes between when you send the transaction and when it is processed, you might get fewer shares than you planned. This report says the pool gives you no way to say 'do not accept anything worse than this', so you can lose out.
What is Business logic?
The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.