Incorrect formula for loanRatio, which would break accounting.
The loanRatio in Lender.sol is currently calculated as follows:
https://github.com/Cyfrin/2023-07-beedle/blob/658e046bda8b010a5b82d2d85e824f3823602d27/src/Lender.sol#L246
The formula assumes that both debt and collateral tokens have the same decimals of 10**18.
In the case where:
Debt and collateral token have different decimals
Debt and / or collateral token does not have 18 decimals (e.g. USDC, USDT)
The formula will lead to an incorrect accounting of loanRatio.
This breaks the accounting of the protocol.
Manual review.
Tokens should be scaled according to the number of decimals they have.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.