File | Type | Proxy |
---|---|---|
ECDSAServiceManagerBase.sol |
Abstract Base Contract | UUPS proxy |
ECDSAServiceManagerBase
is an abstract base contract that provides core infrastructure provided by EigenLayer for the AVS. It manages operator registration, stake tracking, and rewards distribution for ECDSA-based services.
- Operator Management
- Rewards Distribution
- AVS Metadata Management
address public immutable stakeRegistry; // Manages operator registration and stake
address public immutable avsDirectory; // Stores AVS-related operator data
address internal immutable rewardsCoordinator; // Handles rewards distribution
address internal immutable delegationManager; // Manages staker delegations
address public rewardsInitiator; // Authorized to create rewards submissions
The contract implements role-based access control:
- StakeRegistry: Can register/deregister operators
- RewardsInitiator: Can submit AVS rewards
- Owner: Can update AVS metadata and configurations
function registerOperatorToAVS(
address operator,
ISignatureUtils.SignatureWithSaltAndExpiry memory operatorSignature
) external onlyStakeRegistry
Registers an operator with the AVS:
- Validates operator signature
- Records registration in AVS directory
- Enables operator participation
function deregisterOperatorFromAVS(
address operator
) external onlyStakeRegistry
Removes an operator from the AVS:
- Cleans up operator records
- Updates AVS directory
- Disables operator participation
function createAVSRewardsSubmission(
IRewardsCoordinator.RewardsSubmission[] calldata rewardsSubmissions
) external onlyRewardsInitiator
Creates rewards submissions for operators:
- Validates submission data
- Forwards to rewards coordinator
- Updates reward distributions
function updateAVSMetadataURI(
string memory _metadataURI
) external onlyOwner
Updates AVS metadata:
- Sets new metadata URI
- Updates AVS directory
- Maintains service information
The contract integrates with several EigenLayer components:
- StakeRegistry: For operator stake management
- AVSDirectory: For operator service data
- RewardsCoordinator: For rewards distribution
- DelegationManager: For delegation management
event OperatorRegistered(address indexed operator)
event OperatorDeregistered(address indexed operator)
event AVSMetadataURIUpdated(string newMetadataURI)
event RewardsInitiatorSet(address newRewardsInitiator)
This base contract is inherited by SpottedServiceManager.