Commit Graph

27 Commits

Author SHA1 Message Date
joerg d41a00c8da Add missing dead. 2013-09-24 22:52:14 +00:00
rmind a99ac6280c npftest: add a choice of "rule" or "state" for -b option. 2013-09-24 02:44:20 +00:00
rmind a484105289 npftest: add some concurrency testing code. 2013-09-24 02:04:21 +00:00
rmind 5f3b7e2652 Update npftest.conf for the recent syntax adjustments. 2013-09-23 15:30:32 +00:00
rmind 7b5edfdc0d NPF: G/C n-code in favour of BPF byte-code. Delete lots of code, mmm! 2013-09-19 01:49:07 +00:00
rmind 4e592132ab - Convert NPF to use BPF byte-code by default. Compile BPF byte-code in
npfctl(8) and generate separate marks to describe the filter criteria.
- Rewrite 'npfctl show' functionality and fix some of the bugs.
- npftest: add a test for BPF COP.
- Bump NPF_VERSION.
2013-09-19 01:04:45 +00:00
rmind e9a253f3c1 npftest/npf_blockall_rule: set NPF_RULE_DYNAMIC flag for the test rule. 2013-02-18 23:09:20 +00:00
rmind 56910be779 - Convert NPF dynamic rule ID to just incremented 64-bit counter.
- Fix multiple bugs.  Also, update the man page.
2013-02-16 21:11:12 +00:00
rmind 90957242c6 npftest: adjust for recent change. 2013-02-11 02:52:32 +00:00
rmind 0e21825481 NPF:
- Implement dynamic NPF rules.  Controlled through npf(3) library of via
  npfctl rule command.  A rule can be removed using a unique identifier,
  returned on addition, or using a key which is SHA1 hash of the rule.
  Adjust npftest and add a regression test.
- Improvements to rule inspection mechanism.
- Initial BPF support as an alternative to n-code.
- Minor fixes; bump the version.
2013-02-09 03:35:31 +00:00
rmind 3107fd1eb5 - nbuf_ensure_contig: rework to use m_ensure_contig(9), which will not free
the mbuf chain on failure.  Fixes some corner cases.  Improve regression
  test and sprinkle some asserts.
- npf_reassembly: clear nbuf on IPv6 reassembly failure path (partial fix).
  The problem was found and fix provided by Anthony Mallet.
2013-01-20 18:45:56 +00:00
rmind 352f160615 - Rework NPF's nbuf interface: use advancing and ensuring as a main method.
Eliminate unnecessary copy and simplify.  Adapt regression tests.
- Simplify ICMP ALG a little.  While here, handle ICMP ECHO for traceroute.
- Minor fixes, misc cleanup.
2012-12-24 19:05:42 +00:00
rmind 64647e51e4 Implement NPF table listing and preservation of entries on reload.
Bump the version.
2012-10-29 02:27:11 +00:00
joerg c4eabd7bd6 More __dead 2012-09-14 15:37:03 +00:00
martin 9cf2fc91c7 Fix printf format 2012-09-12 16:26:02 +00:00
martin a76a87c096 Add two new command line options to help integration into ATF:
-L lists the available test cases, -T executes a single named test.
2012-09-12 08:47:14 +00:00
rmind b8c27e4a39 npftest:
- Do not stop running other tests, if some tests fail.
- Fix some endianness bugs in the test cases.

Tested on sparc64 by martin@, all tests pass.
2012-08-21 20:52:11 +00:00
rmind e0cfa502eb Add npf_state_setsampler() for _NPF_TESTING case. This also fixes the build. 2012-08-15 19:47:38 +00:00
rmind 68f7a7bc54 Move and rename librumpdev_npf to librumpnet_npf. 2012-08-14 22:31:43 +00:00
rmind 63f44833ba - Extend npftest: add ruleset inspection testing from the config generated
by npfctl debug functionality.  Auto-create npftest interfaces for this.
- NPF sessions: combine protocol and interface into a separate substructure,
  share between the entries and thus fix the handling of them.  Constify.
- npftest: add regression tests for NAT policies.
- npf_build_nat: simplify and fix bi-NAT regression.
- Bump yacc stack size for npfctl.
2012-08-12 03:35:13 +00:00
rmind 4ad5029440 - npf_fetch_tcpopts: fix off-by-one when validating TCP option length
against the maximum allowed.
- npf_tcp_inwindow: be more liberal with npf_fetch_tcpopts().
- Few minor improvements to npftest.
2012-07-21 17:11:01 +00:00
rmind a3b239f6f3 - Rework NPF tables and fix support for IPv6. Implement tree table type
using radix / Patricia tree.  Universal IPv4/IPv6 comparator for ptree(3)
  was contributed by Matt Thomas.
- NPF tables: update regression tests, improve npfctl(8) error messages.
- Fix few bugs when using kernel modules and handle module autounloader.
- Few other fixes and misc cleanups.
- Bump the version.
2012-07-15 00:22:58 +00:00
rmind 33b678d7e0 NPF improvements:
- Add NPF_OPCODE_PROTO to match the address and/or protocol only.
- Update parser to support arbitrary "pass proto <name/number>".
- Fix IPv6 address and protocol handling (add a regression test).
- Fix few theorethical races in session handling module.
- Misc fixes, simplifications and some clean up.
2012-07-01 23:21:06 +00:00
rmind 53e5b8cc71 NPF:
- Rename some functions for consistency and de-inline them.
- Fix few invalid asserts (add regressoin test).
- Use pserialize(9) for ALG interface.
- Minor fixes, sprinkle many comments.
2012-06-22 13:43:17 +00:00
rmind 79afee64f7 npftest: add a module for TCP state tracking and add few test cases. 2012-06-04 00:28:34 +00:00
rmind fb07f475c0 npftest: add a stream processor, which prints out the TCP state information.
A tool for debugging connection tracking from tcpdump -w captured data.
2012-05-30 21:38:03 +00:00
rmind 9ffbe6bd3d Add initial NPF regression tests integrated with RUMP framework (running the
kernel part of NPF in userland).  Other tests will be added once converted to
RUMP framework.  All tests are in the public domain.

Some Makefile fixes from christos@.
2012-04-14 21:57:29 +00:00