| Commit message (Collapse) | Author | Age | Files | Lines |
| | |
|
| | |
|
| |
|
|
|
|
|
| |
Otherwise tls_error_clear() (called e.g. via tls_error_vset()) will
free the bad error->msg pointer.
From Michael Forney
|
| |
|
|
|
|
|
|
|
|
|
| |
on a SAN DNSname constraint. This is not correct, as with
a DNSname constraint, it may exacly match or match zero or
more additional components on the front of the candidte to
match.
Spotted by Haruto Kimura <hkimura2026@gmail.com>
ok tb@ kenjiro@
|
| | |
|
| | |
|
| | |
|
| |
|
|
| |
The second case (14b) currently triggers a bug in the new verifier.
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
| |
Add the three RSASSA-PSS SignatureScheme 0x080b, 0x080a, 0x0809 in the
appropriate spots in (components of) the ClientHello and adjust various
length octets by adding 6.
|
| |
|
|
| |
include.
|
| | |
|
| |
|
|
|
|
| |
This improves the test coverage of make_addressRange() where there is an
annoyance with unused bits in the RFC 3779 ASN.1 encoding versus trailing
ones in the network encoding that the X509v3_addr_add_range() API expects.
|
| |
|
|
| |
discussed with jsing
|
| | |
|
| | |
|
| |
|
|
|
|
| |
This requires egcc to be installed, if not we'll just skip the test.
Discussed with tb@
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
| |
Also has code to check the RFC 7919 primes and run DH_check() once that
knows about these.
|
| |
|
|
|
| |
Installed packages will update and pkg_add wycheproof-testvectors will
continue to work.
|
| | |
|
| |
|
|
|
| |
This adds coverage for MLKEM_private_key_from_seed(), which was previously
only minimal teted from our regress.
|
| |
|
|
|
| |
New testvectors want some more detailed handling, which brings these
Wycheproof encapsulation tests about on par with our existing tests.
|
| | |
|
| | |
|
| |
|
|
|
| |
An update to the test vectors adds tests which verifies that the API
correctly rejects some inputs.
|
| |
|
|
|
|
|
|
|
|
| |
libc call, flockfile() and ftrylockfile() can be called when
single-threaded and then--while 'holding' the lock--the process can
create another thread, resulting in a broken state. Have the
f{lock,trylock,unlock}file() APIs *always* do real locking so the
exposed state is always consistent.
ok dlg@
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A nasty quirk in the bit string handling is that the serialization
produced by i2d_ASN1_BIT_STRING() depends on whether the the magic
ASN1_STRING_FLAG_BITS_LEFT is set.
If ASN1_STRING_FLAG_BITS_LEFT is set, the number of unused bits is
carried in a->flags & 0x07 and the remainder of the bit string is
in a->data. This is terrible and undocumented but handled correctly.
If ASN1_STRING_FLAG_BITS_LEFT is not set, all trailing zero bits are
(intended to be) chopped off with all sorts of hilarious side effects.
I broke this quite thoroughly when I incorrectly ported an overflow
check from BoringSSL in:
https://github.com/openbsd/src/commit/f81cc285d2aed8b36615119a306533696f3eb66c
The result is that we currently return ret = a->length + 1 for both NULL
and non-NULL pp. The calls to asn1_ex_i2c() in asn1_i2d_ex_primitive()
thus report consistent lengths back, making it succeed.
asn1_i2d_ex_primitive() therefore skips a->length + 1 bytes, while
i2c_ASN1_BIT_STRING() only overwrites len + 1 bytes, which are possibly
fewer. So a caller passing in an output buffer containing garbage
(malloc) will get some of that garbage back in the encoding. Further,
i2c_ASN1_BIT_STRING() also advances that pointer by the possibly reduced
len + 1, but that fortunately doesn't matter since that's an effect
local to asn1_ex_i2c(), the only caller of i2c_ASN1_BIT_STRING().
The last bit is that the current behavior may set bogus unused bits
coming from the scanning backward madness. I added such an example in
the parent commit.
The fix is simple: use len after the truncation effect was established,
not the original a->length, turning this commit into what my backport
should have been.
This fixes the two currently failing regress tests, so remove expected
failure marker again.
ok jsing kenjiro
|
| |
|
|
| |
This is another test that fails due to the bug in i2c_ASN1_BIT_STRING().
|
| |
|
|
| |
This test fails, so mark the asn1basic test as an expected failure
|
| |
|
|
|
|
| |
There is a bug in i2c_ASN1_BIT_STRING() resulting in nonsense encoding of
some BIT STRINGs with trailing zeroes if ASN1_STRING_FLAG_BITS_LEFT is not
set (a rare corner case). This test currently passes when it shouldn't.
|
| | |
|
| |
|
|
|
|
|
|
|
| |
RANK768 and RANK1024 are awfully short and generic names for public
constants. Before we make it worse with similarly named constants for
ML-DSA, let's fix this. This follows the naming convention used by the
other macros in the mlkem code.
ok kenjiro jsing
|
| | |
|
| | |
|
| |
|
|
| |
alright. go home.
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
|
| |
Exercises the batshit crazy truncation behavior of ASN1_BIT_STRING_set_bit()
Based on https://boringssl-review.googlesource.com/c/boringssl/+/48225
(still under ISC).
|
| | |
|
| | |
|
| | |
|
| |
|
|
| |
pointed out by kenjiro
|
| | |
|