Simplest Possible PF Setup on FreeBSD

Good code travels well, and FreeBSD users will tell you that good code from elsewhere tends to find its way into FreeBSD sooner or later. PF is no exception, and from FreeBSD 5.2.1 and the late 4.x series onward, PF and related tools made their way into FreeBSD.

On FreeBSD, it seems that you need a little more magic in your /etc/rc.conf file, but it's still a simple set of commands. There are some differences between the FreeBSD 4.x and 5.x and newer releases with respect to PF. Refer to the FreeBSD Handbook, specifically the PF chapter at http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/firewalls-pf.html, to see which information applies in your case. The PF code in FreeBSD 7.0 is equivalent to the ...

Get The Book of PF now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.