diff options
author | tb <> | 2022-04-07 17:37:25 +0000 |
---|---|---|
committer | tb <> | 2022-04-07 17:37:25 +0000 |
commit | 8d808b1fad425472f16e190aa9c72037b7efe75a (patch) | |
tree | d24b9a5f8727ef577e3036c13bcebc52ae475072 /src/lib/libcrypto/asn1/a_object.c | |
parent | 491cd486a581a71008b2ca3b70aeb7c2ef32b32b (diff) | |
download | openbsd-8d808b1fad425472f16e190aa9c72037b7efe75a.tar.gz openbsd-8d808b1fad425472f16e190aa9c72037b7efe75a.tar.bz2 openbsd-8d808b1fad425472f16e190aa9c72037b7efe75a.zip |
Avoid infinite loop for custom curves of order 1
If a private key encoded with EC parameters happens to have
order 1 and is used for ECDSA signatures, this causes an
infinite loop since a random integer x in the interval [0,1)
will be 0, so do ... while (x == 0); will loop indefinitely.
Found and reported with a reproducer by Hanno Boeck.
Helpful comments and analysis from David Benjamin.
ok beck jsing
Diffstat (limited to 'src/lib/libcrypto/asn1/a_object.c')
0 files changed, 0 insertions, 0 deletions