You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Generally speaking, at least for subtraction and division, we are not using SafeMath for input validation, so having underflows or zero divisions would likely mean a bug. Having assert instead of require would allow some of these bugs to be caught by tools like Echidna.
As we have already deployed to mainnet, we don’t plan to do much changens to contracts in the short term.
To change this, we should analyze first all the usages of Safe Math along our code base, and make sure that legit reverts like for instance due to user input are properly protected.
If you still feel like you want to give it a try, I would be happy to review it and help.
Generally speaking, at least for subtraction and division, we are not using SafeMath for input validation, so having underflows or zero divisions would likely mean a bug. Having
assert
instead ofrequire
would allow some of these bugs to be caught by tools like Echidna.Some references:
OpenZeppelin/openzeppelin-contracts#1120
https://media.consensys.net/when-to-use-revert-assert-and-require-in-solidity-61fb2c0e5a57
The text was updated successfully, but these errors were encountered: