Hkdf

object Hkdf

HMAC-based Extract-and-Expand Key Derivation Function (HKDF) according to RFC 5869.

Functions

Link copied to clipboard
fun deriveKey(algorithm: Algorithm, ikm: ByteArray, salt: ByteArray?, info: ByteArray, length: Int): ByteArray

Derives a symmetric encryption key according to HKDF as defined by RFC 5869.

Link copied to clipboard
fun expand(algorithm: Algorithm, prk: ByteArray, info: ByteArray, length: Int): ByteArray

The "expand" part of HKDF.

Link copied to clipboard
fun extract(algorithm: Algorithm, ikm: ByteArray, salt: ByteArray?): ByteArray

The "extract" part of HKDF.