63 Commits

Author SHA1 Message Date
Michael Rash e82cb8621f [test suite] another bogus user test for fko-wrapper 2018-08-19 16:24:08 -07:00
Michael Rash d7aacb68f2 [test suite] add bogus username test to fko-wrapper 2018-08-19 16:21:47 -07:00
Michael Rash d328278cb8 [test suite] minor Makefile enhancement (variable usage) for fko-wrapper 2018-08-19 14:02:42 -07:00
Michael Rash 57ef059811 [test suite] add calls to fko_set_raw_spa_digest_type() and fko_get_raw_spa_digest_type() 2018-08-19 12:40:14 -07:00
Michael Rash 62336616d7 [test suite] minor decoding and fko_set_timestamp() exercise enhancements for fko_wrapper 2018-08-18 09:41:23 -07:00
Jonathan Bennett 108a669730 Update fko_wrapper to reflect SHA3 changing MAX_DIGEST_BLOCK_LEN 2016-01-11 00:04:09 -06:00
Michael Rash d70e3f3fbb [fko-wrapper] add 'usban' compilation directive 2015-12-10 14:36:14 -08:00
Michael Rash 0c455ebf9c [test suite] ensure fko-wrapper passes 16-byte string to fko_set_rand_value() 2015-12-09 17:15:48 -08:00
Michael Rash d4ca18dae6 [test suite] more comprehensive code coverage driven by fko-wrapper 2015-12-04 19:04:23 -08:00
Michael Rash 21149faf89 [libfko] fko_set_username() crash bug fix.
Bug fix for a crash in libfko that could be triggered in fko_set_username()
when a username that is 64 chars or longer is specified. This crash
cannot be triggered in fwknopd even if an SPA packet contains such a
username however due to additional protections in the SPA decoding
routines. Further, this bug does not apply to the main fwknop client
either because the maximal username size is truncated down below 64
bytes. Hence, this bug only applies to client-side software that is
directly using libfko calling the fko_set_username() function.
2015-12-04 19:01:26 -08:00
Michael Rash c67008b6a8 minor fault injection tag rework for fko_set_rand_value() and fko_set_username() 2015-11-30 12:28:59 -08:00
Michael Rash 6116419e21 [test suite] ensure HMAC key string is equal to SHA512_BLOCK_LEN in length (fixes ASAN warning) 2015-07-24 10:43:53 -07:00
Michael Rash 43f38551c9 [test suite] add ASAN mode to fko-wrapper 2015-07-14 21:26:44 -04:00
Michael Rash a99bff9b63 [test suite] minor Makefile update for fko-wrapper 2014-12-06 19:58:33 -05:00
Michael Rash eed3418996 [test suite] update wrapper Makefile gcc -> cc 2014-07-22 17:35:19 -04:00
Michael Rash 55a03f3392 [test suite] added suppressions to fko-wrapper/run_valgrind.sh 2014-06-16 17:12:59 -04:00
Michael Rash 4878607254 [libfko] removed fko_new_strdup() fault injection tag since fko_destroy() isn't called 2014-06-16 17:11:52 -04:00
Michael Rash 06ce514111 [test suite] add several fault injection tests 2014-06-12 00:02:18 -04:00
Michael Rash dfeecf5c29 [test suite] additional fix for duplicate fault injection tags 2014-06-06 10:31:07 -04:00
Michael Rash 1b4d7f5b19 [test suite] minor fix for duplicate fault injection tags 2014-06-06 10:25:33 -04:00
Michael Rash ddaf0134d6 use fiu.h instead of fiu-local.h 2014-05-26 15:54:12 -04:00
Michael Rash 237602114f [test suite] minor fko_wrapper comment update 2014-05-26 08:40:26 -04:00
Michael Rash d625a24a87 [test suite] added fko_new_with_data() call with SPA data that is too short 2014-05-25 15:08:31 -04:00
Michael Rash 597a3d3953 [libfko] added fault injections for remaining ...set...() functions called by fko_new() 2014-05-24 15:12:07 -04:00
Michael Rash 5f227cfa48 [libfko] added fault injections for fko_set_username() 2014-05-24 14:47:10 -04:00
Michael Rash 17f325eceb [libfko] added fault injections for fko_set_rand_value() 2014-05-24 14:01:49 -04:00
Michael Rash 35ad832392 [libfko] started on libfiu fault injection code 2014-05-24 10:14:28 -04:00
Michael Rash a2f2777e9f [test suite] add fko_basic.c file to the FKO wrapper 2014-05-22 08:24:16 -05:00
Michael Rash 84821438bd [test suite] started on support for libfiu fault injection tests 2014-05-20 21:20:10 -04:00
Michael Rash 7cb8ad9528 [fko-wrapper] add missing fko_destroy() call 2014-05-09 20:53:32 -04:00
Michael Rash 33234183df [test stuie] fko-wrapper PKT_ID generation + send fuzzing packets back through fko_new_with_data() cycle 2014-05-08 07:46:13 -04:00
Michael Rash 9901d8a76a [libfko/test suite] add the FUZZING_INTERFACES macro
Add a new fko_set_encoded_data() function gated by #define
FUZZING_INTERFACES to allow encryption and authentication to be bypassed
for fuzzing purposes (and only fuzzing purposes).  The fko-wrapper code
has been extended to process data in the
test/fko-wrapper/fuzz_spa_payloads file, which is created by the new
python fuzzer.  Typical workflow is:

