Eggstravaganza

First Flight #37
Beginner FriendlySolidity
100 EXP
View results
Submission Details
Severity: low
Invalid

Missing Input Validation in EggstravaganzaNFT Constructor

Summary

The EggstravaganzaNFT contract's constructor lacks input validation for _name and _symbol parameters, allowing empty strings to be set.

Vulnerability Details

The constructor accepts string parameters without any validation. This could lead to display issues in NFT marketplaces and wallets, affecting user experience and contract integration.

constructor(string memory _name, string memory _symbol)
ERC721(_name, _symbol) Ownable(msg.sender)
{
// no validations
}

Impact

Low as it doesn't affect core contract functionality or security.

Tools Used

Manual code review

Recommendations

Add input validation in the constructor. Example:

require(bytes(_name).length > 0, "Name cannot be empty");
require(bytes(_symbol).length > 0, "Symbol cannot be empty");
Updates

Lead Judging Commences

m3dython Lead Judge about 2 months ago
Submission Judgement Published
Invalidated
Reason: Out of scope

Support

FAQs

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