embassy-crypto

Crates

git

Versions

default

Flavors

Skip to main content

Module ed25519

Module ed25519 

Source
Expand description

Ed25519 (EdDSA over edwards25519, RFC 8032).

Pure Ed25519: messages are signed directly, without pre-hashing or a context string. Served by driver::Ed25519.

§Example

use embassy_crypto::ed25519::{SigningKey, VerifyingKey, Signature};

let sk = SigningKey::generate()?;
let vk = sk.verifying_key()?;
let sig = sk.sign(b"hello")?;
vk.verify(b"hello", &sig)?;

Structs§

Signature
An Ed25519 signature: R || S, 64 bytes.
SigningKey
An Ed25519 signing key: the 32-byte seed of RFC 8032 section 5.1.5.
VerifyingKey
An Ed25519 verifying key: a compressed edwards25519 point, 32 bytes.