Skip to content
Commit 78382d78 authored by David Ahern's avatar David Ahern Committed by Greg Kroah-Hartman
Browse files

net/ipv4: Set oif in fib_compute_spec_dst

[ Upstream commit e7372197 ]

Xin reported that icmp replies may not use the address on the device the
echo request is received if the destination address is broadcast. Instead
a route lookup is done without considering VRF context. Fix by setting
oif in flow struct to the master device if it is enslaved. That directs
the lookup to the VRF table. If the device is not enslaved, oif is still
0 so no affect.

Fixes: cd2fbe1b

 ("net: Use VRF device index for lookups on RX")
Reported-by: default avatarXin Long <lucien.xin@gmail.com>
Signed-off-by: default avatarDavid Ahern <dsahern@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 829f4fd6
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment