mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Josan Kadett" <corporate@superonline.com>
To: "'Chris Siebenmann'" <cks@utcc.utoronto.ca>
Cc: <linux-kernel@vger.kernel.org>
Subject: RE: Entirely ignoring TCP and UDP checksum in kernel level
Date: Sun, 22 Aug 2004 04:08:39 +0200	[thread overview]
Message-ID: <S264980AbUHVBIi/20040822010839Z+1297@vger.kernel.org> (raw)
In-Reply-To: <04Aug21.205911edt.41960@gpu.utcc.utoronto.ca>


Well, the device fails only in one type of operation, that is when it has to
receive packets from an internal port, it sends packets via its external IP
address. 

I have managed to disable IP header checksumming by hacking the kernel (in
file ip_input.c). Now I have to do the same for tcp_input.c and udp.c .
Packet mangling will not be required because when I turn the rp_filter off,
the kernel does not care whether it is coming from the intended source or
not.

Now after disabling IP protocol checksumming, I passed to udp checksumming.
However; now the code is more complicated. And for the TCP there is 100K of
code. Well of course, with correct patch it would work, but as far as I can
see, there are many locations that needs to be changed in order to get this
work.

I also thought about packet mangling, but again something needs to be done
for checksums. By the way, it is not necessary to do as such. Perhaps, I
would later need it in case I see such errors in future but my current
problem has a rather easy solution.

I have received many replies about what to change in these codes. However;
none of them were correct at all. Either they disabled some part of
checksumming or cast the TCP/IP totally unavailable.

Any reference to code would be appreciated.
Regards...

-----Original Message-----
From: Chris Siebenmann [mailto:cks@utcc.utoronto.ca] 
Sent: Sunday, August 22, 2004 2:59 AM
To: Josan Kadett
Subject: Re: Entirely ignoring TCP and UDP checksum in kernel level

 At least with TCP, I believe that if TCP is establishing a circuit
between (IP1, port1) and (IP2, port2), SYN+ACKs from (IP3, port2) will
generally be ignored. So it seems likely that you will not only have
to ignore the checksum failure but also mangle the IP packets that you
receive that claim to be from 'IP3' to claim to be from 'IP2' instead,
so that they match up with what the kernel expects.

 (The alternative approach is to mangle on the outgoing path, such
that the Linux box at the high level thinks it's talking to IP3, but
IP3 is replaced by IP2 as each packet goes out.)

 Has this particular chunk of hardware ever successfully talked to
anything via TCP/IP?

[And just to check: you are entirely 100% certain that the IP checksum
 on incoming packets is incorrect?]
---
	"I shall clasp my hands together and bow to the corners of the
world."
			Number Ten Ox, "Bridge of Birds"
cks@utcc.toronto.edu
utgpu!cks




       reply	other threads:[~2004-08-22  1:08 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <04Aug21.205911edt.41960@gpu.utcc.utoronto.ca>
2004-08-22  2:08 ` Josan Kadett [this message]
2004-08-22  6:01   ` Brad Campbell
2004-08-22  7:06     ` Josan Kadett
     [not found] <41285DB3.6070605@wasp.net.au>
2004-08-22 10:14 ` Josan Kadett
2004-08-22 11:48   ` James Courtier-Dutton
2004-08-22 10:25 ` Josan Kadett
2004-08-22  9:36   ` Brad Campbell
2004-08-22 10:48     ` Josan Kadett
2004-08-22 13:10       ` Brad Campbell
2004-08-22 13:13       ` Brad Campbell
2004-08-22 19:27         ` Josan Kadett
2004-08-22 20:28         ` Josan Kadett
2004-08-23  3:38           ` David Meybohm
2004-08-23  5:26             ` Josan Kadett
2004-08-23  8:40             ` Josan Kadett
2004-08-22  9:19 Brad Campbell
  -- strict thread matches above, loose matches on Subject: below --
2004-08-22  6:17 Brad Campbell
2004-08-22  7:18 ` Josan Kadett
2004-08-22  7:24 ` Josan Kadett
2004-08-22  7:04   ` Brad Campbell
2004-08-22  8:12     ` Josan Kadett
2004-08-22  8:29       ` Brad Campbell
     [not found] <1093120934.854.155.camel@krustophenia.net>
2004-08-21 20:46 ` Lee Revell
2004-08-21 21:53   ` Josan Kadett
     [not found] <4126FDD8.1090101@gmc.lt>
2004-08-21  9:00 ` Josan Kadett
2004-08-21  8:11   ` Denis Vlasenko
2004-08-21  9:18     ` Josan Kadett
2004-08-21  8:26       ` Lee Revell
2004-08-21  9:35         ` Josan Kadett
2004-08-21  9:14   ` Vojtech Pavlik
     [not found] <1093078213.854.76.camel@krustophenia.net>
2004-08-21  8:58 ` Lee Revell
2004-08-21 21:41   ` Josan Kadett
2004-08-21  8:27 Denis Vlasenko
2004-08-21  8:41 ` Lee Revell
2004-08-21  9:50   ` Josan Kadett
2004-08-21  9:06     ` Kalin KOZHUHAROV
2004-08-21 21:46       ` Josan Kadett
2004-08-21  9:39 ` Josan Kadett
     [not found] <4126F16D.1000507@gmc.lt>
2004-08-21  8:02 ` Josan Kadett
2004-08-21  7:36   ` Kalin KOZHUHAROV
2004-08-21  8:54     ` Josan Kadett
2004-08-21  6:15 Josan Kadett
2004-08-21  7:10 ` Willy Tarreau

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=S264980AbUHVBIi/20040822010839Z+1297@vger.kernel.org \
    --to=corporate@superonline.com \
    --cc=cks@utcc.utoronto.ca \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®