patch-2.3.19 linux/net/ipx/af_ipx.c
Next file: linux/net/irda/Config.in
Previous file: linux/net/ipx/Config.in
Back to the patch index
Back to the overall index
- Lines: 22
- Date:
Sat Oct 2 07:49:30 1999
- Orig file:
v2.3.18/linux/net/ipx/af_ipx.c
- Orig date:
Tue Sep 7 12:14:07 1999
diff -u --recursive --new-file v2.3.18/linux/net/ipx/af_ipx.c linux/net/ipx/af_ipx.c
@@ -744,7 +744,9 @@
if(ipx->ipx_type == IPX_TYPE_PPROP
&& ipx->ipx_tctrl < 8
- && skb->pkt_type != PACKET_OTHERHOST)
+ && skb->pkt_type != PACKET_OTHERHOST
+ /* header + 8 network numbers */
+ && ntohs(ipx->ipx_pktsize) >= sizeof(struct ipxhdr) + 8 * 4)
{
int i;
ipx_interface *ifcs;
@@ -2043,6 +2045,10 @@
/* Too small? */
if(ntohs(ipx->ipx_pktsize) < sizeof(struct ipxhdr))
+ goto drop;
+
+ /* Invalid header */
+ if(ntohs(ipx->ipx_pktsize) > skb->len)
goto drop;
/* Not ours */
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)