Below are rules for allowing passive FTP that are not working.
/proc/sys/net/netfilter/nf_conntrack_helper is set to 1
The nf_conntrack_ftp module is loaded.
What could be blocking it? Do I really need the counter? Do I really need the tcp dport 1024-65535 line if I already am allowing established related connections with the ct state established,related accept line?
table inet myhelpers {
ct helper ftp-standard {
type "ftp" protocol tcp
}
chain input {
type filter hook prerouting priority 0;
tcp dport 21 ct helper set "ftp-standard"
}
}
table inet filter {
chain input {
type filter hook input priority 0; policy drop;
ct state established,related accept
# passive FTP
tcp dport 21 ct state established,new counter accept
tcp dport 20 ct state established,related counter accept
tcp dport 1024-65535 ct state established,related counter accept
}
}