states and UDP
Am I right in thinking that the stateful capabilities of iptables (NEW/ESTABLISHED/RELATED etc) only apply to tcp connections? If not, how are these states defined for udp?
iptables doesnt complain if I add a rule containing '-p udp -m state --state NEW'
Thanks,
Terry.
Quoted 5 lines · T. Horsnell
Am I right in thinking that the stateful capabilities of iptables (NEW/ESTABLISHED/RELATED etc) only apply to tcp connections? If not, how are these states defined for udp?
Quoted 7 lines
iptables doesnt complain if I add a rule containing '-p udp -m state --state NEW'
Thanks,
Terry.
any tracked connection can have state. For instance, one could write a conneciton tracker for NFS over UDP mounts and use the state flag in firewall rules. That's not a real example (to my knowledge), I'm just showing that the capability is there.
Quoted 7 lines · T. Horsnell
Am I right in thinking that the stateful capabilities of iptables (NEW/ESTABLISHED/RELATED etc) only apply to tcp connections? If not, how are these states defined for udp?
iptables doesnt complain if I add a rule containing '-p udp -m state --state NEW'
Conntrack states are valid for all protocols. They are different from TCP states.
The man page and tutorial describe what they mean:
http://iptables-tutorial.frozentux.net/iptables-tutorial.html#USERLANDSTATES