| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
This allows --test-runs= to work as expected
|
| |
|
| |
|
|
|
|
| |
Some help from include-what-you-use
|
|\ |
|
| |
| |
| |
| |
| |
| |
| | |
Allows PSS-signing a raw hash while also still specifying the salt
length.
GH #1211
|
| |
| |
| |
| | |
Remove CT::min and CT::max which were unused and it turns out, broken.
|
|\ \
| |/
|/| |
|
| |
| |
| |
| |
| | |
Ted Krovetz confirmed there were bugs in the reference code for
blocks > 128 bits so these values should be the correct ones.
|
|/ |
|
|
|
|
| |
Based on patch from Jeffrey Walton in GH #841
|
|
|
|
| |
Based on GH #807 and #808
|
|\ |
|
| |
| |
| |
| |
| | |
Implement RSA private key generation with RSA_generate_key_ex().
Make PK_Key_Generation_Test iterate over all providers.
|
|/ |
|
|
|
|
|
|
|
| |
Curious test failure, HMAC(MD5) failing with "invalid IV length"
(HMAC doesn't support an IV), it turned out to be the IV was left
around from the previously run GMAC test. Just clear out all vars
if a new [algo] header is seen in the file.
|
|
|
|
|
|
|
|
| |
The tests for block, hash, stream, pubkey, and mac loop over all
possible crypto providers. If a specific provider is given on the
botan-test command line, use only this one. If the provider to be
tested is restricted, skip text based tests that do not have a
possible provider.
|
|
|
|
|
|
|
|
| |
Currently botan runs the tests for all crypto providers it can find.
Add a --provider option for botan-test to specify exactly one
provider. This allows to see which parts of a specific implementation
have been tested. Pass down the given provider to a specific test
class.
|
| |
|
|
|
|
| |
Tested on qemu-aarch64
|
|
|
|
| |
Instead just let the individual tests that need the RNG fail.
|
| |
|
|
|
|
|
|
|
| |
Fix a bug in Pipe::check_available that must date back 15 years...
Add destructors to compression filter so unique_ptr destructor runs
without user having to include an extra header for the owned type.
|
| |
|
|
|
|
|
|
| |
Previously longer tests were hidden behind higher 'soak levels'
but these arbitrary cutoffs are confusing compared to a simple
short tests/long tests split.
|
|
|
|
|
|
| |
Turns out astyle has some bugs wrt C++11 initialize lists. Rather
than having astyle mangle all of the tests, convert to using a string
which is split once at the start instead of a vector of keys.
|
|
|
|
|
|
|
|
|
|
|
|
| |
When the code was changed in b8966d0f89e, the offset was not changed,
so it would reject ciphertexts with exactly 8 bytes of random padding
(the required minimum).
Found by pkcs1 fuzzer which also had problems due to not having been
updated at the same time.
Add a test suite for decoding of PK decryption padding to cover the
problem cases.
|
|
|
|
|
|
|
| |
AEAD::output_length)
Fix a bug in CCM, GCM, and OCB decryption which caused `output_length(tag_size())`
to fail even though empty plaintexts are certainly defined for all three modes.
|
|
|
|
| |
Tests touching network are gated by --run-online-tests flag.
|
|
|
|
| |
Document that create_*_op is public but not for public consumption.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
TLS message parsing:
- CertificateVerify
- HelloVerify
- ClientHello (with extensions)
- ServerHello (with extensions)
- NewSessionTicket
- Alert
TLS message processing:
- HelloVerify
TLS Policy tests
Unit tests with TLS client authentication
Added test_throws method that checks the correct exception message.
|
|
|
|
|
| |
For block ciphers, stream ciphers, hashes, MACs, and cipher modes.
Cipher_Mode already had it, with a slightly different usage.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Change reseed interval logic to count calls to `randomize` rather than
bytes, to match SP 800-90A
Changes RNG reseeding API: there is no implicit reference to the
global entropy sources within the RNGs anymore. The entropy sources
must be supplied with the API call. Adds support for reseding directly
from another RNG (such as a system or hardware RNG).
Stateful_RNG keeps optional references to both an RNG and a set of
entropy sources. During a reseed, both sources are used if set.
These can be provided to HMAC_DRBG constructor.
For HMAC_DRBG, SP800-90A requires we output no more than 2**16 bytes
per DRBG request. We treat requests longer than that as if the caller
had instead made several sequential maximum-length requests. This
means it is possible for one or more reseeds to trigger even in the
course of generating a single (long) output (generate a 256-bit key
and use ChaCha or HKDF if this is a problem).
Adds RNG::randomize_with_ts_input which takes timestamps and uses them
as the additional_data DRBG field. Stateful_RNG overrides this to also
include the process ID and the reseed counter. AutoSeeded_RNG's
`randomize` uses this.
Officially deprecates RNG::make_rng and the Serialized_RNG construtor
which creates an AutoSeeded_RNG. With these removed, it would be
possible to perform a build with no AutoSeeded_RNG/HMAC_DRBG at all
(eg, for applications which only use the system RNG).
Tests courtesy @cordney in GH PRs #598 and #600
|
| |
|
|
|
|
| |
and add the possibility to compare OctetStrings with the botan test-framework
|
| |
|
| |
|
|
|
|
| |
fix PVS-Studio perfomance warnings
|
| |
|
|
|
|
|
|
| |
Improve diagnostics when an exception escapes a test
GH #369
|
|
|
|
|
|
|
| |
Understand using '-' on the command line to mean stdin
Fix last few unit tests that wanted to write to the filesystem; removes
outdata directory.
|
|
|
|
|
|
| |
Also fix KDF tests which failed on missing algo
GH #367
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The command line tools' origin as a collection of examples and test
programs glued together led to some unfortunate problems; lots of
hardcoded values, missing parameters, and obsolete crypto.
Adds a small library for writing command line programs of the sort
needed here (cli.h), which cuts the length of many of the commands in
half and makes commands more pleasant to write and extend.
Generalizes a lot of the commands also, eg previously only
signing/verification with DSA/SHA-1 was included!
Removes the fuzzer entry point since that's fairly useless outside of
an instrumented build.
Removes the in-library API for benchmarking.
|
|
|
|
|
|
|
|
| |
As the alternatives are unfortunate for applications trying to catch
all library errors, and it seems deriving from std::runtime_error
causes problems with MSVC DLLs (GH #340)
Effectively reverts 2837e915d82e43
|
|
|
|
| |
unless they are actually optional
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Fix a bug which rejected any short server key exchanges. These can
occur with a plain PSK with short or empty identity hints.
Disable SHA-224 by default.
Remove some vestigal RC4 cruft.
Push more on the TLS corruption tests.
|
|
|
|
|
|
|
|
|
| |
The Boost directory iterator throws an exception in that case.
Interestingly the current VC version does not seem to. In the
interests of portability just avoid this operation rather than trying
to hack around it in the Boost fs version.
GH #328
|