Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f8e9881c authored by Eric Dumazet's avatar Eric Dumazet Committed by David S. Miller
Browse files

bridge: reset IPCB in br_parse_ip_options



Commit 462fb2af (bridge : Sanitize skb before it enters the IP
stack), missed one IPCB init before calling ip_options_compile()

Thanks to Scot Doyle for his tests and bug reports.

Reported-by: default avatarScot Doyle <lkml@scotdoyle.com>
Signed-off-by: default avatarEric Dumazet <eric.dumazet@gmail.com>
Cc: Hiroaki SHIMODA <shimoda.hiroaki@gmail.com>
Acked-by: default avatarBandan Das <bandan.das@stratus.com>
Acked-by: default avatarStephen Hemminger <shemminger@vyatta.com>
Cc: Jan Lübbe <jluebbe@debian.org>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent aa867359
Loading
Loading
Loading
Loading
+2 −4
Original line number Diff line number Diff line
@@ -249,11 +249,9 @@ static int br_parse_ip_options(struct sk_buff *skb)
		goto drop;
	}

	/* Zero out the CB buffer if no options present */
	if (iph->ihl == 5) {
	memset(IPCB(skb), 0, sizeof(struct inet_skb_parm));
	if (iph->ihl == 5)
		return 0;
	}

	opt->optlen = iph->ihl*4 - sizeof(struct iphdr);
	if (ip_options_compile(dev_net(dev), opt, skb))