Platform: Code4rena
Start Date: 22/03/2024
Pot Size: $36,500 USDC
Total HM: 7
Participants: 17
Period: 14 days
Judge: Lambda
Id: 323
League: POLKADOT
Rank: 17/17
Findings: 1
Award: $41.91
🌟 Selected for report: 0
🚀 Solo Findings: 0
🌟 Selected for report: Bauchibred
Also found by: 0xTheC0der, AM, Cryptor, ZanyBonzy, n4nika, zhaojie
41.9121 USDC - $41.91
The function name is misleading due to incorrect order. According to the code, it reaccumulates and then payouts
parity-wasm
deprecated by the authorhttps://rustsec.org/advisories/RUSTSEC-2022-0061
There is no reason to check for the min bond on the function rebond because that check is already made in the bond and unbond functions
If the earning module is hooked into OnloanUpdate, then it would break the invariant of having the total bonded token match the total amount of shares
Deposit Event is used for events that have nothing to do with depositing funds which can be confusing
The function allows a user to to deposit funds to receive shares. However, there is no check whether a user has the required capital to make the deposit. This is shown here
Without this check a user could potentially gain shares that they did not deserve. For example, a user can make a deposit of 1000 token to receive shares, when they only have 10 tokens, but since the function does not check whether a user has the required funds, the function will grant the user extra shares that was not deserved.
#0 - c4-pre-sort
2024-04-07T15:33:16Z
DadeKuma marked the issue as sufficient quality report
#1 - c4-judge
2024-04-09T17:05:11Z
OpenCoreCH marked the issue as grade-b