hats-finance / Wise-Lending-0xa2ca45d6e249641e595d50d1d9c69c9e3cd22573

0 stars 1 forks source link

GHOST_Amount borrow shares accrue interest and lead to bad debt #34

Open hats-bug-reporter[bot] opened 7 months ago

hats-bug-reporter[bot] commented 7 months ago

Github username: @g01u Twitter username: g01uu Submission hash (on-chain): 0x7e2ff1aa3147a4e7c3db10d074d3c4af0d563ebc96dea11c5ec45f2336465ab3 Severity: high

Description: Description\

The GHOST_Amount borrow shares, that are not owned by anyone, earn interest in _accrueInterest. This interest keeps compounding and cannot be repaid as the GHOST borrow shares are not owned by anyone. As the withdrawable funds are computed as supplyAssets - borrowAssets, the borrow shares' assets equivalent leads to a reduction in withdrawable funds, basically bad debt. Note that while the initial borrow shares only account for 1 asset, this can be increased by increasing the share price. The share price can be inflated arbitrarily high,

Impact low

It's just 1e6 virtual borrow shares earning interest on 1 wei, so the bad debt accrued is negligible even for very high borrow rates.

Likelihood high

The GHOST_Amount debt shares exist in every market, it's an issue in every market.

vm06007 commented 6 months ago

@g01u please refer to out-of-scope part:

https://app.hats.finance/audit-competitions/wise-lending-0xa2ca45d6e249641e595d50d1d9c69c9e3cd22573/scope Screenshot 2024-02-18 at 7 59 09 PM