In the createOffer
function of the PreMarkets
contract, the check for the eachTradeTax
parameter should revert if eachTradeTax is greater than or equal to Constants.EACH_TRADE_TAX_DECIMAL_SCALER
. The current implementation only checks if it is greater, potentially allowing invalid tax rates.
The check for eachTradeTax
ensures it is less than Constants.EACH_TRADE_TAX_DECIMAL_SCALER
, but does not account for values equal to the scaler.
Allowing eachTradeTax
to be equal to Constants.EACH_TRADE_TAX_DECIMAL_SCALER
can lead to invalid tax rates, potentially causing financial losses or unfair trades.
Manual Review
Update the check for eachTradeTax
to ensure it is strictly less than Constants.EACH_TRADE_TAX_DECIMAL_SCALER
.
Similar to issue #1323, Despite this off-by-one error of the intended check, the difference between 99% and 100% is minimal, so I believe whether or not 100% is allowed has minimal impact. Ultimately, takers should not be realistically creating offer with such tradeTax
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.