Bug 105091 - ICMP unreachable is not sent when receiving GRE packets on device that has no tunnel interface
Summary: ICMP unreachable is not sent when receiving GRE packets on device that has no...
Status: NEW
Alias: None
Product: Networking
Classification: Unclassified
Component: IPV4 (show other bugs)
Hardware: All Linux
: P1 low
Assignee: Stephen Hemminger
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-09-27 22:42 UTC by Isaac Lee
Modified: 2016-02-15 20:44 UTC (History)
2 users (show)

See Also:
Kernel Version: 4.2
Subsystem:
Regression: Yes
Bisected commit-id:


Attachments
fix patch (1.78 KB, patch)
2015-09-27 22:42 UTC, Isaac Lee
Details | Diff

Description Isaac Lee 2015-09-27 22:42:34 UTC
Created attachment 188691 [details]
fix patch

This used to work in version 3.9. In file ip_gre.c, when a GRE packet is received and tunnel lookup returned NULL (ie, no such interface), ipgre_rcv() calls icmp_send() to respond with port unreachable message.

In the latest version, gre_demux.c tries to do the same thing in gre_cisco_rcv(), but icmp_send fails because skb dst entry has been dropped (during parse_gre_header() -> iptunnel_pull_header() ->  skb_dst_drop(skb);) prior to calling icmp_send, causing icmp_send to return early due to rt is NULL.

A fix patch is attached.

Note You need to log in before you can comment on or make changes to this bug.