Beginner FriendlyDeFiFoundry
100 EXP
View results
Submission Details
Severity: medium
Valid

`quitTheGang` allows any gang member to remove any other gang member but they should not be allowed to do so.

Summary

The quitTheGang should only allow the caller gang member to quit the gang but a gang member can pass any other gang member's address and remove them from the gang.

Vulnerability Details

  • The vulnerability is present in the quitTheGang function where it is meant for a particular gang member to quit. But instead it allows a gang member to remove any other gang member from their gang.

  • The gang member doesn't have the privilege to remove any other gang member except self, but still they are allowed to remove other members from the gang.

Impact

Allows a gang member to remove any gang members.

Tools Used

Manual Review

Recommendations

Instead of taking account as argument from the gang member, use msg.sender as the account so that only the caller is quitting.

Updates

Lead Judging Commences

n0kto Lead Judge about 1 year ago
Submission Judgement Published
Validated
Assigned finding tags:

Gang members ban other members

Support

FAQs

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