From 8efc4a9c656b8b3eabeac64c54efdeb07dd42f8e Mon Sep 17 00:00:00 2001 From: Matt Caswell Date: Fri, 28 Feb 2020 08:08:59 +1000 Subject: Implement the ECX Serializers Provide serializers for X25519 and X448 for text, pem and der. There are no parameter serializers because there are no parameters for these algorithms. Add some documentation about the various import/export types available Add additional testing for the serializers Reviewed-by: Shane Lontis (Merged from https://github.com/openssl/openssl/pull/11095) --- providers/defltprov.c | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) (limited to 'providers/defltprov.c') diff --git a/providers/defltprov.c b/providers/defltprov.c index d513dbe..9400eee 100644 --- a/providers/defltprov.c +++ b/providers/defltprov.c @@ -470,6 +470,34 @@ static const OSSL_ALGORITHM deflt_serializer[] = { dsa_param_pem_serializer_functions }, #endif +#ifndef OPENSSL_NO_EC + { "X25519", "provider=default,format=text,type=private", + x25519_priv_print_serializer_functions }, + { "X25519", "provider=default,format=text,type=public", + x25519_pub_print_serializer_functions }, + { "X25519", "provider=default,format=der,type=private", + x25519_priv_der_serializer_functions }, + { "X25519", "provider=default,format=der,type=public", + x25519_pub_der_serializer_functions }, + { "X25519", "provider=default,format=pem,type=private", + x25519_priv_pem_serializer_functions }, + { "X25519", "provider=default,format=pem,type=public", + x25519_pub_pem_serializer_functions }, + + { "X448", "provider=default,format=text,type=private", + x448_priv_print_serializer_functions }, + { "X448", "provider=default,format=text,type=public", + x448_pub_print_serializer_functions }, + { "X448", "provider=default,format=der,type=private", + x448_priv_der_serializer_functions }, + { "X448", "provider=default,format=der,type=public", + x448_pub_der_serializer_functions }, + { "X448", "provider=default,format=pem,type=private", + x448_priv_pem_serializer_functions }, + { "X448", "provider=default,format=pem,type=public", + x448_pub_pem_serializer_functions }, +#endif + { NULL, NULL, NULL } }; -- cgit v1.1