-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add more beacon API types (#5292)
- Loading branch information
Showing
17 changed files
with
844 additions
and
151 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
pub const BLS_DST: &[u8] = b"BLS_SIG_BLS12381G2_XMD:SHA-256_SSWU_RO_POP_"; | ||
pub const BLS_PUBLIC_KEY_BYTES_LEN: usize = 48; | ||
pub const BLS_SECRET_KEY_BYTES_LEN: usize = 32; | ||
pub const BLS_SIGNATURE_BYTES_LEN: usize = 96; |
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
#![allow(missing_docs)] | ||
//! Types for the Ethereum 2.0 RPC protocol (beacon chain) | ||
|
||
use alloy_primitives::FixedBytes; | ||
use constants::{BLS_PUBLIC_KEY_BYTES_LEN, BLS_SIGNATURE_BYTES_LEN}; | ||
|
||
pub mod constants; | ||
/// Beacon API events support. | ||
pub mod events; | ||
pub mod payload; | ||
pub mod withdrawals; | ||
|
||
/// BLS signature type | ||
pub type BlsSignature = FixedBytes<BLS_SIGNATURE_BYTES_LEN>; | ||
|
||
/// BLS public key type | ||
pub type BlsPublicKey = FixedBytes<BLS_PUBLIC_KEY_BYTES_LEN>; |
Oops, something went wrong.