The Graph L2 bridge contest - carlitox477's results

A protocol for indexing and querying blockchain data.

General Information

Platform: Code4rena

Start Date: 07/10/2022

Pot Size: $50,000 USDC

Total HM: 4

Participants: 62

Period: 5 days

Judge: 0xean

Total Solo HM: 2

Id: 169

League: ETH

The Graph

Findings Distribution

Researcher Performance

Rank: 45/62

Findings: 1

Award: $20.79

🌟 Selected for report: 0

🚀 Solo Findings: 0

Multiple access to state variables can be avoided

Splitting require() statements that use && saves gas

See this issue which describes the fact that there is a larger deployment gas cost, but with enough runtime calls, the change ends up being cheaper by 3 gas.

Instances found:

Internal/private functions called once can be avoided to save gas

Not inlining costs 20 to 40 gas because of two extra JUMP instructions and additional stack operations needed for function calls.

Inline hashing can be put in immutable variables to avoid calculation

  • Managed#curation can avoid calculate keccak256("Curation") by putting its value in an immutable variable
  • Managed#epochManager can avoid calculate keccak256("EpochManager") by putting its value in an immutable variable
  • Managed#rewardsManager can avoid calculate keccak256("RewardsManager") by putting its value in an immutable variable
  • Managed#staking can avoid calculate keccak256("Staking") by putting its value in an immutable variable
  • Managed#graphToken can avoid calculate keccak256("GraphToken") by putting its value in an immutable variable
  • Managed#graphTokenGateway can avoid calculate keccak256("GraphTokenGateway") by putting its value in an immutable variable
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