GivingThanks

First Flight #28
Beginner FriendlyFoundry
100 EXP
View results
Submission Details
Severity: high
Valid

Anyone can update _registry by calling updateRegistry()

Summary

Anyone can call the GivingThanks contract and update the registry address.

We should make sure that only owner can update the registry.

Vulnerability Details

Impact

Tools Used

Recommendations

Add a require() statement before updating registry as:

function updateRegistry(address _registry) public {
require(msg.sender == owner, "Only admin can update");
registry = CharityRegistry(_registry);
}
Updates

Lead Judging Commences

n0kto Lead Judge 10 months ago
Submission Judgement Published
Validated
Assigned finding tags:

finding-anyone-can-change-registry

Likelyhood: High, anyone can change it at anytime Impact: High, can bypass the verification process

Support

FAQs

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