FEI and TRIBE Redemption contest - 0x4non's results

A new DeFi primitive that allows any token to become productive and provide FEI liquidity at no cost to the markets that need it most.

General Information

Platform: Code4rena

Start Date: 09/09/2022

Pot Size: $42,000 USDC

Total HM: 2

Participants: 101

Period: 3 days

Judge: hickuphh3

Total Solo HM: 2

Id: 161

League: ETH

Tribe

Findings Distribution

Researcher Performance

Rank: 56/101

Findings: 1

Award: $33.58

🌟 Selected for report: 0

🚀 Solo Findings: 0

Use open pragma only on interfaces or libraries

In SimpleFeiDaiPSM.sol#L2, TribeRedeemer.sol#L2 and MultiMerkleRedeemer.sol#L2 Contracts should be deployed with the same compiler version and flags that they have been tested with thoroughly. Locking the pragma helps to ensure that contracts do not accidentally get deployed using, for example, an outdated compiler version that might introduce bugs that affect the contract system negatively.

Take a look into SWC-103


Current sign message on MultiMerkleRedeemer.sol#L53 seems to be a sample message, it say Sample message, please update.


Use named imports, as you do on MerkleRedeemerDripper.sol#L4-L5

In this cases you are not using named imports; MultiMerkleRedeemer.sol#L4 SimpleFeiDaiPSM.sol#L4-L5 RariMerkleRedeemer.sol#L4-L9


SimpleFeiDaiPSM.sol#L92-L98: Use recommend order especified in soliditylang According to order-of-layout in soliditylang the order should be;

Inside each contract, library or interface, use the following order:

  1. Type declarations
  2. State variables
  3. Events
  4. Modifiers
  5. Functions

This variables in SimpleFeiDaiPSM.sol#L92-L98 and SimpleFeiDaiPSM.sol#L75 should be declared in the beginning of the contract.


Revert messages should be lower than 32 bytes; SimpleFeiDaiPSM.sol#L39 SimpleFeiDaiPSM.sol#L54 RariMerkleRedeemer.sol#L125-L126 RariMerkleRedeemer.sol#L138-L139 RariMerkleRedeemer.sol#L171 RariMerkleRedeemer.sol#L190-L191 RariMerkleRedeemer.sol#L227 RariMerkleRedeemer.sol#L239 MerkleRedeemerDripper.sol#L24

Try to use custom errors or send a shorter error messages. Checkout this article; https://blog.soliditylang.org/2021/04/21/custom-errors/

AuditHub

A portfolio for auditors, a security profile for protocols, a hub for web3 security.

Built bymalatrax © 2024

Auditors

Browse

Contests

Browse

Get in touch

ContactTwitter