diff options
author | Richard Levitte <levitte@openssl.org> | 2020-10-26 13:22:54 +0100 |
---|---|---|
committer | Richard Levitte <levitte@openssl.org> | 2020-11-11 11:42:06 +0100 |
commit | 2c090c1d1b00fe49dd2911674e26c629f123c44f (patch) | |
tree | 6966886dfcde93a1ea601c5a13af79c7f3aa6041 /providers/baseprov.c | |
parent | de5008a4076e36f7038180d60ae1521afb524d68 (diff) |
PROV: Re-implement all the keypair decoders
The base functionality to implement the keypair decoders doesn't
change much, but this results in a more massive amount of
OSSL_DISPATCH and OSSL_ALGORITHM arrays, to support a fine grained
selection of implementation based on what parts of the keypair
structure (combinations of key parameters, public key and private key)
should be expected as input, the input type ("DER", "PEM", ...) and the
outermost input structure ("pkcs8", "SubjectPublicKeyInfo", key
type specific structures, ...).
We add support for the generic structure name "type-specific", to
allow selecting that without knowing the exact name of that structure.
Reviewed-by: Shane Lontis <shane.lontis@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/13248)
Diffstat (limited to 'providers/baseprov.c')
-rw-r--r-- | providers/baseprov.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/providers/baseprov.c b/providers/baseprov.c index 019caf10d6..18d664aa29 100644 --- a/providers/baseprov.c +++ b/providers/baseprov.c @@ -80,15 +80,11 @@ static const OSSL_ALGORITHM base_encoder[] = { #undef ENCODER static const OSSL_ALGORITHM base_decoder[] = { -#define DECODER(name, _fips, _input, func_table) \ - { name, \ - "provider=base,fips=" _fips ",input=" _input, \ - (func_table) } - +#define DECODER_PROVIDER "base" #include "decoders.inc" { NULL, NULL, NULL } +#undef DECODER_PROVIDER }; -#undef DECODER static const OSSL_ALGORITHM base_store[] = { #define STORE(name, _fips, func_table) \ |