BadgerDAO ibBTC Wrapper contest - defsec's results

Building Products to Bring BTC to DeFi.

General Information

Platform: Code4rena

Start Date: 28/10/2021

Pot Size: $30,000 ETH

Total HM: 8

Participants: 19

Period: 3 days

Judge: leastwood

Total Solo HM: 4

Id: 47

League: ETH

BadgerDAO

Findings Distribution

Researcher Performance

Rank: 7/19

Findings: 3

Award: $1,771.30

🌟 Selected for report: 4

πŸš€ Solo Findings: 0

Findings Information

🌟 Selected for report: hack3r-0m

Also found by: defsec

Labels

bug
duplicate
2 (Med Risk)
sponsor confirmed

Awards

679.3693 USDC - $679.37

External Links

Handle

defsec

Vulnerability details

Impact

During the code review, It has been seen that oracle return value has not been checked on the function. If oracle is returned price as a 0, balance of shares will be zero.

Proof of Concept

  1. Navigate to "https://github.com/code-423n4/2021-10-badgerdao/blob/9d4734becebd729299f154c0cfa1d3a7f06cccfb/contracts/WrappedIbbtc.sol#L124"
  2. The return value pricePerShare() function has not been checked.

Tools Used

Code Review

Consider to add return value check on the oracle function.

""" require(oracle.pricePerShare()>0, "Price should be more than zero"); """

#0 - 0xleastwood

2021-12-04T09:09:36Z

#90

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