I'm trying to properly setup the firewall on my gateway (OpenBSD 4.7) using pf to allow amule (on to operate properly as discussed here:

Now I know pf has changed a bit from OpenBSD 4.7 to 4.9 with some of the rules being rewritten and I believe the '->' symbol is no longer used with port forwarding. So my question is:

Which rule set do I use for pf on OpenBSD 4.7 on the gateway? This:

# pass in on $int_if proto tcp from any to any port 4662 rdr-to
# pass in on $int_if proto udp from any to any port 4672 rdr-to
# pass in on $int_if proto udp from any to any port 4665 rdr-to

or this:

# rdr pass on egress proto tcp to port 4662 ->
# rdr pass on egress proto udp to port 4672 ->
# rdr pass on egress proto udp to port 4665 ->

The OBSD site has updated everything to reflect 4.9 now and no longer seems to have the old pf stuff up there.


You want the first set. Regarding the OpenBSD documentation you can consult the man page for the most accurate info, if you don't have them installed you can get them from OpenBSDs site:


They keep all versions and there is a drop down that lets you select the specific one you are using.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.