You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The payable attribute will allow swapTo() to receive BNB and may confuse/allow users into sending BNB to contract trying to swap that to token, which is not the case. This will lead to user's BNB getting locked in this contract without a way to retrieve it.
Handle
0xRajeev
Vulnerability details
Impact
The payable attribute will allow swapTo() to receive BNB and may confuse/allow users into sending BNB to contract trying to swap that to token, which is not the case. This will lead to user's BNB getting locked in this contract without a way to retrieve it.
Proof of Concept
https://github.com/code-423n4/2021-07-spartan/blob/e2555aab44d9760fdd640df9095b7235b70f035e/contracts/Pool.sol#L210-L226
Tools Used
Manual Analysis
Recommended Mitigation Steps
Remove payable attribute as it is not required here.
The text was updated successfully, but these errors were encountered: