Struct keys::PublicKey
zaun_community_protocol::keys::PublicKey · Struct
pub struct PublicKey(…)A composite public key, 1 985 bytes.
Methods
Section titled “Methods”from_bytes
Section titled “from_bytes”pub fn from_bytes(bytes: &[u8]) -> Result<Self, KeyEncodingError>Parses the encoding, checking the suite byte and length.
Errors
Section titled “Errors”KeyEncodingError for an unknown suite or a wrong length.
as_bytes
Section titled “as_bytes”pub fn as_bytes(&self) -> &[u8]The full encoding, suite byte first.
pub fn suite(&self) -> SuiteThe suite.
pub fn mldsa(&self) -> &[u8]The ML-DSA-65 component (RFC 10073 serialisation, first part).
ed25519
Section titled “ed25519”pub fn ed25519(&self) -> &[u8]The Ed25519 component (RFC 10073 serialisation, second part).
Trait implementations
Section titled “Trait implementations”Clone, Debug, Decode, Deserialize<'de>, Encode, Eq, Hash, PartialEq, Serialize, StructuralPartialEq