| Severity | Impact | Likelihood |
|---|---|---|
| CRITICAL | High | High |
Scope: programs/rustfund/src/lib.rs:25-52
In a crowdfunding platform, contributors should be able to get refunds if the campaign fails to meet its goal. The Contribution account stores the amount each user contributed via contribution.amount, which is then used in the refund() function to return funds.
The contribute() function transfers SOL from the contributor to the fund and increments fund.amount_raised, but never updates contribution.amount. This means the contribution tracking is broken - all contributions are recorded as 0, making refunds worthless.
Likelihood: High
Every single contribution to any campaign triggers this bug
The missing line of code means 100% of contributions are affected
Impact: High
Contributors permanently lose all contributed SOL with no way to recover
Refunds return 0 lamports regardless of actual contribution amount
Complete loss of user funds - the most severe impact category
The contest is live. Earn rewards by submitting a finding.
Submissions are being reviewed by our AI judge. Results will be available in a few minutes.
View all submissionsThe contest is complete and the rewards are being distributed.