DatingDapp

First Flight #33
Beginner FriendlyFoundrySolidityNFT
100 EXP
View results
Submission Details
Severity: high
Invalid

Multisig wallet will revert after every function call due to the onlyOwners() modifier

Summary

The MultiSig.sol::onlyOwners() modifier checks the msg.sender, however, it checks whether the msg.sender is equal to owner1 AND equal to owner2 or not. This will cause the modifier to revert every time a function is called since an address cannot be equal to two different addresses at the same time.

Vulnerability Details

This would be a critical vulnerability since the MultiSig.sol contract would be rendered useless as not a single function call would execute successfully.

Impact

The wallet would not be able to execute any transactions at all, the wallet would be unable to use.

Tools Used

Manual Review

Recommendations

modifier onlyOwners() {
- if (msg.sender != owner1 && msg.sender != owner2) revert NotAnOwner();
+ if (msg.sender != owner1 || msg.sender != owner2) revert NotAnOwner();
_;
}
Updates

Appeal created

n0kto Lead Judge 5 months ago
Submission Judgement Published
Invalidated
Reason: Incorrect statement

Support

FAQs

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