Cyfrin / 2023-07-beedle

21 stars 20 forks source link

Medium4-StorageOccupation-CarlosAlegreUr #260

Open codehawks-bot opened 1 year ago

codehawks-bot commented 1 year ago

Medium4-StorageOccupation-CarlosAlegreUr

Severity

Medium Risk

Relevant GitHub Links

https://github.com/Cyfrin/2023-07-beedle/blob/main/src/Lender.sol

Software Audit Report 📑


Summary 📌

This report outlines potential exploits where well-funded attackers might tamper with the contract's storage slots, leading to higher operational costs.


Vulnerability Details 🔍

In Lender.sol:

Exploits by Attackers with Enough Capital

📘 Notice ℹī¸: Some solutions are explained in the Recommendations section. They may differ in implementation so I've linked trusted implementations like OpenZeppelin contracts.


Impact 📈

Redundant storage utilization can increase operational expenses.


Tools Used 🛠ī¸


Recommendations đŸŽ¯

Considering future plans for a governance model here are some suggestions to face the problems:

🚧 Note ⚠ī¸: Implementing solutions to these problems requires significant code modification. A second audit is recommended post-implementation to ensure no new bugs are introduced.


PatrickAlphaC commented 1 year ago

Moving to informational. It's theoretically possible to imagine a user with infinite funds, but not practically.

Your suggestions are good for the protocol to be aware of.