ip_tunnel: Do not use inner ip-header-id for tunnel ip-header-id.
authorPravin B Shelar <pshelar@nicira.com>
Tue, 13 Aug 2013 08:41:06 +0000 (01:41 -0700)
committerDavid S. Miller <davem@davemloft.net>
Tue, 13 Aug 2013 23:52:50 +0000 (16:52 -0700)
commit4221f40513233fa8edeef7fc82e44163fde03b9b
treeb7213a4e780c4c5b61ef4f103bcd5346c960a365
parent50f850fdf91a9ed21bfca982932520ee21a4ccb9
ip_tunnel: Do not use inner ip-header-id for tunnel ip-header-id.

Using inner-id for tunnel id is not safe in some rare cases.
E.g. packets coming from multiple sources entering same tunnel
can have same id. Therefore on tunnel packet receive we
could have packets from two different stream but with same
source and dst IP with same ip-id which could confuse ip packet
reassembly.

Following patch reverts optimization from commit
490ab08127 (IP_GRE: Fix IP-Identification.)

CC: Jarno Rajahalme <jrajahalme@nicira.com>
CC: Ansis Atteka <aatteka@nicira.com>
Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/ip_tunnels.h
net/ipv4/ip_tunnel_core.c