Platform: Code4rena
Start Date: 04/11/2021
Pot Size: $50,000 USDC
Total HM: 20
Participants: 28
Period: 7 days
Judge: 0xean
Total Solo HM: 11
Id: 51
League: ETH
Rank: 23/28
Findings: 2
Award: $136.40
🌟 Selected for report: 2
🚀 Solo Findings: 0
🌟 Selected for report: TomFrenchBlockchain
Also found by: pauliax
130.8427 USDC - $130.84
TomFrench
Tokens are locked for 1 day less than specified in spec.
The vesting period is calculated here in unixYear
This results in a lockup of 364 days rather than the expected 365.
Replace line with uint256 constant private unixYear = 365 days;
TomFrench
Higher gas costs on all arithmetic.
Over and underflow checking is standard on arithmetic operations in 0.8.0, yet the SafeMath
library is used extensively in the codebase.
We're then checking for over/underflows twice which uses extra gas
Remove SafeMath
#0 - chickenpie347
2022-01-03T21:12:09Z
Duplicate of #7
🌟 Selected for report: TomFrenchBlockchain
Also found by: PranavG, Reigada, WatchPug, jah, nathaniel, pants, pauliax, pmerkleplant
2.147 USDC - $2.15
TomFrench
Increased gas costs + risk of accidental changes to values expected to be fixed.
Several contracts contain variables which are set at deploy time and never changed again. For example see PublicSale.sol
Since solidity 0.6.5, variables can be marked immutable
which avoids the need for SLOADs when reading these variables - decreasing gas costs and protecting against accidentally modifying these variables.
Manual inspection
Inspect all contracts for variables which are set once and then never modified, apply immutable
keyword and adjust constructors to not read these values (instead use passed parameters)