pub struct HybridSigningKey { /* private fields */ }Expand description
A hybrid signing keypair (private) — the software composition, both halves in memory.
The hardware-backed composition lives in HardwareBackedSigner
(Ed25519 hardware half) and P256HybridSigningKey
(P-256 hardware half); both drive the same HybridSignature/HybridVerifyingKey types.
Implementations§
Source§impl HybridSigningKey
impl HybridSigningKey
Sourcepub fn from_seed_bytes(ed_seed: &[u8; 32], ml_seed: &[u8; 32]) -> Self
pub fn from_seed_bytes(ed_seed: &[u8; 32], ml_seed: &[u8; 32]) -> Self
Reconstruct a keypair deterministically from its two 32-byte seeds.
Sourcepub fn to_seed_bytes(&self) -> [u8; 64]
pub fn to_seed_bytes(&self) -> [u8; 64]
Export the two 32-byte seeds (Ed25519 secret ‖ ML-DSA ξ) for sealed storage.
Sourcepub fn from_seed64(bytes: &[u8; 64]) -> Self
pub fn from_seed64(bytes: &[u8; 64]) -> Self
Reconstruct from a 64-byte concatenation of the two seeds.
Sourcepub fn verifying_key(&self) -> HybridVerifyingKey
pub fn verifying_key(&self) -> HybridVerifyingKey
The public verifying key.
Sourcepub fn sign(&self, msg: &[u8]) -> HybridSignature
pub fn sign(&self, msg: &[u8]) -> HybridSignature
Sign msg, producing both halves. ML-DSA uses the deterministic variant.
Trait Implementations§
Source§impl Clone for HybridSigningKey
impl Clone for HybridSigningKey
Source§fn clone(&self) -> HybridSigningKey
fn clone(&self) -> HybridSigningKey
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 moreSource§impl Signer for HybridSigningKey
The software signer: an in-memory hybrid key. Its sign never fails.
impl Signer for HybridSigningKey
The software signer: an in-memory hybrid key. Its sign never fails.
Source§fn sign(&self, msg: &[u8]) -> Result<HybridSignature, CryptoError>
fn sign(&self, msg: &[u8]) -> Result<HybridSignature, CryptoError>
Sign
msg, producing both signature halves (Ed25519 ‖ ML-DSA-65). Read moreSource§fn verifying_key(&self) -> HybridVerifyingKey
fn verifying_key(&self) -> HybridVerifyingKey
The hybrid public key both halves of
sign verify against.Auto Trait Implementations§
impl Freeze for HybridSigningKey
impl RefUnwindSafe for HybridSigningKey
impl Send for HybridSigningKey
impl Sync for HybridSigningKey
impl Unpin for HybridSigningKey
impl UnsafeUnpin for HybridSigningKey
impl UnwindSafe for HybridSigningKey
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more