Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 13 Nov 2000 08:38:46 -0700 (MST)
From:      Charles Mott <cmott@scientech.com>
To:        Ruslan Ermilov <ru@FreeBSD.ORG>
Cc:        Archie Cobbs <archie@dellroad.org>, net@FreeBSD.ORG, Ari Suutari <ari@suutari.iki.fi>
Subject:   Re: libalias: Incremental Update of Internet Checksum
Message-ID:  <Pine.BSF.4.21.0011130824410.52006-100000@carcassonne.scientech.com>
In-Reply-To: <20001113103852.E34671@sunbay.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, 13 Nov 2000, Ruslan Ermilov wrote:
> On Mon, Nov 13, 2000 at 12:29:32AM -0700, Charles Mott wrote:
> > Ok, ok -- Ruslan is mathematically correct, but
> > the problem is really neglible, because of how checksums
> > are commonly verified.  Even if DifferentialChecksum()
> > incorrectly produces a 0xffff instead of 0x0000, this error
> > does not affect the verification sum computed by a recipient
> > machine.
> > 
> > To quote from RF 1624:
> > 
> >    If an end system verifies the checksum by including the checksum
> >    field itself in the one's complement sum and then comparing the
> >    result against -0, as recommended by RFC 1071, it does not matter if
> >    an intermediate system generated a -0 instead of +0 due to the RFC
> >    1141 property described here.
> > 
> That's true but it does not mean that there is no problem.  The checksum
> value of 0xffff is incorrect, because one's complement sum is guaranteed
> to be a non-zero if at least one item is non-zero (which is the case for
> IP header -- protocol field is non-zero).

It should be corrected.  I was just tryng to understand
why it has not caused any noticeable problem since 1996.

> 
> Actually I do not understand at all how DifferentialChecksum() works
> currently.  What mathematica it is based on?

I just worked it out myself -- I was unaware of the
+0 and -0 paradox.  Apparently, I replicated the
behavior of RFC 1141 (which is superseded by RFC
1624).

Charles Mott



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-net" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.21.0011130824410.52006-100000>