info > EVP_KEYEXCH-X25519(7)

πŸ“› NAME

EVP_KEYEXCH-X25519, EVP_KEYEXCH-X448 – X25519 and X448 Key Exchange algorithm support

πŸš€ Quick Reference

Use Case Command Description
πŸ”‘ Generate X25519 key pair openssl genpkey -algorithm X25519 -out priv.pem Create a private key for X25519 key exchange
πŸ”‘ Generate X448 key pair openssl genpkey -algorithm X448 -out priv.pem Create a private key for X448 key exchange
🀝 Derive shared secret (X25519) EVP_PKEY_derive_init() + EVP_PKEY_derive_set_peer() + EVP_PKEY_derive() Compute shared secret using X25519 keys
🀝 Derive shared secret (X448) Same API with X448 keys Compute shared secret using X448 keys
🧩 Set padding parameter OSSL_EXCHANGE_PARAM_PAD Control padding of the shared secret output

πŸ“– DESCRIPTION

Key exchange support for the X25519 and X448 key types.

πŸ”§ Key exchange parameters

πŸ”‘ pad (OSSL_EXCHANGE_PARAM_PAD) <unsigned integer> β€” See β€œCommon Key Exchange parameters” in provider-keyexch(7).

πŸ’‘ EXAMPLES

Keys for the host and peer can be generated as shown in β€œExamples” in EVP_PKEY-X25519(7).

The code to generate a shared secret is identical to β€œExamples” in EVP_KEYEXCH-DH(7).

πŸ”— SEE ALSO

πŸ”— EVP_PKEY-FFC(7), EVP_PKEY-DH(7), EVP_PKEY(3), provider-keyexch(7), provider-keymgmt(7), OSSL_PROVIDER-default(7), OSSL_PROVIDER-FIPS(7)

©️ COPYRIGHT

Copyright 2020 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_KEYEXCH-X25519(7SSL)

EVP_KEYEXCH-X25519(7)
πŸ“› NAME πŸš€ Quick Reference πŸ“– DESCRIPTION
πŸ”§ Key exchange parameters
πŸ’‘ EXAMPLES πŸ”— 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 11:50 @216.73.216.183
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