Function fcp_cryptoauth::cryptography::gen_keypair [] [src]

pub fn gen_keypair() -> (PublicKey, SecretKey)

Randomly generates a secret key and a corresponding public key.

THREAD SAFETY: gen_keypair() is thread-safe provided that you have called fcp_cryptoauth::init() (or rust_sodium::init()) once before using any other function from fcp_cryptoauth or rust_sodium.