PermissionlessGate
PermissionlessGate.sol is a supplementary contract that allows anyone to register as a Node Operator in the module. In a single transaction, it creates the Node Operator and submits the initial validator keys and bond in ETH, stETH, or wstETH. Node Operators created through this gate use the default bond curve.
Upgradability​
The contract is immutable.
State Variables​
CURVE_ID​
Curve ID is the default bond curve ID from the accounting contract This immutable variable is kept here for consistency with the other gates
uint256 public immutable CURVE_ID
MODULE​
Address of the Staking Module
IBaseModule public immutable MODULE
Functions​
constructor​
constructor(address module, address admin) ;
addNodeOperatorETH​
Add a new Node Operator using ETH as a bond. At least one deposit data and corresponding bond should be provided. Any excess msg.value will be sent to the bond and can be claimed from there.
function addNodeOperatorETH(
uint256 keysCount,
bytes calldata publicKeys,
bytes calldata signatures,
NodeOperatorManagementProperties calldata managementProperties,
address referrer
) external payable returns (uint256 nodeOperatorId);
Parameters
| Name | Type | Description |
|---|---|---|
keysCount | uint256 | Signing keys count |
publicKeys | bytes | Public keys to submit |
signatures | bytes | Signatures of (deposit_message_root, domain) tuples https://github.com/ethereum/consensus-specs/blob/v1.4.0/specs/phase0/beacon-chain.md#signingdata |
managementProperties | NodeOperatorManagementProperties | Optional. Management properties to be used for the Node Operator. managerAddress: Used as managerAddress for the Node Operator. If not passed msg.sender will be used. rewardAddress: Used as rewardAddress for the Node Operator. If not passed msg.sender will be used. extendedManagerPermissions: Flag indicating that managerAddress will be able to change rewardAddress. If set to true resetNodeOperatorManagerAddress method will be disabled |
referrer | address | Optional. Referrer address. Should be passed when Node Operator is created using partners integration |
Returns
| Name | Type | Description |
|---|---|---|
nodeOperatorId | uint256 | Id of the created Node Operator |
addNodeOperatorStETH​
Add a new Node Operator using stETH as a bond. At least one deposit data and corresponding bond should be provided
function addNodeOperatorStETH(
uint256 keysCount,
bytes calldata publicKeys,
bytes calldata signatures,
NodeOperatorManagementProperties calldata managementProperties,
IAccounting.PermitInput calldata permit,
address referrer
) external returns (uint256 nodeOperatorId);
Parameters
| Name | Type | Description |
|---|---|---|
keysCount | uint256 | Signing keys count |
publicKeys | bytes | Public keys to submit |
signatures | bytes | Signatures of (deposit_message_root, domain) tuples https://github.com/ethereum/consensus-specs/blob/v1.4.0/specs/phase0/beacon-chain.md#signingdata |
managementProperties | NodeOperatorManagementProperties | Optional. Management properties to be used for the Node Operator. managerAddress: Used as managerAddress for the Node Operator. If not passed msg.sender will be used. rewardAddress: Used as rewardAddress for the Node Operator. If not passed msg.sender will be used. extendedManagerPermissions: Flag indicating that managerAddress will be able to change rewardAddress. If set to true resetNodeOperatorManagerAddress method will be disabled |
permit | IAccounting.PermitInput | Optional. Permit to use stETH as bond |
referrer | address | Optional. Referrer address. Should be passed when Node Operator is created using partners integration |
Returns
| Name | Type | Description |
|---|---|---|
nodeOperatorId | uint256 | Id of the created Node Operator |
addNodeOperatorWstETH​
Add a new Node Operator using wstETH as a bond. At least one deposit data and corresponding bond should be provided
function addNodeOperatorWstETH(
uint256 keysCount,
bytes calldata publicKeys,
bytes calldata signatures,
NodeOperatorManagementProperties calldata managementProperties,
IAccounting.PermitInput calldata permit,
address referrer
) external returns (uint256 nodeOperatorId);
Parameters
| Name | Type | Description |
|---|---|---|
keysCount | uint256 | Signing keys count |
publicKeys | bytes | Public keys to submit |
signatures | bytes | Signatures of (deposit_message_root, domain) tuples https://github.com/ethereum/consensus-specs/blob/v1.4.0/specs/phase0/beacon-chain.md#signingdata |
managementProperties | NodeOperatorManagementProperties | Optional. Management properties to be used for the Node Operator. managerAddress: Used as managerAddress for the Node Operator. If not passed msg.sender will be used. rewardAddress: Used as rewardAddress for the Node Operator. If not passed msg.sender will be used. extendedManagerPermissions: Flag indicating that managerAddress will be able to change rewardAddress. If set to true resetNodeOperatorManagerAddress method will be disabled |
permit | IAccounting.PermitInput | Optional. Permit to use wstETH as bond |
referrer | address | Optional. Referrer address. Should be passed when Node Operator is created using partners integration |
Returns
| Name | Type | Description |
|---|---|---|
nodeOperatorId | uint256 | Id of the created Node Operator |
_onlyRecoverer​
function _onlyRecoverer() internal view override;