545 Commits

Author SHA1 Message Date
Michael Rash
89dfa2c1fb minor ChangeLog update for the RPM build change 2012-08-27 21:20:02 -04:00
Michael Rash
c5b229c5c8 Added $DESTDIR prefix in uninstall-local and install-exec-hook to fix RPM builds 2012-08-27 21:17:40 -04:00
Michael Rash
e8386dbe6c added encryption mode flags for each access stanza 2012-08-26 15:47:24 -04:00
Michael Rash
557cd6615b consolidatd fuzzing functions within a single 'fuzzer' function 2012-08-26 15:46:54 -04:00
Michael Rash
f4c16bc47f [server] Stronger IP validation based on a bug found by Fernando Arnaboldi from IOActive
This commit fixes a condition in which the server did not properly validate
allow IP addresses from malicious authenticated clients.  This has been fixed
with stronger allow IP validation.
2012-08-25 23:08:55 -04:00
Michael Rash
d46ba1c027 (Fernando Arnaboldi, IOActive) Found and fixed several DoS/code execution vulns for authenticated clients
- [server] Fernando Arnaboldi from IOActive found several DoS/code
execution vulnerabilities for malicious fwknop clients that manage to
get past the authentication stage (so a such a client must be in
possession of a valid access.conf encryption key).  These vulnerbilities
manifested themselves in the handling of malformed access requests, and
both the fwknopd server code along with libfko now perform stronger input
validation of access request data.  These vulnerabilities affect
pre-2.0.3 fwknop releases.
- [test suite] Added a new fuzzing capability to ensure proper server-side
input validation.  Fuzzing data is constructed with modified fwknop
client code that is designed to emulate malicious behavior.
2012-08-24 22:12:19 -04:00
Michael Rash
b0bf7f3699 minor paren's syntax bug fix 2012-08-18 16:30:34 -04:00
Michael Rash
6de386b937 updated ChangeLog.git file for the fwknop-2.0.2 release 2012-08-18 15:10:05 -04:00
Michael Rash
f7e84da340 fwknop-2.0.2 release 2012-08-18 15:03:04 -04:00
Michael Rash
38feb8d7b9 Better --resolve-url handling
Chop any trailing '/' char, be more careful about handling incoming large HTTP
responses, print the HTTP request and response in --verbose --verbose mode.
2012-08-17 21:02:24 -04:00
Michael Rash
760162a40a ipfw active/expire test bug fix (atoi() for config vars) 2012-08-16 22:30:09 -04:00
Michael Rash
2c55773bdb added test/conf/ipfw_active_expire_equal_fwknopd.conf file 2012-08-16 22:19:39 -04:00
Michael Rash
3afd1aa762 [server] ipfw active/expire sets cannot be the same 2012-08-16 22:16:36 -04:00
Michael Rash
fda5759b2b todo.org notes update 2012-08-16 21:18:11 -04:00
Michael Rash
3af8e4c517 [client] Added cipherdyne.com backup check in -R mode.
Added backup check against a cipherdyne.com 'myip' cgi instance in -R mode if
the normal check against cipherdyne.org fails.
2012-08-15 22:49:29 -04:00
Michael Rash
a646a024d9 added 'Pragma: no-cache' header 2012-08-15 22:46:49 -04:00
Michael Rash
419fbafa04 added extras/myip/myip.c 2012-08-14 22:52:24 -04:00
Michael Rash
37950df66f bumped version to fwknop-2.0.2-pre3 2012-08-14 22:35:02 -04:00
Michael Rash
c272339707 todo.org notes update 2012-08-14 22:34:03 -04:00
Michael Rash
7ae45ecad1 Added GPG_ALLOW_NO_PW to the fwknopd man page 2012-08-14 22:31:03 -04:00
Michael Rash
66187a22af minor defensive fko_destroy() calls in two error condition blocks 2012-08-14 22:21:34 -04:00
Michael Rash
dfe6679c57 Added the extras/myip/ directory for client IP resolution code
The myip.c file is deployed at http://www.cipherdyne.org/cgi-bin/myip
for fwknop client IP resolution.
2012-08-14 21:51:00 -04:00
Michael Rash
385396b845 Added --enable-distcheck for 'make distcheck' verification 2012-08-13 22:53:29 -04:00
Michael Rash
863838d0ba [server] Preserve any existing config files in /etc/fwknop/
Updated the 'make install' step to not overwrite any existing config files in
/etc/fwknop/ and instead install new copies from the source tree at
/etc/fwknop/fwknopd.conf.inst and /etc/fwknop/access.conf.inst
2012-08-13 22:39:03 -04:00
Michael Rash
8fafd4b80b [server] 'make install' permissions fix
Set restrictive permissions on /etc/fwknop/ directory and /etc/fwknop/* files.
Current default permissions on /etc/fwknop/ and /etc/fwknop/* are too lax.
2012-08-12 19:57:11 -04:00
Michael Rash
543de16613 [server] iptables 'comment' match check
Implemented a new check to ensure that the iptables 'comment' match exists to
ensure the proper environment for fwknopd operations.  This check is controlled
by the new ENABLE_IPT_COMMENT_CHECK variable, and was suggested by Hank
Leininger.
2012-08-12 15:44:13 -04:00
Michael Rash
a087b11887 todo update 2012-08-12 15:23:38 -04:00
Michael Rash
a686d96d44 Added todo.org org mode file
The todo.org mode file was built with vim and the VimOrganizer project:

https://github.com/hsitz/VimOrganizer
2012-08-12 09:29:51 -04:00
Michael Rash
dc23c640bb added gpg_no_pw_access.conf file for no password gpg tests 2012-08-11 09:33:54 -04:00
Michael Rash
72229b5f46 bumped version to fwknop-2.0.2-pre2 2012-08-11 09:21:49 -04:00
Michael Rash
27ccfe35d3 [server] Added GPG_ALLOW_NO_PW variable and associated test suite support
For GPG mode, added a new access.conf variable "GPG_ALLOW_NO_PW" to make it
possible to leverage a server-side GPG key pair that has no associated
password.  This comes in handy when a system requires the user to leverage
gpg-agent / pinentry which can present a problem in automated environments as
required by the fwknopd server.  Now, it might seem like a problem to remove
the passphrase from a GPG key pair, but it's important to note that simply
doing this is little worse than storing the passphrase in the clear on disk
anyway in the access.conf file.  Further, this link help provides additional
detail:

http://www.gnupg.org/faq/GnuPG-FAQ.html#how-can-i-use-gnupg-in-an-automated-environment
2012-08-10 22:20:30 -04:00
Michael Rash
0af3bd0ee1 [server] Added FLUSH_IPFW_AT_INIT and FLUSH_IPFW_AT_EXIT
Added FLUSH_IPFW_AT_INIT and FLUSH_IPFW_AT_EXIT for ipfw firewalls to emulate
the corresponding functionality that is implemented for iptables firewalls.

Bug fix for ipfw firewalls to ensure that if the ipfw expire set is zero, then
do not disable this set whenever the FLUSH_IPFW* variables are enabled.

These changes were suggested by Jonathan Schulz.
2012-08-10 21:48:02 -04:00
Michael Rash
c6f3fde537 bug fix to implement FLUSH_IPT_AT_INIT and FLUSH_IPT_AT_EXIT functionality 2012-08-10 21:43:49 -04:00
Michael Rash
fbdae50064 added Geoff Carstairs for the FORCE_NAT idea 2012-08-08 21:27:33 -04:00
Michael Rash
fd30440128 added Aldan Beaubien for reporting the Morpheus NULL IP problem 2012-08-05 14:07:42 -04:00
Michael Rash
e70739d211 minor whitespace update 2012-08-05 13:05:55 -04:00
Michael Rash
f6ac4484c9 minor memset value update 0 -> 0x0 to conform to other memset() calls 2012-08-05 13:05:30 -04:00
Michael Rash
4cde31584f bumped version to 2.0.2-pre1 2012-08-03 22:16:22 -04:00
Michael Rash
79a947603a added changes for the 2.0.2 release (so far) 2012-08-03 22:08:14 -04:00
Michael Rash
29512bd8ec [client] -R http recv() read until close (Jonathan Schulz)
Applied patch from Jonathan Schulz to ensure that the fwknop client reads all
data from a remote webserver when resolving the client IP address in -R mode.
Jonathan indicated that some webservers would transfer HTTP headers and data
separately, and a single recv() would therefore fail to get the necessary IP
information.
2012-08-03 21:49:03 -04:00
Michael Rash
7c1db89106 minor white space fix tabs->spaces 2012-08-03 21:30:24 -04:00
Michael Rash
7061b7bd3e added Jonathan Schulz 2012-08-01 23:40:34 -04:00
Michael Rash
84e036f95b Change HTTP connection type to 'close' in -R mode
Applied patch from Jonathan Schulz to change the HTTP connection type to
'close' for the client in -R mode.
2012-08-01 23:27:34 -04:00
Michael Rash
5fd3343ca9 added client IP resolution test with complete SPA->SSH cycle 2012-08-01 22:30:02 -04:00
Michael Rash
016098a254 Replay attack bug fix (encryption prefixes)
Ensure that an attacker cannot force a replay attack by intercepting an
SPA packet and the replaying it with the base64 version of "Salted__"
(for Rindael) or the "hQ" prefix (for GnuPG).  This is an important fix.
The following comment was added into the fwknopd code:

/* Ignore any SPA packets that contain the Rijndael or GnuPG prefixes
 * since an attacker might have tacked them on to a previously seen
 * SPA packet in an attempt to get past the replay check.  And, we're
 * no worse off since a legitimate SPA packet that happens to include
 * a prefix after the outer one is stripped off won't decrypt properly
 * anyway because libfko would not add a new one.
*/

