Beginner FriendlyFoundryNFT
100 EXP
View results
Submission Details
Severity: low
Invalid

Functions set_minter, transfer_ownership, and renounce_ownership are non-functional and can be removed

Summary

External functions set_minter(), transfer_ownership(), and renounce_ownership() have no effect and can be safely removed.

Vulnerability Details

set_minter() is only used in conjunction with snekmate's safe_mint() function which is not exposed in the contract. The minter role has no effect for the current smart contract. Therefore, the set_minter() function is unnecessary.

Similarly, there are no functions that are using the owner role, making the transfer_ownership() and renounce_ownership() functions unnecessary.

Impact

Low: Removing the functions has no impact on the smart contract functionality but improves readability and makes it more clear that the contract cannot be "rugged" by the contract deployer.

Tools Used

Manual code inspection.

Recommendations

Remove ERC721.set_minter, ERC721.transfer_ownership, and ERC721.renounce_ownership from the list of exports in contracts/snek_raffle.py.

Updates

Lead Judging Commences

inallhonesty Lead Judge over 1 year ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity

Support

FAQs

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