Subject: pf documentation?
To: None <tech-net@netbsd.org>
From: der Mouse <mouse@Rodents.Montreal.QC.CA>
List: tech-net
Date: 02/14/2006 19:41:56
I'm trying to do some stuff with pf that, among other things, involves
adding and removing rules under program control.

However, documentation seems..lacking.  (It's 3.0 I'm using.)  pf(4)
gives a list of ioctls, but the documentation on the structures they
use borders on nonexistent, and there are some important concepts that
are not described at all (such as pool addresses) and some are
described too sketchily to write code to (such as tickets).

For example, what is necessary to add a rule?  DIOCADDRULE describes a
structure but gives no indication how to determine whether "any pool
addresses are required", nor how to fill in the fields of the rule
itself (a struct that is not described in the documentation even to the
extent of listing its members - and there are a lot of them).

Am I just missing something, or do I really need to reverse-engineer
documentation from the code in pfctl and the kernel?

/~\ The ASCII				der Mouse
\ / Ribbon Campaign
 X  Against HTML	       mouse@rodents.montreal.qc.ca
/ \ Email!	     7D C8 61 52 5D E7 2D 39  4E F1 31 3E E8 B3 27 4B