Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgraded Q -> H from 63 [1654488227536] #168

Closed
code423n4 opened this issue Jun 6, 2022 · 2 comments
Closed

Upgraded Q -> H from 63 [1654488227536] #168

code423n4 opened this issue Jun 6, 2022 · 2 comments
Labels
3 (High Risk) Assets can be stolen/lost/compromised directly bug Something isn't working duplicate This issue or pull request already exists upgraded by judge

Comments

@code423n4
Copy link
Contributor

Judge has assessed an item in Issue #63 as High risk. The relevant finding follows:

@code423n4 code423n4 added 3 (High Risk) Assets can be stolen/lost/compromised directly bug Something isn't working upgraded by judge labels Jun 6, 2022
code423n4 added a commit that referenced this issue Jun 6, 2022
@HickupHH3
Copy link
Collaborator

ETH can accidentally be sent to a contract that rejects the transfer because the sent value returned by address(_to).call{value: receivedETHAmount}(''); is not actually checked.
https://github.com/code-423n4/2022-05-sturdy/blob/main/smart-contracts/LidoVault.sol#L140-L142
On line 140 a call is made to transfer ETH (bool sent, bytes memory data) = address(_to).call{value: receivedETHAmount}('');
Then on line 141 receivedETHAmount is returned.
And on line 142 the sending of ETH is checked.

Recommended Mitigation Steps
To fix this, line 141 and line 142 should be swapped.

@HickupHH3
Copy link
Collaborator

Duplicate of #157

@HickupHH3 HickupHH3 marked this as a duplicate of #157 Jun 6, 2022
@HickupHH3 HickupHH3 added the duplicate This issue or pull request already exists label Jun 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3 (High Risk) Assets can be stolen/lost/compromised directly bug Something isn't working duplicate This issue or pull request already exists upgraded by judge
Projects
None yet
Development

No branches or pull requests

2 participants