diff options
author | Nicola Tuveri <nic.tuv@gmail.com> | 2020-11-10 01:11:48 +0200 |
---|---|---|
committer | Nicola Tuveri <nic.tuv@gmail.com> | 2021-01-08 23:59:02 +0200 |
commit | 9e49aff2aaac4c42ea6c4078266947c75761276b (patch) | |
tree | 10b470a0ce3fcbc13bb26290003f10f0d5c60116 /apps/x509.c | |
parent | 4554988e582e676a51c451de031939b45e60d00c (diff) | |
download | openssl-new-9e49aff2aaac4c42ea6c4078266947c75761276b.tar.gz |
Add SM2 private key range validation
According to the relevant standards, the valid range for SM2 private
keys is [1, n-1), where n is the order of the curve generator.
For this reason we cannot reuse the EC validation function as it is, and
we introduce a new internal function `sm2_key_private_check()`.
Partially fixes https://github.com/openssl/openssl/issues/8435
Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
(Merged from https://github.com/openssl/openssl/pull/13359)
Diffstat (limited to 'apps/x509.c')
0 files changed, 0 insertions, 0 deletions