diff options
author | schwarze <> | 2020-06-04 21:21:03 +0000 |
---|---|---|
committer | schwarze <> | 2020-06-04 21:21:03 +0000 |
commit | d0cf9aeca512581235a63d9ed8e8a3c69039b9df (patch) | |
tree | 2920ef908eabfe843f01bfd04a3aaf4eff0a1cec /src/lib/libcrypto/ec/ec_curve.c | |
parent | 53beb8fe96aa9ab3ce5c57b525e3a1fbb817382e (diff) | |
download | openbsd-d0cf9aeca512581235a63d9ed8e8a3c69039b9df.tar.gz openbsd-d0cf9aeca512581235a63d9ed8e8a3c69039b9df.tar.bz2 openbsd-d0cf9aeca512581235a63d9ed8e8a3c69039b9df.zip |
When X509_ATTRIBUTE_create() receives an invalid NID (e.g., -1), return
failure rather than silently constructing a broken X509_ATTRIBUTE object
that might cause NULL pointer accesses later on. This matters because
X509_ATTRIBUTE_create() is used by documented API functions like
PKCS7_add_attribute(3) and the NID comes straight from the user.
This fixes a bug found while working on documentation.
OK tb@ and "thanks" bluhm@
Diffstat (limited to 'src/lib/libcrypto/ec/ec_curve.c')
0 files changed, 0 insertions, 0 deletions