Open c4-bot-10 opened 8 months ago
raymondfam marked the issue as sufficient quality report
raymondfam marked the issue as duplicate of #18
See #18.
raymondfam marked the issue as duplicate of #22
raymondfam marked the issue as duplicate of #181
3docSec marked the issue as not a duplicate
3docSec marked the issue as duplicate of #18
3docSec changed the severity to QA (Quality Assurance)
3docSec marked the issue as grade-b
Lines of code
https://github.com/code-423n4/2024-03-coinbase/blob/main/src/SmartWallet/MultiOwnable.sol#L97-L110
Vulnerability details
Impact
Malicious owner through the removeOwnerAtIndex() can remove other owners and make themselves the sole owner of the wallet. This is because the function's access modifiers only needs one owner executing this call to remove other owners.
Peradventure we have a wallet with 20 owners, a malicious owner on a rogue move can remove all other owners and gain sole access to the contract and gain access to all the funds in it.
Proof of Concept
The only owner access control modifier
The check _onlyOwner() function which only needs one owner to valid to execute removeOwnerAtIndex()
Tools Used
Manual review, vs code
Recommended Mitigation Steps
removeOwnerAtIndex() should only be executed by address.this following a consensus decision from all wallet owners.
Assessed type
Access Control