Commit Graph

478 Commits

Author SHA1 Message Date
Michael Rash
92e403a242 added initial HMAC-SHA256 support for the client side 2012-07-02 23:50:45 -04:00
Michael Rash
3095f0ee43 Added key generation support with --key-gen
Added --key-gen to allow KEY_BASE64 and HMAC_KEY_BASE64 keys to be created from
reading random data from /dev/random.  These keys can be placed within server
access.conf files and corresponding client .fwknoprc files for SPA
communications.  The HMAC key is not used yet with this commit, but that is
coming.
2012-06-27 23:06:17 -04:00
Michael Rash
20e3e3b6e5 added test for client --show-last functionality 2012-06-23 15:41:58 -04:00
Michael Rash
adbc6a8f39 Bug fix to not force asymmetric gpg decryption
fwknopd access stanzas can have both Rijndael and GnuPG keys, so this
commit fixes a bug where any gpg info would force only gpg decryption
attempts even if a Rijndael key is provided in the stanza.
2012-06-23 15:13:03 -04:00
Michael Rash
c6a2680be2 added test for invalid SOURCE access lines 2012-06-17 13:57:06 -04:00
Michael Rash
5f8e3f4a7d Bug fix to throw out invalid access.conf SOURCE entries
This commit causes fwknopd to exit whenever an invalid SOURCE entry is seen
such as ":ANY".  Previous to this commit, valgrind threw the following errors
with ":ANY" as an access.conf SOURCE entry:

