Type Definition did_key::Ed25519KeyPair[][src]

type Ed25519KeyPair = AsymmetricKey<PublicKey, SecretKey>;

Implementations

impl Ed25519KeyPair[src]

pub fn from_seed(seed: &[u8]) -> Self[src]

pub fn from_public_key(public_key: &[u8]) -> Self[src]

pub fn get_x25519(&self) -> X25519KeyPair[src]

Trait Implementations

impl DIDCore for Ed25519KeyPair[src]

fn get_verification_methods(
    &self,
    config: Config,
    controller: &str
) -> Vec<VerificationMethod>
[src]

fn get_did_document(&self, config: Config) -> Document[src]

impl Debug for Ed25519KeyPair[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl Ecdh for Ed25519KeyPair[src]

fn key_exchange(&self, _: &Self) -> Vec<u8>[src]

Perform key exchange operation

impl Ecdsa for Ed25519KeyPair[src]

fn sign(&self, payload: Payload) -> Vec<u8>[src]

Performs sign operation

fn verify(&self, payload: Payload, signature: &[u8]) -> Result<(), Error>[src]

Performs verify operation

impl Fingerprint for Ed25519KeyPair[src]

impl Generate for Ed25519KeyPair[src]

fn new() -> Ed25519KeyPair[src]

Generate random key

fn new_with_seed(seed: &[u8]) -> Ed25519KeyPair[src]

Generate key deterministically using a given seed

fn from_public_key(public_key: &[u8]) -> Ed25519KeyPair[src]

Generate instance from existing public key

fn from_secret_key(secret_key: &[u8]) -> Ed25519KeyPair[src]

Generate instance from existing secret key

impl KeyMaterial for Ed25519KeyPair[src]

fn public_key_bytes(&self) -> Vec<u8>[src]

Returns the public key bytes as slice

fn private_key_bytes(&self) -> Vec<u8>[src]

Returns the secret key bytes as slice