Beginner FriendlyFoundry
100 EXP
View results
Submission Details
Severity: low
Invalid

Certain Inputs to MulWad() can yield out of gas errors

Summary

By executing MathMaster's MulWad() function with specifically:
uint256 x = 0x00021005ddc2e4297aad49826105766555afffffffffffffffffffffffffffff
uint256 y = 0x00010b6116ce4a0d0374bb732db67a839ef49244e3bfb5876546e9d878000003

One can consistently spend more gas than is allocated to begin with. A call with these values would result in a reverted TX.

Vulnerability Details

Function does not process these inputs efficiently, low impact to protocol overall.

Impact

Reverted TXs to some users.

Tools Used

Foundry, Halmos

Recommendations

Recommended to implement a validation mechanism within the function. This would preemptively check for input values that could result in gas inefficiencies or cause transactions to revert.

Updates

Lead Judging Commences

inallhonesty Lead Judge
over 1 year ago
inallhonesty Lead Judge over 1 year ago
Submission Judgement Published
Invalidated
Reason: Incorrect statement

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.