Wrong implementation of NoYield.sol#emergencyWithdraw()
#115
Labels
3 (High Risk)
Assets can be stolen/lost/compromised directly
bug
Something isn't working
sponsor confirmed
Sponsor agrees this is a problem and intends to fix it (OK to use w/ "disagree with severity")
Handle
WatchPug
Vulnerability details
https://github.com/code-423n4/2021-12-sublime/blob/9df1b7c4247f8631647c7627a8da9bdc16db8b11/contracts/yield/NoYield.sol#L78-L83
received
is not being assigned prior to L81, therefore, at L81,received
is0
.As a result, the
emergencyWithdraw()
does not work, in essence.Recommendation
Change to:
The text was updated successfully, but these errors were encountered: