Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mint can be front-run #20

Open
code423n4 opened this issue Apr 29, 2021 · 0 comments
Open

Mint can be front-run #20

code423n4 opened this issue Apr 29, 2021 · 0 comments
Labels
1 (Low Risk) bug Something isn't working

Comments

@code423n4
Copy link
Contributor

Handle

cmichel

Vulnerability details

Vulnerability Details

The price of an MFT falls over time which creates a dynamic that one potential buyers want to wait for the price to drop but also not wait too long to avoid hitting the max sale cap.
However, on public blockchains any such mint call can be observed and attackers can simply wait until another person decides to buy at the current price and then frontrun that person.

Impact

Legitimate minters can be frontrun and end up with a failed transaction and without the NFT as the max sale limit is reached: require(numSales < SALE_LIMIT, "Sale limit reached.");

Recommended Mitigation Steps

Front-running is hard to prevent, maybe an auction-style minting process could work where the top SALE_LIMIT bids are accepted after the sale duration.

@code423n4 code423n4 added 1 (Low Risk) bug Something isn't working labels Apr 29, 2021
code423n4 added a commit that referenced this issue Apr 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1 (Low Risk) bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant