Commit Graph

111 Commits

Author SHA1 Message Date
Michael Rash
8c3a67377e [test suite] bug fix to ensure binary existence check in build security tests 2012-10-30 21:23:30 -04:00
Michael Rash
aa74fa3eed minor fuzzing README update 2012-10-28 23:31:09 -04:00
Michael Rash
cefac6275b added non digit rand val fuzzing encoding tests 2012-10-27 22:45:28 -04:00
Michael Rash
dced7c6a77 added fuzzing encoding strip eq return packets 2012-10-27 22:34:52 -04:00
Michael Rash
4b25e1e242 added encoding_append_b64_modified_byte equals sign fuzzing encoding tests 2012-10-27 22:28:33 -04:00
Michael Rash
807dd315e5 added encoding_append_b64_modified_byte fuzzing encoding tests 2012-10-27 22:07:40 -04:00
Michael Rash
03255a5547 added non-base64 char to access msg for fuzzing encoding tests 2012-10-26 23:13:41 -04:00
Michael Rash
f3c9f49a67 added fuzzing encoding packets (extra colon 3) 2012-10-26 23:07:35 -04:00
Michael Rash
e89338c431 added fuzzing encoding packets (extra colon 2) 2012-10-26 23:06:09 -04:00
Michael Rash
69ed7ee635 added fuzzing encoding packets (extra colon 1) 2012-10-26 21:47:08 -04:00
Michael Rash
830996b3ac added non-base64 encoding fuzzing packets 2012-10-26 15:52:09 -04:00
Michael Rash
60083cc272 added rm colon5 fuzzing packets 2012-10-25 22:12:47 -04:00
Michael Rash
3ae583813c added fuzzing encoding test that removes colon #5 2012-10-25 22:04:09 -04:00
Michael Rash
91596f4450 added fuzzing encoding test that removes colon #4 2012-10-25 22:01:12 -04:00
Michael Rash
ef635d57e3 added test/fuzzing/patches/encoding_rm_colon1.patch file 2012-10-25 21:57:40 -04:00
Michael Rash
165e618bad Added fuzzing encoding tests that remove the 2nd and 3rd colons 2012-10-25 21:55:01 -04:00
Michael Rash
f6b0d23c1c Added fuzzing spa packet generation for invalid encodings
This commit adds the ability to generate SPA packets that are valid except for
the last encoding step before encryption.  This is independent of supplying
invalid data for SPA packet fields.  To invoke the test suite in this mode,
do something like:

 # ./test-fwknop.pl --enable-perl-module-pkt-gen  --fuzzing-test-tag "encoded_colon1_missing"  --fuzzing-class encoding

This assumes that lib/fko_encode.c has been patched to subvert the encoding
step itself before encryption.  In this case, the first colon after the random
value is removed.
2012-10-25 21:37:52 -04:00
Michael Rash
b3889289b3 added non-base64 user character fuzzing SPA packets 2012-10-25 00:42:02 -04:00
Michael Rash
d16643affa added extra_timestamp_digit fuzzing SPA packets 2012-10-25 00:29:01 -04:00
Michael Rash
e8312c26b9 added colon_1_to_a fuzzing SPA packets 2012-10-25 00:24:19 -04:00
Michael Rash
de512e7d8f added fuzzing/README file 2012-10-25 00:20:55 -04:00
Michael Rash
6a649e26e7 easier SPA fuzzing packet generation and importing 2012-10-25 00:20:08 -04:00
Michael Rash
691d9503ee added test/fuzzing/ directory for fuzzing data and patches 2012-10-19 22:14:24 -04:00
Michael Rash
54297086ba fixed --enable-recompile argument for OpenBSD 2012-10-18 23:10:02 -04:00
Michael Rash
3eaa7dcb5f added libfko validate_username() for decrypted SPA data 2012-10-18 23:01:54 -04:00
Michael Rash
692e336880 added 'Rejected' messages to test output for bogus SPA packet perl FKO tests 2012-10-18 22:24:48 -04:00
Michael Rash
d5c3fc4b1c removed non-SPA packet lines 2012-10-18 22:24:11 -04:00
Michael Rash
cc58adc7fc added bogus_spa_packets file for perl FKO fuzzing tests 2012-10-18 22:08:38 -04:00
Michael Rash
b218977c61 continued validation code driven by perl FKO module 2012-10-16 21:23:43 -04:00
Michael Rash
e0d86f9a33 [libfko] validation of NAT access strings
Added validation of NAT access strings in the various NAT modes in libfko.
This applies to both the client and server, and test suite support was added
as well.
2012-10-15 20:52:23 -04:00
Michael Rash
bf22778ada added perl FKO module client timeout test 2012-10-13 14:08:38 -04:00
Michael Rash
1910cd1ecf additional perl FKO module access message test strings 2012-10-13 11:38:23 -04:00
Michael Rash
e24cfd014d added perl FKO module cmd mode tests 2012-10-13 11:31:31 -04:00
Michael Rash
5112704ed9 started on fuzzing tests with the perl FKO module 2012-10-12 23:52:14 -04:00
Michael Rash
e4751d1c20 added icmp type/code blurb 2012-10-11 23:40:04 -04:00
Michael Rash
67f5d1f1e9 Applied perl FKO module libfko path patch from Franck Joncourt
Applied patch from Franck Joncourt to have the perl FKO module link
against libfko in the local directory (if it exists) so that it doesn't
have to have libfko completely installed in /usr/lib/.  This allows the
test suite to run FKO tests without installing libfko.

