Vyper Vested Claims

First Flight #34
Beginner FriendlyDeFi
100 EXP
View results
Submission Details
Severity: medium
Invalid

Zero total_amount in _calculate_vested_amount

Summary

The function allows total_amount = 0, which could lead to invalid claims.

Vulnerability Details

  • If total_amount is zero, vested would also be zero, allowing users to claim zero tokens. This is a logical flaw.

Impact

  • Waste gas and computation on invalid claims.

Tool Used

  • Manual review

Recommendations

  • Add a check in claim:

assert total_amount > 0, "Total amount must be greater than zero"
Updates

Appeal created

bube Lead Judge 4 months ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity

Support

FAQs

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