The strategy functions _allocate and _deallocate only return the nominal amount allocated or withdrawn, without reflecting any profit accrued over time. As a result, when attempting to deallocate after yield accumulation, the computed new allocation can underflow and cause a revert.
Vulnerability Details
Initially, suppose the allocation is x.
Because both _allocate and _deallocate return the raw principal amounts, accrued interest I is not reflected in these values. After some time, the true allocation becomes:
new_allocation = x + I
However, during deallocation, the strategy calculates the updated allocation as:
If the maximum amount (x + I) is deallocated, this becomes:
Since this result is negative and stored in an unsigned integer, it triggers an underflow revert.
Importantly, this issue cannot be bypassed by passing a corrected allocation value (x + I) through a proxy call, because the vault’s internal accounting still records the allocation as x. Thus, any attempt to deallocate using the full accrued amount will still revert due to the vault–strategy mismatch.
Impact
Permanent Loss of Yield — Accrued interest within the vault becomes inaccessible, as deallocation reverts when attempting to withdraw profit-inclusive amounts.
Potential Accounting Mismatch — Some debt tokens may appear undercollateralized, since the vault’s recorded shares cannot be redeemed for the actual underlying assets.