lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Sat, 10 Mar 2007 00:16:57 +0100
From:	Norbert Eicker <n.eicker@...juelich.de>
To:	Jeff Garzik <jgarzik@...ox.com>
Cc:	Linas Vepstas <linas@...tin.ibm.com>,
	Jens Osterkamp <jens@...ibm.com>,
	Kou Ishizaki <kou.ishizaki@...hiba.co.jp>,
	linuxppc-dev@...abs.org, netdev@...r.kernel.org
Subject: Re: [PATCH] spidernet: Fix problem sending IP fragments

On Friday, 9. March 2007 17:53, Jeff Garzik wrote:
> Linas Vepstas wrote:
> > Jeff,
> >
> > Please apply. The rather long patch description is from the submitter,
> > Norbert Eicker, I don't know if that's alright, or if I should ask to
> > have it trimmed.
> >
> > Thanks,
> > --linas
> >
> > From: Norbert Eicker <n.eicker@...juelich.de>
> >
> >
> > Signed-off-by: Norbert Eicker <n.eicker@...juelich.de>
> > Signed-off-by: Linas Vepstas <linas@...tin.ibm.com>
>
> are you sure it can't send out fragmented IP frames?  what's really
> going on here?

Pretty sure that fragmented IP frames are not send out. Here's a small test 
using ttcp and tcpdump reproducing the problem (I assume a MTU of 1500):

You need two node, lets call them src and dest.

On dest run 'tcpdump -nvvv host src'.

Furthermore start on dest: 'ttcp -u -r -s'
and on src: 'ttcp -u -t -s -l 1472 -n 4 dest

tcpdump will show 10 frames received from src, one of size 32 (UDP length 4), 
four of size 1500 (UDP length 1472) (the payload), five more of size 32 (UDP 
length 4). The size 32 frames are some startup/closing frames of ttcp.

Start on dest again: 'ttcp -u -r -s'
and on src: 'ttcp -u -t -s -l 1473 -n 4 dest

Now tcpdump only sees the six startup/closing frames. The payload frames 
(which are fragmented by the IP-stack) disappear somehow.

With the patch applied you see in the second case the startup/closing frames 
plus 4 pairs of frames in between. Each pair consists of one frame of size 
1500 followed by one of size 21 (with an offset of 1480), i.e. the two 
fragments of the too large UDP-datagram.

On src tcpdump will show the fragmented IP-frames in both cases (with and 
without patch applied).

> patch was corrupted anyway, and could not be applied...

Whitespace problem? Let's try again...

Signed-off-by: Norbert Eicker <n.eicker@...juelich.de>

diff --git a/drivers/net/spider_net.c b/drivers/net/spider_net.c
index 3b91af8..e3019d5 100644
--- a/drivers/net/spider_net.c
+++ b/drivers/net/spider_net.c
@@ -719,7 +719,7 @@ spider_net_prepare_tx_descr(struct spide
 			SPIDER_NET_DESCR_CARDOWNED | SPIDER_NET_DMAC_NOCS;
 	spin_unlock_irqrestore(&chain->lock, flags);
 
-	if (skb->protocol == htons(ETH_P_IP))
+	if (skb->protocol == htons(ETH_P_IP) && skb->ip_summed == CHECKSUM_PARTIAL)
 		switch (skb->nh.iph->protocol) {
 		case IPPROTO_TCP:
 			hwdescr->dmac_cmd_status |= SPIDER_NET_DMAC_TCP;
 
-- 
Fon ++49-(0)2461/61-1492
http://www.fz-juelich.de

-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