Wild Credit contest - pauliax's results

Decentralized lending protocol with isolated lending pairs.

General Information

Platform: Code4rena

Start Date: 08/07/2021

Pot Size: $50,000 USDC

Total HM: 7

Participants: 13

Period: 7 days

Judge: ghoulsol

Total Solo HM: 5

Id: 18

League: ETH

Wild Credit

Findings Distribution

Researcher Performance

Rank: 3/13

Findings: 2

Award: $2,749.02

🌟 Selected for report: 1

🚀 Solo Findings: 1

Findings Information

🌟 Selected for report: pauliax

Labels

bug
2 (Med Risk)
sponsor confirmed

Awards

2749.0229 USDC - $2,749.02

External Links

Handle

pauliax

Vulnerability details

Impact

function withdrawBorrowETH invokes _wethWithdrawTo and later _checkMinReserve, however, the check of reserve is not necessary here, as function _wethWithdrawTo also does that after transferring the ether. However, this reserve check might be bypassed as TransferHelper._wethWithdrawTo uses a low level call that is vulnerable to re-entrancy attacks. As this MIN_RESERVE sounds like an important value, you should consider preventing re-entrancy attacks here. // Prevents division by zero and other undesirable behavior uint public constant MIN_RESERVE = 1000;

Consider using re-entrancy guard on all main action functions (e.g. deposit, withdraw, borrow, repay, etc): https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/security/ReentrancyGuard.sol

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