info > EVP_KDF-TLS13_KDF(7)

๐Ÿ“› NAME

EVP_KDF-TLS13_KDF - The TLS 1.3 EVP_KDF implementation

๐Ÿš€ Quick Reference

Use CaseCommandDescription
๐Ÿ”‘ Fetch KDF implementationEVP_KDF_fetch(NULL, "TLS13-KDF", NULL)Get the TLS 1.3 KDF provider
๐Ÿ†• Create KDF contextEVP_KDF_CTX_new(kdf)Allocate a new KDF context for TLS 1.3
๐Ÿ”ง Set digest algorithmEVP_KDF_CTX_set_params(ctx, params)Configure digest (e.g., SHA-256)
๐Ÿ”‘ Set key materialEVP_KDF_CTX_set_params(ctx, params)Provide the input key (IKM) for extract
๐Ÿง‚ Set saltEVP_KDF_CTX_set_params(ctx, params)Optional salt for extract operation
๐Ÿท๏ธ Set label prefixOSSL_KDF_PARAM_PREFIX = "tls13 "Must be ASCII "tls13 " (no trailing zero)
๐Ÿท๏ธ Set labelOSSL_KDF_PARAM_LABELLabel per RFC 8446 ยง7.1
๐Ÿ“ฆ Set context dataOSSL_KDF_PARAM_DATAContext data (info) per RFC 8446 ยง7.1
โš™๏ธ Set modeOSSL_KDF_PARAM_MODE = EXTRACT_ONLY | EXPAND_ONLYChoose extract or expand phase
๐Ÿ” Derive key (extract)EVP_KDF_derive(ctx, key, keylen, params)Perform extract โ†’ intermediate pseudorandom key K
๐Ÿ” Derive key (expand)EVP_KDF_derive(ctx, key, keylen, params)Perform expand using K as input key
๐Ÿ“ Get output sizeEVP_KDF_CTX_get_kdf_size(ctx)Look up fixed output size for extract mode
๐Ÿงน Free contextEVP_KDF_CTX_free(kctx)Release the KDF context

๐Ÿ“– DESCRIPTION

Support for computing the TLS 1.3 version of the HKDF KDF through the EVP_KDF API.

The EVP_KDF-TLS13_KDF algorithm implements the HKDF key derivation function as used by TLS 1.3.

๐Ÿ”ค Identity

"TLS13-KDF" is the name for this implementation; it can be used with the EVP_KDF_fetch() function.

โš™๏ธ Supported parameters

The supported parameters are:

These parameters work as described in "PARAMETERS" in EVP_KDF(3).

๐Ÿ“ NOTES

This KDF is intended for use by the TLS 1.3 implementation in libssl. It does not support all the options and capabilities that HKDF does.

The OSSL_PARAM array passed to EVP_KDF_derive(3) or EVP_KDF_CTX_set_params(3) must specify all of the parameters required. This KDF does not support a piecemeal approach to providing these.

A context for a TLS 1.3 KDF can be obtained by calling:

EVP_KDF *kdf = EVP_KDF_fetch(NULL, "TLS13-KDF", NULL);
EVP_KDF_CTX *kctx = EVP_KDF_CTX_new(kdf);

The output length of a TLS 1.3 KDF expand operation is specified via the keylen parameter to the EVP_KDF_derive(3) function. When using EVP_KDF_HKDF_MODE_EXTRACT_ONLY the keylen parameter must equal the size of the intermediate fixed-length pseudorandom key otherwise an error will occur. For that mode, the fixed output size can be looked up by calling EVP_KDF_CTX_get_kdf_size() after setting the mode and digest on the EVP_KDF_CTX.

๐Ÿ“œ CONFORMING TO

RFC 8446

๐Ÿ‘๏ธ SEE ALSO

EVP_KDF(3), EVP_KDF_CTX_new(3), EVP_KDF_CTX_free(3), EVP_KDF_CTX_get_kdf_size(3), EVP_KDF_CTX_set_params(3), EVP_KDF_derive(3), "PARAMETERS" in EVP_KDF(3), EVP_KDF-HKDF(7)

ยฉ๏ธ COPYRIGHT

Copyright 2021 The OpenSSL Project Authors. All Rights Reserved.

Licensed under the Apache License 2.0 (the "License"). You may not use this file except in compliance with the License. You can obtain a copy in the file LICENSE in the source distribution or at https://www.openssl.org/source/license.html.

3.0.2 โ€” 2026-06-02 โ€” EVP_KDF-TLS13_KDF(7SSL)

EVP_KDF-TLS13_KDF(7)
๐Ÿ“› NAME ๐Ÿš€ Quick Reference ๐Ÿ“– DESCRIPTION
๐Ÿ”ค Identity โš™๏ธ Supported parameters
๐Ÿ“ NOTES ๐Ÿ“œ CONFORMING TO ๐Ÿ‘๏ธ SEE ALSO ยฉ๏ธ COPYRIGHT

Generated by phpman v4.9.26-1-g511901d · Markdown · JSON · MCP Author: Che Dong Under GNU General Public License
2026-08-04 12:53 @216.73.217.98
CrawledBy Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
Valid XHTML 1.0 Transitional!Valid CSS!
Enhanced by LLM: deepseek-v4-flash / taotoken.net / www.chedong.com - original format

^_top_^