aboutsummaryrefslogtreecommitdiffstats
path: root/src/tests/test_ffi.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Increase slop size in FFI testJack Lloyd2016-10-141-2/+3
| | | | | This is lame but I still cannot repro and random CI failures suck. Eventually I will fix the API.
* Work around a bug in FFIJack Lloyd2016-08-281-3/+29
| | | | This seems to trigger under ARM
* Travis CI additions and cleanupJack Lloyd2016-08-281-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Convert Travis build configuration to a single var instead of 4 tuple. Makes it much easier to review the builds in the Travis web UI. Adds sanitizer builds for Clang on both Linux and OS X. Clang is a different compiler from GCC and its sanitizers may catch things GCC does not. I have no idea if Apple's Clang has some magic sanitizer sauce stock LLVM does not, so maybe sanitizer build on OS X can be skipped. Adds Linux cross compile targets for ARM32, ARM64, PPC64, and MinGW x86 using the cross compiler available in Trusty. All of them build and are set up to run through qemu/wine. All of the tests currently fail and so are marked as expected fail in the Travis matrix. The ARM test runs seem to have thread problems; ARM32 thread creation just fails with an exception, as if pthreads was disabled. All other tests pass ok for ARM32. On Aarch64, it looks like there is a hard crash the first time the library tries creating a thread. Both of these might be due to statically linking the binary? I have been unable to convince Ubuntu's qemu-ppc64 to execute binaries compiled by Ubuntu's ppc64 cross compiler. I'm downloading an Ubuntu ISO to try this in a VM. Running under Wine exposes several issues, both in Wine and Botan. Many functions are stubs and it appears that entropy collection fails as a result. This triggers a bug in the FFI tests which causes a crash there. A pox on time zones; _mkgmtime is a MSVC extension and is not available on MinGW GCC. Add a last resort call that just uses the localzone variant instead. Adds valgrind target, remove a bogus poison in pubkey.cpp (it was effectively asserting that all of RSA was const time which is sadly not true at all). Moves -Wshadow to maintainer mode for GCC - GCC 4.8 has a noisy variant of -Wshadow which warns if a parameter masks a function name, but this comes up all the time in constructors. Later GCCs no longer warn about this (even with -Wshadow), so the warnings are never fixed, but they cause noise in CI output and hide interesting warnings like warning: vec_lvsl is deprecated for little endian; use assignment for unaligned loads and stores [-Wdeprecated] __vector unsigned char perm = vec_lvsl(0, static_cast<u32bit*>(nullptr));
* add label parameter to KDF::derive_keyKai Michaelis2016-05-191-1/+3
|
* Add more tests for ffiRené Korthaus2016-03-251-5/+285
|
* Fix memory leaks in FFI testsJack Lloyd2016-02-091-7/+16
| | | | | | | | | | Some tests only deallocated in the branch where some other test on the object succeeded. The ECDH FFI test didn't deallocate any of its objects, which was missed by valgrind before now because the test was not being run. Found by Coverity scanner
* Prevent FFI tests from failing if bcrypt is disabled. GH #369Jack Lloyd2015-12-191-4/+10
|
* Update and consolidate the test framework.Jack Lloyd2015-11-111-330/+335
| | | | | | | | | | | 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.
* Merge pull request #317 from randombit/cc-flag-sanityJack Lloyd2015-10-271-2/+1
|\ | | | | Split up build options
| * Remove --build-mode and add individual toggles for optimization, debug,Jack Lloyd2015-10-261-2/+1
| | | | | | | | | | | | sanitizers and coverage as all 4 are usefully set independently. Use GCC 4.9 on CircleCI as it seems to be supported. Add ASan + UBSan test.
* | Reduce workfactors in ffi tests to speed things alongJack Lloyd2015-10-271-2/+2
|/
* Fix bcrypt testJack Lloyd2015-10-031-1/+1
|
* Fix pbkdf, pk padding and ECDH registration for static linking.Jack Lloyd2015-09-111-5/+5
| | | | | | | | With this change the tests pass when linked against a static library built in the normal (non-amalgamation) fashion. Remove the restriction in configure.py, and have circleci build the clang static build as a non-amalg.
* Reactivate FFI PBKDF minimum iterations testSimon Warta2015-08-211-3/+2
| | | | | as dicussed here: https://github.com/randombit/botan/commit/480999c2820b0da995108d7474a74755cafd2924
* Deactivate tests that consistently fail in debug modeSimon Warta2015-08-091-0/+8
| | | | [ci skip]
* Refactor most of FFI test for matchersSimon Warta2015-08-081-103/+149
|
* Refactor catchy testsSimon Warta2015-08-081-1/+1
| | | | | | | | * Add std::vector matcher * Add test_base to ensure Botan::vector<X> works with matcher * Rewrite base64 tests from CHECK( to CHECK_THAT( Closes #206
* Add tests for RSA, ECDSA, and ECDH interfaces in FFI moduleJack Lloyd2015-07-181-36/+210
|
* Timing ratio is too tight for CI VMsJack Lloyd2015-07-181-1/+1
|
* Add tests for some of the C89 interface.Jack Lloyd2015-07-181-0/+170
Add missing returns to botan_kdf, botan_pbkdf, botan_pbkdf_timed; previously they always returned an error code.