Normal Behavior: A new bid should be at least 5 higher than the previous bid, as defined by S_MIN_BID_INCREMENT_PERCENTAGE.
Specific Issue: The calculation for the minimum required subsequent bid uses integer division: (previousBidAmount / 100) * (100 + S_MIN_BID_INCREMENT_PERCENTAGE). This logic truncates the fractional part when dividing previousBidAmount by 100. For small previousBidAmount values, this truncation dramatically reduces the required increment, allowing the new bid to be only slightly more than the previous one, thus bypassing the intended 5 increase.
Example: If previousBidAmount is 104 wei, 104/100 is 1 (integer division). The requiredAmount becomes 1×105=105 wei. This means the user only needed to increase the bid by 1 wei (105−104), far less than the intended 5.2 wei.
Likelihood:
The flaw is guaranteed to manifest for any bid amount not divisible by 100.
This occurs frequently for low-value bids, where precision is most critical.
Impact:
Auction Integrity Flaw. Undermines the integrity of the auction rules, allowing malicious users to game the bidding system with minimal financial commitment.
This PoC demonstrates a previous bid of 104 wei only requiring a 1 wei increment, instead of the 5 minimum.
The order of operations must be changed to perform multiplication before division to prevent truncation. This preserves precision and ensures the required percentage increase is met.
Integer division in requiredAmount truncates fractions, allowing bids slightly lower than intended.
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.