[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20170215.121933.1895033942256273386.davem@davemloft.net>
Date: Wed, 15 Feb 2017 12:19:33 -0500 (EST)
From: David Miller <davem@...emloft.net>
To: anssi.hannula@...wise.fi
Cc: michal.simek@...inx.com, soren.brinkmann@...inx.com,
netdev@...r.kernel.org
Subject: Re: [PATCH 1/2] net: xilinx_emaclite: fix receive buffer overflow
From: Anssi Hannula <anssi.hannula@...wise.fi>
Date: Tue, 14 Feb 2017 19:11:44 +0200
> xilinx_emaclite looks at the received data to try to determine the
> Ethernet packet length but does not properly clamp it if
> proto_type == ETH_P_IP or 1500 < proto_type <= 1518, causing a buffer
> overflow and a panic via skb_panic() as the length exceeds the allocated
> skb size.
>
> Fix those cases.
>
> Also add an additional unconditional check with WARN_ON() at the end.
>
> Signed-off-by: Anssi Hannula <anssi.hannula@...wise.fi>
> Fixes: bb81b2ddfa19 ("net: add Xilinx emac lite device driver")
Applied.
Powered by blists - more mailing lists