pub enum SignatureAlgorithm {
Ed25519,
MlDsa65,
SlhDsaSha2_128s,
HybridEd25519MlDsa65,
}Expand description
Signature algorithms named by BCX metadata.
Variants§
Ed25519
Ed25519 for compact classical signatures.
MlDsa65
ML-DSA-65 for post-quantum-ready deployments.
SlhDsaSha2_128s
SLH-DSA-SHA2-128s for conservative stateless signatures.
HybridEd25519MlDsa65
Hybrid Ed25519 plus ML-DSA-65 signature envelope.
Canonical layout is [ed25519: 64 bytes][ml-dsa-65: 3293 bytes].
Verifiers must verify both components before returning Ok.
Implementations§
Source§impl SignatureAlgorithm
impl SignatureAlgorithm
Sourcepub const ED25519_SIGNATURE_LEN: usize = 64
pub const ED25519_SIGNATURE_LEN: usize = 64
Ed25519 signature byte length.
Sourcepub const ML_DSA_65_SIGNATURE_LEN: usize = 3_293
pub const ML_DSA_65_SIGNATURE_LEN: usize = 3_293
ML-DSA-65 signature byte length.
Sourcepub const SLH_DSA_SHA2_128S_SIGNATURE_LEN: usize = 7_856
pub const SLH_DSA_SHA2_128S_SIGNATURE_LEN: usize = 7_856
SLH-DSA-SHA2-128s signature byte length.
Sourcepub const HYBRID_ED25519_ML_DSA_65_SIGNATURE_LEN: usize
pub const HYBRID_ED25519_ML_DSA_65_SIGNATURE_LEN: usize
Hybrid Ed25519 plus ML-DSA-65 signature byte length.
Sourcepub const fn expected_signature_len(self) -> usize
pub const fn expected_signature_len(self) -> usize
Returns the exact signature length admitted for this algorithm.
Trait Implementations§
Source§impl Clone for SignatureAlgorithm
impl Clone for SignatureAlgorithm
Source§fn clone(&self) -> SignatureAlgorithm
fn clone(&self) -> SignatureAlgorithm
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for SignatureAlgorithm
Source§impl Debug for SignatureAlgorithm
impl Debug for SignatureAlgorithm
impl Eq for SignatureAlgorithm
Source§impl PartialEq for SignatureAlgorithm
impl PartialEq for SignatureAlgorithm
Source§fn eq(&self, other: &SignatureAlgorithm) -> bool
fn eq(&self, other: &SignatureAlgorithm) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for SignatureAlgorithm
Auto Trait Implementations§
impl Freeze for SignatureAlgorithm
impl RefUnwindSafe for SignatureAlgorithm
impl Send for SignatureAlgorithm
impl Sync for SignatureAlgorithm
impl Unpin for SignatureAlgorithm
impl UnsafeUnpin for SignatureAlgorithm
impl UnwindSafe for SignatureAlgorithm
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more