-
Notifications
You must be signed in to change notification settings - Fork 95
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
…or `EVP_PKEY`. This commit is an attempt to fix #372, by adding four new [`OSSL_PARAM`] to [`EVP_PKEY`]. The following [`OSSL_PARAM`] are added by this commit: - `hybrid_classical_pub`: an octet string to the classical public key. - `hybrid_classical_priv`: an octet string to the classical private key. - `hybrid_pq_pub`: an octet string to the quantum-resistant public key. - `hybrid_pq_priv`: an octet string to the quantum-resistant private key. Using [`EVP_PKEY_get_params`], OpenSSL users should be able to extract the specific subkey they want from an hybrid key. A test called `test_evp_pkey_params` has been added to ensure that it works with all hybrid algorithms, to also ensure that the output of these parameters are consistent between each other. [`OSSL_PARAM`]: https://www.openssl.org/docs/man3.2/man3/OSSL_PARAM.html [`EVP_PKEY`]: https://www.openssl.org/docs/man3.2/man7/evp.html [`EVP_PKEY_get_params`]: https://www.openssl.org/docs/man3.2/man3/EVP_PKEY_get_params.html Signed-off-by: thb-sb <[email protected]>
- Loading branch information
thb-sb
committed
Mar 18, 2024
1 parent
f08657b
commit d19518d
Showing
14 changed files
with
820 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
oqs-template/test/oqs_test_evp_pkey_params.c/hybrid_kem_algs.fragment
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
|
||
|
||
/** \brief List of hybrid KEMs. */ | ||
const char *kHybridKEMAlgorithms[] = { | ||
{%- for kem in config['kems'] %} | ||
{%- for hybrid in kem['hybrids'] %} | ||
"{{ hybrid['hybrid_group'] }}_{{ kem['name_group'] }}", | ||
{%- endfor %} | ||
{%- endfor %} | ||
NULL, | ||
}; |
14 changes: 14 additions & 0 deletions
14
oqs-template/test/oqs_test_evp_pkey_params.c/hybrid_sig_algs.fragment
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
|
||
|
||
/** \brief List of hybrid signature algorithms. */ | ||
const char *kHybridSignatureAlgorithms[] = { | ||
{% for sig in config['sigs'] %} | ||
{%- for variant in sig['variants'] %} | ||
{%- for classical_alg in variant['mix_with'] -%} | ||
"{{ classical_alg['name'] }}_{{ variant['name'] }}", | ||
{%- endfor -%} | ||
{%- endfor %} | ||
{%- endfor %} | ||
NULL, | ||
}; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.