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

setPassword() allows addresses other than the owner to execute it.

Summary

setPassword() is problematic function

Vulnerability Details

setPassword() could be executed from entity different than the owner.

Impact

The password can be changed by address different than the owner.

Tools Used

manual testing

Recommendations

add modifier to check for owner

modifer owner() {
require(owner == msg.sender);
_;
}

and add it to setPassword() function like this:
function setPassword(string memory newPassword) external owner {
}

Updates

Lead Judging Commences

inallhonesty Lead Judge
about 2 years ago
inallhonesty Lead Judge about 2 years 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.