Struct cardano_serialization_lib::chain_crypto::algorithms::ed25519::Ed25519
source · [−]pub struct Ed25519;
Expand description
ED25519 Signing Algorithm
Trait Implementations
sourceimpl AsymmetricKey for Ed25519
impl AsymmetricKey for Ed25519
type Secret = Priv
type PubAlg = Ed25519
const SECRET_BECH32_HRP: &'static str = "ed25519_sk"
fn generate<T: RngCore + CryptoRng>(rng: T) -> Self::Secret
fn compute_public(
key: &Self::Secret
) -> <Self::PubAlg as AsymmetricPublicKey>::Public
fn secret_from_binary(data: &[u8]) -> Result<Self::Secret, SecretKeyError>
sourceimpl AsymmetricPublicKey for Ed25519
impl AsymmetricPublicKey for Ed25519
type Public = Pub
const PUBLIC_BECH32_HRP: &'static str = "ed25519_pk"
const PUBLIC_KEY_SIZE: usize = 32usize
fn public_from_binary(data: &[u8]) -> Result<Self::Public, PublicKeyError>
sourceimpl SecretKeySizeStatic for Ed25519
impl SecretKeySizeStatic for Ed25519
const SECRET_KEY_SIZE: usize = 32usize
sourceimpl VerificationAlgorithm for Ed25519
impl VerificationAlgorithm for Ed25519
type Signature = Sig
const SIGNATURE_SIZE: usize = 64usize
const SIGNATURE_BECH32_HRP: &'static str = "ed25519_sig"
fn signature_from_bytes(data: &[u8]) -> Result<Self::Signature, SignatureError>
fn verify_bytes(
pubkey: &Self::Public,
signature: &Self::Signature,
msg: &[u8]
) -> Verification
impl Eq for Ed25519
impl StructuralEq for Ed25519
impl StructuralPartialEq for Ed25519
Auto Trait Implementations
impl RefUnwindSafe for Ed25519
impl Send for Ed25519
impl Sync for Ed25519
impl Unpin for Ed25519
impl UnwindSafe for Ed25519
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more