Beginner FriendlyFoundry
100 EXP
View results
Submission Details
Severity: high
Valid

Anyone can update owner's password

Summary

Any EOA can update owner's password

Vulnerability Details

  • Access modifier setPassword is external, but it does not implement any authentication mechanism, like onlyOwner.

  • This allows any EOA to update the state variable called s_password freely.

Impact

  • Very high.

Tools Used

  • Manual inspection

Recommendations

  • Implement OpenZeppelin's Ownable contract for authenticating the owner of the PasswordStore.

  • Then, add onlyOwner modifier to the setPassword function to allow only the owner to set the password.

Updates

Lead Judging Commences

inallhonesty Lead Judge
over 1 year ago
inallhonesty Lead Judge over 1 year ago
Submission Judgement Published
Validated
Assigned finding tags:

finding-lacking-access-control

Anyone can call `setPassword` and set a new password contrary to the intended purpose.

Support

FAQs

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