Hawk High

First Flight #39
Beginner FriendlySolidity
100 EXP
View results
Submission Details
Impact: low
Likelihood: low
Invalid

Unspecified Error in Expel Function

Summary

The expel function uses revert() without an error message when the session is not active, hindering debugging.

Vulnerability Details

The line if (inSession == false) { revert(); } provides no error details, making it difficult to diagnose transaction failures.

https://github.com/CodeHawks-Contests/2025-05-hawk-high/blob/3a7251910c31739505a8699c7a0fc1b7de2c30b5/src/LevelOne.sol#L245

Impact

Poor user experience and increased difficulty in identifying transaction revert causes.

Tools Used

Recommendations

Replace with a custom error (e.g., error HH__SessionNotActive()) and revert with that error instead.

Updates

Lead Judging Commences

yeahchibyke Lead Judge 16 days ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity
yeahchibyke Lead Judge 16 days ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity

Support

FAQs

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