diff options
author | tb <> | 2022-03-29 14:03:12 +0000 |
---|---|---|
committer | tb <> | 2022-03-29 14:03:12 +0000 |
commit | a7a9550038d6737fe60232569082b4e463ef1c5c (patch) | |
tree | f3eb1afef5a9f1e2847d1adc42bdfa0cefcf4a53 /src/lib/libcrypto/man | |
parent | 5474ea01ccbb75c0e017bd0a7735e0bbb8b14e9f (diff) | |
download | openbsd-a7a9550038d6737fe60232569082b4e463ef1c5c.tar.gz openbsd-a7a9550038d6737fe60232569082b4e463ef1c5c.tar.bz2 openbsd-a7a9550038d6737fe60232569082b4e463ef1c5c.zip |
Bound cofactor in EC_GROUP_set_generator()
Instead of bounding only bounding the group order, also bound the
cofactor using Hasse's theorem. This could probably be made a lot
tighter since all curves of cryptographic interest have small
cofactors, but for now this is good enough.
A timeout found by oss-fuzz creates a "group" with insane parameters
over a 40-bit field: the order is 14464, and the cofactor has 4196223
bits (which is obviously impossible by Hasse's theorem). These led to
running an expensive loop in ec_GFp_simple_mul_ct() millions of times.
Fixes oss-fuzz #46056
Diagnosed and fix joint with jsing
ok inoguchi jsing (previous version)
Diffstat (limited to 'src/lib/libcrypto/man')
0 files changed, 0 insertions, 0 deletions