PF, The OpenBSD Packet Filter: Building The Network You Need: BSDCan, Ottawa, June 10th 2015 | ||
---|---|---|
Prev | Next |
In the base system, load the daemon if you need it
/etc/rc.conf[.local]
ftpproxy_flags=""
/etc/pf.conf
NAT section anchors
nat-anchor "ftp-proxy/*" rdr-anchor "ftp-proxy/*"
the redirection
rdr pass on $int_if proto tcp from any to any \ port ftp -> 127.0.0.1 port 8021 anchor "ftp-proxy/*"
pass out proto tcp from $proxy to any port 21 keep state