Description:Description\
The subtraction may silently underflow because it's in an unchecked block with no preceding value checks, which may lead to unexpected results
Proof of Concept (PoC) File
file: /CatalystVaultAmplified.sol
114 unchecked {
// Amplification is stored as 1 - amp since most equations uses amp this way.
_oneMinusAmp = int256(FixedPointMathLib.WAD - amp);
_targetAmplification = int256(FixedPointMathLib.WAD - amp);
}
1538 unchecked {
// Amplification is stored as 1 - amp since most equations uses amp this way.
_oneMinusAmp = int256(FixedPointMathLib.WAD - amp);
_targetAmplification = int256(FixedPointMathLib.WAD - amp);
}
Github username: @saidqayoumsadat Twitter username: saqsadat143 Submission hash (on-chain): 0x2bf62b1934129003366ed13bf8720d10490b1108e32214242e63b929ab8b10be Severity: low
Description: Description\ The subtraction may silently underflow because it's in an unchecked block with no preceding value checks, which may lead to unexpected results
https://github.com/catalystdao/catalyst/blob/27b4d0a2bca177aff00def8cd745623bfbf7cb6b/evm/src/CatalystVaultAmplified.sol#L114C1-L119C1
https://github.com/catalystdao/catalyst/blob/27b4d0a2bca177aff00def8cd745623bfbf7cb6b/evm/src/CatalystVaultCommon.sol#L262C1-L266C10