The PF section of the OpenBSD Handbook provides detailed guidance on configuring and managing the Packet Filter firewall. PF controls network traffic through filtering rules, NAT, redirection, and various advanced features.
This section includes:
PFCTL Cheat Sheet A quick reference for common
pfctlcommands and options.Anchors Using anchors to modularize PF rule sets and load rules dynamically.
Filter Writing filtering rules to control inbound and outbound traffic.
Forwarding Enabling and configuring packet forwarding in PF.
Lists and Macros Grouping addresses and defining macros to simplify rule management.
Load Balancing Distributing traffic across multiple servers or network paths.
Logging Capturing and analyzing PF log data.
NAT Configuring Network Address Translation for private network access to the internet.
Options Configuring global PF options that affect rule processing and performance.
Policies Setting default rule policies for packet handling.
Shortcuts Tips and shorthand for efficient PF rule writing.
Tables Using tables to manage large sets of addresses efficiently.