Hi,
Here's another weird one. No NAT rules that should be applied before routing are working. By looking at the iptables config, I see that there is a chain called AUTO_PRE that contains the nat rules I have specified, but in the true PREROUTING chain there is no reference to the AUTO_PRE chain.
The POSTROUTING and AUTO_POST chains are working perfectly.
The command: iptables -t nat -A PREROUTING -j AUTO_PRE
fixes everything.
Here's the output:
iptables -t nat -n -L
Chain PREROUTING (policy ACCEPT)
target prot opt source destination
Chain POSTROUTING (policy ACCEPT)
target prot opt source destination
AUTO_POST all -- 0.0.0.0/0 0.0.0.0/0
USR_POST all -- 0.0.0.0/0 0.0.0.0/0
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Chain AUTO_OUTPUT (0 references)
target prot opt source destination
DNAT tcp -- 0.0.0.0/0 24.48.144.62 tcp spts:1:65535 dpt:3389 to:192.168.128.50
DNAT tcp -- 0.0.0.0/0 24.48.144.62 tcp dpt:22 to:192.168.128.3
Chain AUTO_POST (1 references)
target prot opt source destination
MASQUERADE all -- 192.168.128.0/24 0.0.0.0/0
Chain AUTO_PRE (0 references)
target prot opt source destination
DNAT tcp -- 0.0.0.0/0 24.48.144.62 tcp spts:1:65535 dpt:3389 to:192.168.128.50
DNAT tcp -- 0.0.0.0/0 24.48.144.62 tcp dpt:22 to:192.168.128.3
REDIRECT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp spts:1:65535 dpt:110 redir ports 8110
REDIRECT tcp -- 192.168.128.0/24 0.0.0.0/0 tcp spts:1:65535 dpt:110 redir ports 8110
Chain USR_OUTPUT (0 references)
target prot opt source destination
Chain USR_POST (1 references)
target prot opt source destination
Chain USR_PRE (0 references)
target prot opt source destination