module HKDF

Overview

HMAC-based Extract-and-Expand Key Derivation Function (HKDF)

Defined in:

hkdf.cr

Constant Summary

VERSION = "1.0.0"

Class Method Summary

Class Method Detail

def self.derive_key(salt : Bytes, ikm : Bytes, info : Bytes, length : Int32, hash_algo = OpenSSL::Algorithm::SHA256) : Bytes #

Combined HKDF Extract-and-Expand


[View source]
def self.expand(prk : Bytes, info : Bytes, length : Int32, hash_algo = OpenSSL::Algorithm::SHA256) : Bytes #

HKDF Expand phase


[View source]
def self.extract(salt : Bytes, ikm : Bytes, hash_algo = OpenSSL::Algorithm::SHA256) : Bytes #

HKDF Extract phase


[View source]