Struct orion::hkdf::Hkdf [] [src]

pub struct Hkdf {
    pub salt: Vec<u8>,
    pub data: Vec<u8>,
    pub info: Vec<u8>,
    pub hmac: usize,
    pub length: usize,
}

HKDF (HMAC-based Extract-and-Expand Key Derivation Function) as specified in the RFC 5869.

Fields

Methods

impl Hkdf
[src]

HKDF (HMAC-based Extract-and-Expand Key Derivation Function) as specified in the RFC 5869.

Usage examples:

use orion::hkdf::Hkdf;
use orion::util::gen_rand_key;

let key = gen_rand_key(10);
let salt = gen_rand_key(10);
let info = gen_rand_key(10);

let dk = Hkdf { salt: salt, data: key, info: info, hmac: 256, length: 50 };
dk.hkdf_compute();

[src]

Return HMAC matching argument passsed to Hkdf.

[src]

The HKDF Expand step. Returns an HKDF.

Trait Implementations

impl Drop for Hkdf
[src]

[src]

Executes the destructor for this type. Read more

Auto Trait Implementations

impl Send for Hkdf

impl Sync for Hkdf