Added the ability to the test suite to compile, install, and run some
basic tests against the perl FKO module.
2012-10-11 23:36:50 -04:00
Michael Rash
66741b3d81 Added a test for SPA over TCP 2012-10-04 21:05:55 -04:00
Michael Rash
229a36625b Better IP spoofing support (udpraw and icmp)
- [client] Added '-P udpraw' to allow the client to send SPA packets over
  UDP with a spoofed source IP address.  This is in addition to the
  original 'tcpraw' and 'icmp' protocols that also support a spoofed
  source IP.
- [server] Bug fix to accept SPA packets over ICMP if the fwknop client
  is executed with '-P icmp' and the user has the required privileges.
2012-10-03 22:56:10 -04:00
Michael Rash
1828f51b90 [server] GPG_ALLOW_NO_PW + no KEY bug fix
Bug fix to allow GPG_ALLOW_NO_PW to result in not also having to specify a
Rijndael key.
2012-10-02 23:20:47 -04:00
Michael Rash
61021e0f23 minor print status update in --Anonymize mode 2012-09-24 22:15:01 -04:00
Michael Rash
f8374c8aef [server] (Vlad Glagolev) Submitted a patch to fix command exec mode
(Vlad Glagolev) Submitted a patch to fix command exec mode
under SPA message type validity test.  Support for command exec mode was
also added to the test suite.
2012-09-11 21:54:26 -04:00
Michael Rash
e2c0ac4821 [server] Strong access.conf validation
Fernando Arnaboldi from IOActive found several conditions in
which the server did not properly throw out maliciously constructed
variables in the access.conf file.  This has been fixed along with new
fuzzing tests in the test suite.
2012-09-03 00:21:46 -04:00
Michael Rash
263fa01f2a added inet_aton() call for IP strong IP validation (credit: Fernando Arnaboldi) 2012-09-03 00:21:32 -04:00
Michael Rash
ffe4d3b162 minor spacing update to make merges into hmac_master easier 2012-09-02 15:53:54 -04:00
Michael Rash
4832312e6d added filesystem permissions test 2012-08-29 23:12:56 -04:00
Michael Rash
a60f05ad44 file permissions and client buffer overflow fix
- [client+server] Fernando Arnaboldi from IOActive found that strict
filesystem permissions for various fwknop files are not verified.  Added
warnings whenever permissions are not strict enough, and ensured that
files created by the fwknop client and server are only set to user
read/write.
- [client] Fernando Arnaboldi from IOActive found a local buffer overflow
in --last processing with a maliciously constructed ~/.fwknop.run file.
This has been fixed with proper validation of .fwknop.run arguments.
2012-08-29 22:21:43 -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
760162a40a ipfw active/expire test bug fix (atoi() for config vars) 2012-08-16 22:30:09 -04:00