withdraw() Lead to Permanent Fund LockingThe withdraw() function contains multiple critical design issues.First, the use of the onlyOwner modifier instead of onlyOrganizer prevents the legitimate event operator from accessing ticket revenue and introduces an unnecessary centralization risk.Additionally, the function does not validate that the withdrawal target is not the zero address, which may result in the irreversible loss of funds.
Most critically, the function uses transfer() to send ETH. Since transfer() enforces a strict 2,300 gas stipend, any withdrawal to a smart contract wallet (e.g., a multi-signature wallet) whose receive() or fallback() function requires more gas will consistently revert.
Likelihood: Medium to High. Since many professional organizers and institutional users employ multi-signature or smart contract wallets, the 2300 gas limit of transfer() will frequently trigger reverts, and the role confusion between Owner and Organizer is a certain operational bottleneck.
Impact: High. This flaw leads to a total loss of access for the Organizer and the potential for funds to be permanently locked in the contract or accidentally sent to a zero address, resulting in a complete loss of protocol revenue.
Execution Trace for testWithdrawRevert():
Change the access modifier from onlyOwner to onlyOrganizer to correct the permission logic. Add a require statement to prevent sending funds to a zero address. Finally, replace transfer() with a low-level call() and check its return value to ensure compatibility with smart contract wallets and to handle transfer failures correctly.
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.