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

A new NFT contract is created for every account and mint no NFT.

Description

MondrianWallet is the deployed contract used to create a new account abstraction. A new instance of this contract is deployed every time an account is created. The problem is that ERC721 does not operate this way. Only one contract should be deployed once and the mint function should be used to create NFTs in the same collection.

Moreover, even though every contract instantiates the ERC721, the mint function is never called and there is no function to call it. This means wallets will never receive a painting.

@> contract MondrianWallet is Ownable, ERC721, IAccount {
...
}

Risk

Likelyhood: High

  • Every account creation.

Impact: High

  • One collection per wallet (no collection will be the official one).

  • No NFTs are distributed.

Recommended Mitigation

Create one smart contract dedicated to the NFT and link it with a factory contract that creates every instance of MondrianWallet. For every creation, mint an NFT and send it to the newly created account.

Updates

Lead Judging Commences

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

Extremely Wrong Implementation of ERC721

Support

FAQs

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