MathMasters::mulWalUp
contains the block of code below.
Since z
is always 0 at this step, it has the following behavior:
If , increment x by 1.
Because of the rounded-down division of the EVM, every time , the condition will be true.
This increment will break the calculation because it makes no sense to increment in order to find the result of a multiplication and a division.
Likelihood: High
Every time
Impact: High
Function will return a wrong answer, leading to unexpected behavior on all contracts using this library.
Remove all the parts incrementing x
.
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.