Ineffective Whitelist
A whitelisted profile creator can mint unlimited profiles and transfer the NFTs to other users, bypassing the intended restriction that only whitelisted accounts should create profiles. This makes the whitelist ineffective for limiting profile creation.
Submitted by cmichel
Creating profiles through LensHub.createProfile requires the caller to be whitelisted.
function _validateCallerIsWhitelistedProfileCreator() internal view {
if (!_profileCreatorWhitelisted[msg.sender]) revert Errors.ProfileCreatorNotWhitelisted();
}
However, a single whitelisted account can create as many profiles as they want and send the profile NFT to other users. They can create unlimited profiles on behalf of other users which makes the whitelist not effective.
Recommended Mitigation Steps
Consider limiting the number of profile creations per whitelisted user or severely limiting who is allowed to create profiles, basically making profile creation a centralized system.
Declined, this is by design.
Governance will decide what contracts are allowed to mint via the allowlist. If governance wishes to have a more centralized system, it will only approve contracts that have numerical caps within their code.
0xleastwood (judge) marked invalid and commented:
I agree with the sponsor, I think this can already be handled by the governance strictly approving contracts with numerical caps or limiting the allowlist of who can create a profile. As such, I’m inclined to mark this as
invalidbecause the recommendation can already be implemented or adhered to by the governance.
0xleastwood (judge) re-assessed as Medium severity and commented:
In light of another issue, I will mark this as a valid issue because #66 outlines a similar concern. The two issues reference different parts of the codebase so I think its fair to keep them distinct. However, I’d normally like to see a bit more detail on how non-whitelisted users can benefit from an infinite minter.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the whitelist only checks the caller's address, not how many profiles they create or who receives them, so a single whitelisted account can mint unlimited profiles.
Impact
A whitelisted user could create unlimited profiles on behalf of others, making the whitelist ineffective; the project team declined this as by design, but the judge later marked it valid.
What the attacker needed
A whitelisted account
The fix
The report recommends limiting the number of profile creations per whitelisted user or severely limiting who is allowed to create profiles, making profile creation a centralized system.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
A whitelist is a list of allowed users. Here, only whitelisted users can create profiles, but one whitelisted user can create many profiles and give them to anyone, so the limit is not really enforced.
What is Business logic?
The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.