Initialize Validator Set
Set up the initial validator set when converting a subnet to an L1
When converting an existing subnet to an L1 with sovereign validator management, you need to initialize the Validator Manager with the current validator set. This one-time operation bridges P-Chain subnet creation with L1 validator management using cryptographically verified conversion data.
How initializeValidatorSet Works
Function Implementation
You can view the full source code of the initializeValidatorSet
function here: ValidatorManager.sol#L211
Here you will find pseudo-code that covers the main logic in the function:
P-Chain Integration & Aggregated Signatures
The initialization leverages Avalanche Warp Messaging for security:
- P-Chain Validators Sign - The subnet's validators collectively sign the conversion data
- Aggregated Signature - Creates a threshold signature proving consensus
- Warp Precompile Verifies - The signature is verified before the contract receives it
- Contract Validates - Additional checks ensure data integrity
The conversion ID is derived through:
This ID must match the one in the P-Chain signed message, ensuring data hasn't been tampered with.
Understanding Conversion Data
The conversion data structure used by the function:
Required Information
To initialize, you'll need:
- Conversion Data: Current validator information from P-Chain
- Message Index: Position in the Warp message queue
- Proper Timing: Must be done before other operations
Initialization can only be done once! Make sure you have the correct validator data before proceeding.
Initialize Validator Set

Initialize Validator Set

Next Steps
Congratulations! You just set up your first Permissioned L1! In the next chapter you will learn how to manage this validator set:
- Query the validator set to verify state
- Add, Chnage Weight & Remove Validators
Is this guide helpful?