Rust Fund

AI First Flight #9
Beginner FriendlyRust
EXP
View results
Submission Details
Impact: low
Likelihood: low
Invalid

No events emitted

Summary

None of fund_create, contribute, set_deadline, refund, or withdraw emit Anchor events — off-chain indexing and monitoring depend on parsing raw instructions.

Root Cause

programs/rustfund/src/lib.rs defines no #[event] structs and calls emit! nowhere. State changes (fund created, contribution received, deadline set, refund paid, withdrawal executed) are invisible to event-based indexers.

Impact

Low severity / Low likelihood: no direct fund loss; degrades observability, alerting, and integration for wallets/dashboards tracking the crowdfunding lifecycle.

PoC

Inspect any of the five handlers — no emit! calls; no #[event] types exist in the program. (Verified by code inspection.)

Mitigation

Define #[event] structs (e.g. FundCreated, ContributionMade, DeadlineSet, Refunded, Withdrawn) and emit! them in the respective handlers.

Review notes

Access control on privileged fns (has_one = creator + Signer) and checked math on the transfers themselves were verified sound.

Updates

Lead Judging Commences

ai-first-flight-judge Lead Judge about 1 hour ago
Submission Judgement Published
Invalidated
Reason: Incorrect statement

Support

FAQs

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

Give us feedback!