Conflicts:

	lib/cipher_funcs.h
2012-08-01 21:52:56 -04:00
Michael Rash
c0e53482fa [libfko] minor memory leak fix for user detection (corner case) 2012-07-30 22:34:15 -04:00
Michael Rash
060fbb607f [server] replay attack detection memory leak bug fix
This commit fixes the following memory leak found with valgrind:

44 bytes in 1 blocks are definitely lost in loss record 2 of 2
   at 0x482BE68: malloc (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
   by 0x490EA50: strdup (strdup.c:43)
   by 0x10CD69: incoming_spa (incoming_spa.c:162)
   by 0x10E000: process_packet (process_packet.c:200)
   by 0x4862E63: ??? (in /usr/lib/i386-linux-gnu/libpcap.so.1.1.1)
   by 0x4865667: pcap_dispatch (in /usr/lib/i386-linux-gnu/libpcap.so.1.1.1)
   by 0x10DABF: pcap_capture (pcap_capture.c:226)
   by 0x10A798: main (fwknopd.c:299)
2012-07-30 22:33:24 -04:00
Michael Rash
8e26cca9f3 removed diffstat and ShortLog from 'make dist' target 2012-07-23 22:53:38 -04:00
Michael Rash
cab2ea9083 bumped version to 2.0.1 2012-07-23 22:40:47 -04:00
Michael Rash
9fe6dc7d6f bumped version to fwknop-2.0.1 2012-07-23 21:58:14 -04:00