5 EVP_PKEY-X25519, EVP_PKEY-X448, EVP_PKEY-ED25519, EVP_PKEY-ED448,
6 EVP_KEYMGMT-X25519, EVP_KEYMGMT-X448, EVP_KEYMGMT-ED25519, EVP_KEYMGMT-ED448
7 - EVP_PKEY X25519, X448, ED25519 and ED448 keytype and algorithm support
11 The B<X25519>, B<X448>, B<ED25519> and B<ED448> keytypes are
12 implemented in OpenSSL's default provider.
14 =head2 Common X25519, X448, ED25519 and ED448 parameters
16 The following Import/Export types are available for the built-in X25519, X448,
17 ED25519 and X448 algorithms:
21 =item "pub" (B<OSSL_PKEY_PARAM_PUB_KEY>) <octet string>
25 =item "priv" (B<OSSL_PKEY_PARAM_PRIV_KEY>) <octet string>
27 The private key value.
31 =head2 ED25519 and ED448 parameters
35 =item "mandatory-digest" (B<OSSL_PKEY_PARAM_MANDATORY_DIGEST>) <utf8 string>
37 The empty string, signifying that no digest may be specified.
51 An B<EVP_PKEY> context can be obtained by calling:
54 EVP_PKEY_CTX_new_from_name(NULL, "X25519", NULL);
57 EVP_PKEY_CTX_new_from_name(NULL, "X448", NULL);
60 EVP_PKEY_CTX_new_from_name(NULL, "ED25519", NULL);
63 EVP_PKEY_CTX_new_from_name(NULL, "ED448", NULL);
65 An B<ED25519> key can be generated like this:
67 EVP_PKEY *pkey = NULL;
69 EVP_PKEY_CTX_new_from_name(NULL, "ED25519", NULL);
71 EVP_PKEY_keygen_init(pctx);
72 EVP_PKEY_gen(pctx, &pkey);
73 EVP_PKEY_CTX_free(pctx);
75 An B<X25519> key can be generated in a similar way:
77 EVP_PKEY *pkey = NULL;
79 EVP_PKEY_CTX_new_from_name(NULL, "X25519", NULL);
81 EVP_PKEY_keygen_init(pctx);
82 EVP_PKEY_gen(pctx, &pkey);
83 EVP_PKEY_CTX_free(pctx);
87 L<EVP_KEYMGMT(3)>, L<EVP_PKEY(3)>, L<provider-keymgmt(7)>,
88 L<EVP_KEYEXCH-X25519(7)>, L<EVP_KEYEXCH-X448(7)>,
89 L<EVP_SIGNATURE-ED25519(7)>, L<EVP_SIGNATURE-ED448(7)>
93 Copyright 2020 The OpenSSL Project Authors. All Rights Reserved.
95 Licensed under the Apache License 2.0 (the "License"). You may not use
96 this file except in compliance with the License. You can obtain a copy
97 in the file LICENSE in the source distribution or at
98 L<https://www.openssl.org/source/license.html>.