Inverse Finance contest - corerouter's results

Rethink the way you borrow.

General Information

Platform: Code4rena

Start Date: 25/10/2022

Pot Size: $50,000 USDC

Total HM: 18

Participants: 127

Period: 5 days

Judge: 0xean

Total Solo HM: 9

Id: 175

League: ETH

Inverse Finance

Findings Distribution

Researcher Performance

Rank: 30/127

Findings: 1

Award: $342.97

🌟 Selected for report: 0

🚀 Solo Findings: 0

Findings Information

🌟 Selected for report: jayphbee

Also found by: catchup, cccz, corerouter, trustindistrust

Labels

bug
2 (Med Risk)
satisfactory
duplicate-275

Awards

342.9734 USDC - $342.97

External Links

Lines of code

https://github.com/code-423n4/2022-10-inverse/blob/3e81f0f5908ea99b36e6ab72f13488bbfe622183/src/Market.sol#L607

Vulnerability details

Impact

In the current codes, liquidation fee will be paid only when there is enough fee in the escrow account. In reality, liquidation fee should be paid as much as possible, which means the existing balance in the escrow account should be paid when there is not enough fee in the escrow account.

Proof of Concept

https://github.com/code-423n4/2022-10-inverse/blob/3e81f0f5908ea99b36e6ab72f13488bbfe622183/src/Market.sol#L607

Tools Used

The current logic shown as below:

if(escrow.balance() >= liquidationFee) { escrow.pay(gov, liquidationFee); }

Should be refactor to the codes shown as below:

if(escrow.balance() >= liquidationFee) { escrow.pay(gov, liquidationFee); } else { escrow.pay(gov, escrow.balance()); }

#0 - c4-judge

2022-11-05T19:50:39Z

0xean marked the issue as duplicate

#1 - c4-judge

2022-11-28T18:26:00Z

0xean marked the issue as duplicate of #275

#2 - Simon-Busch

2022-12-05T15:35:03Z

Issue marked as satisfactory as requested by 0xean

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