Smart contracts for the staking modules of the Lido protocol. Three modules ship from this repository and share a common code base:
- Community Staking Module (CSM) — permissionless module for community stakers. See more in CSM docs.
- CSM 0x02 — CSM dedicated to validators with the
0x02withdrawal credentials prefix. - Curated Module v2 (CMv2) — next iteration of Lido's curated module. Reuses CSM components to introduce bond-based security, flexible operator classification, improved incentive alignment, and lower governance friction compared to the legacy curated module.
src/— Solidity sourcesscript/— deploy and helper scriptstest/— Foundry testsartifacts/— per-chain deployment artifacts (mainnet/,hoodi/, pluslatest/andlocal/working dirs)
Prerequisites:
- Foundry — version pinned in
.foundryref. - Just 1.24.0 or later.
- Yarn — 4.1 or later.
- jq 1.6 or later.
- OpenBSD-flavored
nc(netcat) on some Linux distributions (e.g. Arch) for local fork recipes.
Bootstrap
just depsBuild and run unit tests
just build
just test-unitRun just --list to see all available recipes.
The repository also ships a few utilities used for the modules:
TwoPhaseFrameConfigUpdate— shifts the Oracle report window by reconfiguring theHashConsensusin a safe mannerOneShotCurveSetup— atomically adds a new bond curve and applies its parameter overrides
Python utilities for assessing Identified Community Stakers (ICS) eligibility across engagement, experience, and humanity categories live in ics_assessment/. Methodology and scoring are described in the Research Forum post; see ics_assessment/README.md for usage.
See the Contributing Guide and repository conventions in AGENTS.md.
