diff options
author | Hannes Frederic Sowa <hannes@stressinduktion.org> | 2016-01-07 14:28:39 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-01-10 17:28:24 -0500 |
commit | 787d7ac308ff2279e4b2ea393ad4d990de486ef2 (patch) | |
tree | 30370eacf684b73d796ebfa081f4be5a99f87b96 /include/net | |
parent | 07b9b37c227cb8d88d478b4a9c5634fee514ede1 (diff) | |
download | blackbird-obmc-linux-787d7ac308ff2279e4b2ea393ad4d990de486ef2.tar.gz blackbird-obmc-linux-787d7ac308ff2279e4b2ea393ad4d990de486ef2.zip |
udp: restrict offloads to one namespace
udp tunnel offloads tend to aggregate datagrams based on inner
headers. gro engine gets notified by tunnel implementations about
possible offloads. The match is solely based on the port number.
Imagine a tunnel bound to port 53, the offloading will look into all
DNS packets and tries to aggregate them based on the inner data found
within. This could lead to data corruption and malformed DNS packets.
While this patch minimizes the problem and helps an administrator to find
the issue by querying ip tunnel/fou, a better way would be to match on
the specific destination ip address so if a user space socket is bound
to the same address it will conflict.
Cc: Tom Herbert <tom@herbertland.com>
Cc: Eric Dumazet <edumazet@google.com>
Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net')
-rw-r--r-- | include/net/protocol.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/net/protocol.h b/include/net/protocol.h index d6fcc1fcdb5b..da689f5432de 100644 --- a/include/net/protocol.h +++ b/include/net/protocol.h @@ -107,7 +107,7 @@ int inet_del_offload(const struct net_offload *prot, unsigned char num); void inet_register_protosw(struct inet_protosw *p); void inet_unregister_protosw(struct inet_protosw *p); -int udp_add_offload(struct udp_offload *prot); +int udp_add_offload(struct net *net, struct udp_offload *prot); void udp_del_offload(struct udp_offload *prot); #if IS_ENABLED(CONFIG_IPV6) |