142a227f8SMax Laier# $OpenBSD: pf.conf,v 1.34 2007/02/24 19:30:59 millert Exp $ 242a227f8SMax Laier# 342a227f8SMax Laier# See pf.conf(5) and /usr/share/examples/pf for syntax and examples. 4*6e9a914bSKevin Lo# Remember to set gateway_enable="YES" and/or ipv6_gateway_enable="YES" 5*6e9a914bSKevin Lo# in /etc/rc.conf if packets are to be forwarded between interfaces. 642a227f8SMax Laier 742a227f8SMax Laier#ext_if="ext0" 842a227f8SMax Laier#int_if="int0" 942a227f8SMax Laier 1042a227f8SMax Laier#table <spamd-white> persist 1142a227f8SMax Laier 1242a227f8SMax Laier#set skip on lo 1342a227f8SMax Laier 1442a227f8SMax Laier#scrub in 1542a227f8SMax Laier 1642a227f8SMax Laier#nat-anchor "ftp-proxy/*" 1742a227f8SMax Laier#rdr-anchor "ftp-proxy/*" 184ba82b17SRui Paulo#nat on $ext_if inet from !($ext_if) -> ($ext_if:0) 1942a227f8SMax Laier#rdr pass on $int_if proto tcp to port ftp -> 127.0.0.1 port 8021 2042a227f8SMax Laier#no rdr on $ext_if proto tcp from <spamd-white> to any port smtp 2142a227f8SMax Laier#rdr pass on $ext_if proto tcp from any to any port smtp \ 2242a227f8SMax Laier# -> 127.0.0.1 port spamd 2342a227f8SMax Laier 2442a227f8SMax Laier#anchor "ftp-proxy/*" 2542a227f8SMax Laier#block in 2642a227f8SMax Laier#pass out 2742a227f8SMax Laier 2842a227f8SMax Laier#pass quick on $int_if no state 2942a227f8SMax Laier#antispoof quick for { lo $int_if } 3042a227f8SMax Laier 3142a227f8SMax Laier#pass in on $ext_if proto tcp to ($ext_if) port ssh 3242a227f8SMax Laier#pass in log on $ext_if proto tcp to ($ext_if) port smtp 3342a227f8SMax Laier#pass out log on $ext_if proto tcp from ($ext_if) to port smtp 349c73eae9SRebecca Cran#pass in on $ext_if inet proto icmp from any to ($ext_if) icmp-type { unreach, redir, timex } 35