[][src]Trait crypto_api::rng::SecKeyGen

pub trait SecKeyGen {
    fn new_sec_key(
        &self,
        buf: &mut [u8],
        rng: &mut dyn SecureRng
    ) -> Result<usize, Box<dyn Error + 'static>>; }

A algorithm specific key generator to generate a (secret) key

Required methods

fn new_sec_key(
    &self,
    buf: &mut [u8],
    rng: &mut dyn SecureRng
) -> Result<usize, Box<dyn Error + 'static>>

Generates a new key into buf using rng and returns the length of the secret key

Loading content...

Implementors

Loading content...