Invalid read of size 8
   at 0x117695: free_acc_source_list (access.c:512)
   by 0x1177E3: free_acc_stanza_data (access.c:564)
   by 0x117C67: free_acc_stanzas (access.c:654)
   by 0x10E32E: free_configs (config_init.c:106)
   by 0x10D085: main (fwknopd.c:376)
 Address 0x5a80658 is 8 bytes inside a block of size 16 free'd
   at 0x4C2A82E: free (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
   by 0x116AE0: add_source_mask (access.c:255)
   by 0x116D57: expand_acc_source (access.c:303)
   by 0x117A82: expand_acc_ent_lists (access.c:620)
   by 0x119570: parse_access_file (access.c:1043)
   by 0x10C77E: main (fwknopd.c:193)

Invalid free() / delete / delete[] / realloc()
   at 0x4C2A82E: free (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
   by 0x1176A8: free_acc_source_list (access.c:514)
   by 0x1177E3: free_acc_stanza_data (access.c:564)
   by 0x117C67: free_acc_stanzas (access.c:654)
   by 0x10E32E: free_configs (config_init.c:106)
   by 0x10D085: main (fwknopd.c:376)
 Address 0x5a80650 is 0 bytes inside a block of size 16 free'd
   at 0x4C2A82E: free (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
   by 0x116AE0: add_source_mask (access.c:255)
   by 0x116D57: expand_acc_source (access.c:303)
   by 0x117A82: expand_acc_ent_lists (access.c:620)
   by 0x119570: parse_access_file (access.c:1043)
   by 0x10C77E: main (fwknopd.c:193)

HEAP SUMMARY:
    in use at exit: 8 bytes in 1 blocks
  total heap usage: 1,659 allocs, 1,659 frees, 238,310 bytes allocated
2012-06-17 13:42:23 -04:00
Michael Rash
10d380d193 Test suite support for function coverage testing via gcov
Added --enable-profile-coverage to the configure script to have the fwknop
binaries compiled with gcc profiling support in order to see which functions
get executed by the test suite via gcov.  The last test executed by the test
suite under --enable-profile-coverage contains all fwknop functions that
were not executed under the test run (function execution totals are
cumlative).
2012-06-14 20:43:57 -04:00
Michael Rash
e3761b8bff merged minor updates from master 2012-05-28 14:24:02 -04:00
Michael Rash
fcf40b5e6d gcc warning fix fox: fko_decode.c:43:17: warning: variable ‘edata_size’ set but not used [-Wunused-but-set-variable] 2012-05-28 14:22:33 -04:00
Michael Rash
8a73e6dee8 updated PF anchor check to not rely on listing the PF policy 2012-05-28 14:19:52 -04:00
Michael Rash
5c26c0abaa added Ted Wynnychenko for OpenBSD PF testing 2012-05-28 14:18:34 -04:00
Michael Rash
71690a1de4 bug fix to ensure to pick up proper entropy min/max values 2012-02-13 13:56:24 -05:00
Michael Rash
65cd9b0038 updated to local_spa.key from the test suite directory 2012-02-13 12:48:58 -05:00
Michael Rash
0c9946160c ensure CBC is the default symmetric encryption mode 2012-02-12 20:52:17 -05:00
Michael Rash
8fd83f5a3f updated docs to reference the default AES encryption mode of CBC 2012-02-10 15:59:26 -05:00
Michael Rash
de41b0a1ec bugfix to ensure that incoming SPA data in AES mode is a multiple of the Rjindael blocksize (16) 2012-02-10 15:10:19 -05:00
Michael Rash
6dbe523052 added test suite support for AES CTR, OFB, CFB, and ECB encryption modes 2012-02-10 15:09:27 -05:00
Michael Rash
6130099b75 minor header addition for spa-entropy.pl 2012-02-10 13:38:30 -05:00
Michael Rash
79a5265be0 updated to not base64 decode encrypted packet data by default (can override with --base64-decode) 2012-02-09 15:23:07 -05:00
Michael Rash
aeb96c502e added --gpg entropy measurement, added sensible gnuplot yrange calculations 2012-02-09 14:56:18 -05:00
Michael Rash
280b8c56f0 switched CBC mode test (which is the default Rjindael encryption mode) to ECB mode 2012-02-08 14:29:33 -05:00
Michael Rash
bcb0fcfc1a Re-worked encryption/decryption handling
For SPA packets encrypted with Rjindael, fwknop has always used CBC mode
even though ECB mode is mentioned in a couple of places.  This change makes
more transparent use of block_encrypt() and block_decrypt() to ensure that
the appropriate mode is used.  The default is CBC mode, but others can be
selected as well (-M <mode> for the fwknop client, and ENCRYPTION_MODE in
access.conf for the fwknopd server).
2012-02-08 14:16:42 -05:00
Michael Rash
efcefdfb81 update display_ctx() to show the entire plaintext data on one line 2012-02-08 14:15:36 -05:00
Michael Rash
193e1799e6 made default openssl encryption mode 'aes-256-ecb' 2012-02-06 15:19:03 -05:00
Michael Rash
c68358eabd added the ability to encrypt fwknop client plaintext data with openssl 2012-02-06 15:12:31 -05:00
Michael Rash
a7cb3bf62b added spa-entropy/ directory for measuring entropy across SPA packets 2012-01-29 22:07:06 -05:00
Michael Rash
53a6d72cd2 added test suite support for CBC mode Rijndael tcp/22 test 2012-01-29 17:31:12 -05:00
Michael Rash
4c3d2188a1 Update to make AES encryption modes selectable
This is a significant update to allow AES encryption modes to be selected on a
per-key basis.  For now, only ECB and CBC (recommended) modes are supported.
The default is ECB modes in order to maintain backwards compatibility with the
older perl version of fwknop and the Crypt::CBC CPAN module.  This will likely
be changed to use CBC mode by default because of its better security
properties.

In the access.conf file on the server side, there is a new configuration
variable "ENCRYPTION_MODE" that controls the mode for the corresponding AES
key.  On the client side, a new command line argument "--encryption-mode"
controls how the client encrypts SPA packets.
2012-01-24 20:26:21 -05:00
Michael Rash
7e8e48412f convert Rijndael blocksize values '16' to use RIJNDAEL_BLOCKSIZE macro 2012-01-15 15:57:45 -05:00
Michael Rash
dd188dc392 added --stat output to ChangeLog 2012-01-02 18:35:41 -05:00
Michael Rash
a36082b543 moved ChangeLog-v2.0 to ChangeLog 2012-01-02 18:33:42 -05:00
Michael Rash
36f21f95ce removed old ChangeLog files 2012-01-02 18:32:35 -05:00
Michael Rash
305708aa27 Added ChangeLog, ShortLog, and diffstat files for the 2.0 release. 2012-01-02 18:26:05 -05:00
Michael Rash
4ecbcba77c bumped version to 2.0 2012-01-02 17:47:01 -05:00
Michael Rash
9dae73d972 added FKO_CHECK_COMPILER_ARG_LDFLAGS_ONLY to fix ro-relocations and immediate binding protection compliation warnings on FreeBSD 2012-01-02 15:26:42 -05:00
Michael Rash
6f6a9d727d minor test suite update to look for linker warnings in a more generic way 2012-01-02 15:25:35 -05:00
Michael Rash
1bd2592d15 minor test suite addition to check for linker input file warnings 2012-01-02 15:10:55 -05:00
Michael Rash
a6a6a004d4 bumped version to 2.0 2012-01-02 11:29:16 -05:00
Michael Rash
ac0bf15ea7 minor wording update subversion -> git 2012-01-02 09:53:36 -05:00
Damien S. Stuart
aff8832d66 Refactored configure.ac to use a custom macro for compiler flag checks.
Set version to 2.0 (non-release candidate).
Minor typo fixes.
2011-12-29 14:20:18 -05:00
Michael Rash
99b1a48756 updated copyright and license statement - fwknop is GPL software 2011-12-12 20:41:39 -05:00
Michael Rash
7ac5319847 minor addition of the local_spa.key file for 'make dist' 2011-12-05 22:23:00 -05:00
Michael Rash
7a231a3b72 added local_spa.key file 2011-12-05 22:21:31 -05:00
Michael Rash
3d0ceccf65 added local_spa.key file 2011-12-05 22:20:39 -05:00
Michael Rash
710f98a9b5 minor addition of the CREDITS file for 'make dist' 2011-12-05 22:16:38 -05:00
Michael Rash
9bcd7cb137 Added the CREDITS file for 'make dist' 2011-12-05 22:16:03 -05:00
Michael Rash
3b2ec921be change log doc updates 2011-12-05 22:11:58 -05:00
Michael Rash
474a18b57d Added various files to Makefile.am so that 'make dist' continues to work 2011-12-05 22:10:47 -05:00
Michael Rash
690fe25fa4 added CREDITS file, bumped software version, added ChangeLog files 2011-12-05 21:14:31 -05:00
Michael Rash
bcba9d6bde added CREDITS file, bumped software version, added ChangeLog files 2011-12-05 21:14:14 -05:00