<!-- canonical: https://0xsimao.com/findings/districtone-participate-specifying-shares-overfund -->

# FairLauncher::participate() should allow specifying a minimum number of shares due to the overfund mechanism

Medium · Three Sigma · Social money games · 13th June, 2024

Finding 3S-D1-M02 of the DistrictOne security review.

- Protocol: https://districtone.io/
- Report: /reports/districtone
- Source: https://cdn.sanity.io/files/qoqld077/production/fd2142f1d189dd29db23dff49d4018d4da9c01d6.pdf

---

### Description

Users receive discounted shares when they participate in FairLauncher::participate()
but the amount raised has exceeded the hard cap set. Thus, users may be frontrunned
when participating, receiving less shares than expected. Maliciously frontrunning on Blast
is not possible because the sequencer is centralized and FIFO, but users may still be
organically frontrunned.

### Recommendation

Attackers can not exploit this but users may still be harmed. A minimum shares amount
parameter would be advisable.

### Status

Acknowledged

---

Related findings:

- [_rebalanceWithdraw() mechanism in glAVAX allows arbitrage opportunities by changing the shares/AVAX ratio](https://0xsimao.com/findings/glacier-withdraw-arbitrage-opportunities-shares): Glacier
- [It's possible to mint an infinite number of shares without increasing quote or base amounts, due to rounding down](https://0xsimao.com/findings/nftperp-ii-mint-infinite-shares-rounding): Nftperp Matching Engine
- [Allow lenders to set a minimum amount of asset they would take for their shares](https://0xsimao.com/findings/maple-finance-ii-lenders-minimum-they-shares): Maple Withdrawal Manager
