I have three hosts with following config:
Host A: IP:192.168.1.1/24
Host B: IP:192.168.1.2/24
Host C: IP:192.168.3.1/24
Everything happens on CentOS 6, and all interfaces are VLAN tagged (if it makes any difference here).
I am sending UDP traffic in directions B->A
and C->A
. This is pure unidirectional traffic, so havent configured any routing on Host A
Why C->A
traffic is not accepted on A side unless routing to C is configured on A. (it is visible in tcpdump level, but not received by socket)
I spend a lot of time troubleshooting. I was expecting a lot of reasons: iptables, selinux, and even rp_filter settings, but solution was so simple.
I would like to hear what is the reason of such behavior, and if there is config that is reponsible for the need of having soource route in case of UDP.