Cyfrin / 2023-08-sparkn

Other
11 stars 15 forks source link

Zero token transfer can cause a potential DoS in Distributor.sol #474

Open codehawks-bot opened 1 year ago

codehawks-bot commented 1 year ago

Zero token transfer can cause a potential DoS in Distributor.sol

Severity

Medium Risk

Relevant GitHub Links

https://github.com/code-423n4/2023-04-caviar-findings/issues/278

Summary

The Distributor.sol contract doesn't check for zero amount while transferring rewards, which can end up blocking the operation.

Vulnerability Details

Nadinnnn commented 1 year ago

Escalate

This issue is being identified as a duplicate of Some ERC20 tokens will revert when passing a value of 0. (https://github.com/Cyfrin/2023-08-sparkn/issues/155) .

But it is exactly a duplicate of the issue Potential Distribution Failure Due to Zero Rounded Transfer Amount (https://github.com/Cyfrin/2023-08-sparkn/issues/839) .