Building the Network You Need with OpenBSD's PF: EuroBSDCon, St. Julian's, September 26th 2013 | ||
---|---|---|
Prev | Next |
In the base system, load the daemon if you need it
/etc/rc.conf[.local]
ftpproxy_flags=""
FreeBSD also needs
ftpproxy_enable="YES"
/etc/pf.conf
anchor "ftp-proxy/*"
the redirection
pass in quick inet proto tcp to port ftp divert-to 127.0.0.1 port 8021 pass in quick inet6 proto tcp to port ftp divert-to ::1 port 8021
Pre-OpenBSD 5.0, proxies used rdr-to:
pass in quick inet proto tcp to port ftp rdr-to 127.0.0.1 port 8021 pass in quick inet6 proto tcp to port ftp rdr-to ::1 port 8021
pass out proto tcp from $proxy to port ftp