DeFiHardhatFoundry
250,000 USDC
View results
Submission Details
Severity: high
Valid

`ReseedSilo#reseedSiloDeposit` does not credit the user any `roots`

Summary

ReseedSilo#reseedSiloDeposit does not credit the user any roots

Vulnerability Details

Usually, when users are minted stalk, they're also minted roots at the current Silo ratio.

However, within reseedSiloDeposit, roots are never actually calculated/set.

// increment stalkForAccount by the stalk issued per BDV.
// placed outside of loop for gas effiency.
accountStalk += stalkIssuedPerBdv * totalBdvForAccount;
// set stalk for account.
s.accts[deposits.accounts].stalk = accountStalk;
}

As this would also increase the roots : stalk ratio, this would allow for unfair minting of Beans

Impact

Loss of roots and Beans

Tools Used

Manual review

Recommendations

Mint roots at the current silo ratio

Updates

Lead Judging Commences

inallhonesty Lead Judge about 1 year ago
Submission Judgement Published
Validated
Assigned finding tags:

`ReseedSilo#reseedSiloDeposit` does not credit the user any `roots`

Appeal created

deadrosesxyz Submitter
about 1 year ago
inallhonesty Lead Judge
about 1 year ago
inallhonesty Lead Judge about 1 year ago
Submission Judgement Published
Validated
Assigned finding tags:

`ReseedSilo#reseedSiloDeposit` does not credit the user any `roots`

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.