aboutsummaryrefslogtreecommitdiffstats
path: root/src/tests/test_mac.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Reformat code with astyle + fix code styleTomasz Frydrych2017-05-011-5/+5
|
* Filter provider in test loops, skip text based without provider.Alexander Bluhm2017-04-211-1/+6
| | | | | | | | 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.
* Minor refactoring of Text_Based_TestJack Lloyd2016-12-191-2/+1
| | | | | | 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.
* Add test for various functions previously missed (T::clone, PBKDF::name, ↵Jack Lloyd2016-11-261-1/+8
| | | | | | | 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.
* Add MAC::start_msg, update GMACJack Lloyd2016-10-281-33/+6
| | | | | | | | GMAC needs a per-message nonce specified with `start`, and other MACs are capable of using nonces (Skein-MAC, for instance) so move this API up to MAC class. Change GMAC::clone to clone the owned cipher.
* Implements GMAC with GHASH.Matthias Gierlings2016-10-281-0/+30
| | | | | Adds support for Galois Message Authentication Code calculation based on GHASH, rather than GCM_Mode.
* Added implementation for GMACMatthias Gierlings2016-10-271-8/+14
| | | | | | - Added GMAC class - Integrated GMAC into MAC-Class test bench. Run GMAC tests using ./botan-test mac
* Add T::provider() to allow user to inquire about implementation usedJack Lloyd2016-09-151-3/+6
| | | | | For block ciphers, stream ciphers, hashes, MACs, and cipher modes. Cipher_Mode already had it, with a slightly different usage.
* fix SipHash::clear() and MAC test improvementsDaniel Neus2016-07-201-1/+19
| | | | | | | | Fix for SipHash::clear() which does not clear the complete state. Test additions: - add a test for MessageAuthenticationCode::verify_mac() - test MessageAuthenticationCode::clear()
* Add --data-dir option to test commandJack Lloyd2015-12-201-1/+1
| | | | | | | Understand using '-' on the command line to mean stdin Fix last few unit tests that wanted to write to the filesystem; removes outdata directory.
* Convert const char* arguments on Test:: to std::stringsJack Lloyd2015-11-281-1/+1
| | | | unless they are actually optional
* Update and consolidate the test framework.Jack Lloyd2015-11-111-70/+48
| | | | | | | | | | | The tests previously had used 4 to 6 different schemes internally (the vec file reader framework, Catch, the old InSiTo Boost.Test tests, the PK/BigInt tests which escaped the rewrite in 1.11.7, plus a number of one-offs). Converge on a design that works everywhere, and update all the things. Fix also a few bugs found by the test changes: SHA-512-256 name incorrect, OpenSSL RC4 name incorrect, signature of FFI function botan_pubkey_destroy was wrong.
* Don't treat missing ciphers, hashes, etc as test failuresJack Lloyd2015-10-111-1/+1
| | | | | Just print an error message and return. Reduces false fails with smaller builds
* Remove use of lookup.h in favor of new T::create API.Jack Lloyd2015-09-211-3/+2
|
* Fix TEST_DATA_DIRSimon Warta2015-07-151-1/+1
|
* Make Botan compile when only some modules are enabledSimon Warta2015-07-031-0/+8
| | | | Fixes #146.
* Replace \n by std::endl in tests to ensure proper flushingSimon Warta2015-06-191-4/+4
| | | | | | | - Remove additional newlines in CHECK_MESSAGE call - Remove redundant output of algo in aead_test() Closes #115
* Remove algo factory, engines, global RNG, global state, etc.lloyd2015-02-041-9/+5
| | | | | | | | | | | | | | | Convert all uses of Algorithm_Factory and the engines to using Algo_Registry The shared pool of entropy sources remains but is moved to EntropySource. With that and few remaining initializations (default OIDs and aliases) moved elsewhere, the global state is empty and init and shutdown are no-ops. Remove almost all of the headers and code for handling the global state, except LibraryInitializer which remains as a compatability stub. Update seeding for blinding so only one hacky almost-global RNG instance needs to be setup instead of across all pubkey uses (it uses either the system RNG or an AutoSeeded_RNG if the system RNG is not available).
* Add SipHashlloyd2015-01-111-4/+24
|
* Ensure all files have copyright and license info.lloyd2015-01-101-0/+6
| | | | | Update license header line to specify the terms and refer to the file, neither of which it included before.
* Add ChaChalloyd2014-01-311-0/+6
|
* Split up docs into the reference manual, the website, and everything else.lloyd2014-01-101-0/+67
| | | | | | | | | | | Add `website` target to makefile. Some progress towards fixing minimized builds. TLS now hard requires ECDSA and GCM since otherwise a minimized build has only insecure options. Remove boost_thread dependency in command line tool
* Rename test sourceslloyd2014-01-071-62/+0
|
* Split up public key tests and data, use new test frameworklloyd2014-01-051-7/+7
|
* Shuffle things around. Add NIST X.509 test to build.lloyd2014-01-011-0/+62