$ cd test/fko-wrapper
$ ../spa_fuzzer.py > fuzz_spa_payloads
$ make fuzzing

(as root):

./test-fwknop.pl  --enable-profile-coverage --enable-fuzzing-interfaces --enable-all --include wrapper

[+] Starting the fwknop test suite...

    args: --enable-profile-coverage --enable-fuzzing-interfaces --enable-all --include wrapper

    Saved results from previous run to: output.last/

    Valgrind mode enabled, will import previous coverage from:
        output.last/valgrind-coverage/

[+] Total test buckets to execute: 2

[Rijndael] [fko-wrapper] multiple libfko calls (with valgrind)......pass (1)
[Rijndael] [fko-wrapper] multiple libfko calls......................pass (2)
[profile coverage] gcov profile coverage............................pass (3)
[valgrind output] [flagged functions] ..............................pass (4)

    Run time: 5.85 minutes

[+] 0/0/0 OpenSSL tests passed/failed/executed
[+] 0/0/0 OpenSSL HMAC tests passed/failed/executed
[+] 4/0/4 test buckets passed/failed/executed
2014-04-26 23:04:44 -04:00
Michael Rash c75cbdddef [test suite] add compounded tests for fko-wrapper 2014-04-10 23:08:51 -04:00
Michael Rash 6875d0092c [test suite] exercise fko_base64_encode() and fko_base64_decode() in fko-wrapper 2014-03-18 20:37:47 -04:00
Michael Rash 34a3808b99 [test suite] minor display_ctx() call position update 2014-01-01 19:45:02 -05:00
Michael Rash f5fd8de482 [test suite] better loop output for fko-wrapper 2014-01-01 14:07:39 -05:00
Michael Rash 227d0ab947 [libfko] ensure NULL is handled properly for all fko_get_* functions 2013-12-31 23:27:05 -05:00
Michael Rash 7aa6d37fff [libfko] added NULL check for fko_set_spa_data() data arg 2013-12-30 21:56:08 -05:00
Michael Rash 297d7d00fe [libfko] enc key NULL checks with fko-wrapper test support 2013-12-29 22:44:16 -05:00
Michael Rash 0c6911941b [libfko] reject negative length values
Integer lengths that are negative are never valid.  This commit also
extends the fuzzing capabilities of the test/fko-wrapper code to
validate libfko calls with negative length arguments, and one crash
scenario with a negative length for the encryption key was found (and
fixed) this way.
2013-12-29 21:05:04 -05:00
Michael Rash 283c72e463 [test suite] run fko-wrapper without valgrind, closes #113 2013-12-29 19:59:16 -05:00
Michael Rash 8a7ca121e9 [test suite] use ctx_update() where possible for fko-wrapper 2013-12-28 15:22:01 -05:00
Michael Rash bf9fa57ca8 [test suite] added 'getset' versions of fko_ int/short wrapper functions 2013-12-28 14:56:35 -05:00
Michael Rash 8f3ea42b3f [test suite] update fko-wrapper to use constants from fko.h 2013-12-28 14:20:11 -05:00
Michael Rash 4c42d5575e [test suite] added ctx_update() function to fko-wrapper test 2013-12-28 14:10:47 -05:00
Michael Rash 05eb4ebb7b [test suite] call FKO functions via function pointers (interim commit) 2013-12-27 23:24:05 -05:00
Michael Rash cd15502bf1 [test suite] minor addition to fko-wrapper to call fko_errstr() across valid and invalid values 2013-11-16 20:36:39 -05:00
Michael Rash 2f0ad7c4be [test suite] have fko_wrapper only require fko.h 2013-07-31 13:57:49 -04:00
Michael Rash 69ba2d7a06 fko-wrapper update to print fko_errstr() text, and to have one successful HMAC cycle 2013-06-03 20:54:40 -04:00
Michael Rash 838782f198 [test suite] added fko_destroy() calls to fko-wrapper 2013-05-12 20:57:19 -04:00