Backd contest - UnusualTurtle's results

Maximize the power of your assets and start earning yield

General Information

Platform: Code4rena

Start Date: 21/04/2022

Pot Size: $100,000 USDC

Total HM: 18

Participants: 60

Period: 7 days

Judge: gzeon

Total Solo HM: 10

Id: 112

League: ETH

Backd

Findings Distribution

Researcher Performance

Rank: 60/60

Findings: 1

Award: $70.08

🌟 Selected for report: 0

🚀 Solo Findings: 0

Findings Information

Labels

bug
duplicate
2 (Med Risk)
resolved
reviewed

Awards

70.085 USDC - $70.08

External Links

Title

CompoundHandler topUp(), EthPool _doTransferOut() and VaultReserve withdraw() call native payable.transfer

Impact

Multiple operations are handled by using a payable.transfer() call. transfer() has a gas budget limit which is unsafe because gas costs can and may change and can fail when the user is a smart contract.

Proof of Concept

CompoundHandler, VaultReserve, and EthPool have a function that calls transfer:

CompoundHandler.topUp

https://github.com/code-423n4/2022-04-backd/blob/c856714a50437cb33240a5964b63687c9876275b/backd/contracts/actions/topup/handlers/CompoundHandler.sol#L79

VaultReserve.withdraw

https://github.com/code-423n4/2022-04-backd/blob/c856714a50437cb33240a5964b63687c9876275b/backd/contracts/vault/VaultReserve.sol#L81

EthPool._doTransferOut

https://github.com/code-423n4/2022-04-backd/blob/c856714a50437cb33240a5964b63687c9876275b/backd/contracts/pool/EthPool.sol#L30

Using low-level call.value(amount) with the corresponding result check or using the OpenZeppelin Address.sendValue, and using nonReentrant is advised

#0 - gzeoneth

2022-05-08T21:12:37Z

Duplicate #52

AuditHub

A portfolio for auditors, a security profile for protocols, a hub for web3 security.

Built bymalatrax © 2024

Auditors

Browse

Contests

Browse

Get in touch

ContactTwitter