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]
Message-Id: <20061119130248.c7e7b181.randy.dunlap@oracle.com>
Date:	Sun, 19 Nov 2006 13:02:48 -0800
From:	Randy Dunlap <randy.dunlap@...cle.com>
To:	Al Viro <viro@....linux.org.uk>
Cc:	Andi Kleen <ak@...e.de>, Jeff Mahoney <jeffm@...e.com>,
	lkml <linux-kernel@...r.kernel.org>, reiserfs-dev@...esys.com,
	sam@...nborg.org
Subject: Re: reiserfs NET=n build error

On Sun, 19 Nov 2006 20:57:11 +0000 Al Viro wrote:

> On Sun, Nov 19, 2006 at 11:04:33AM -0800, Randy Dunlap wrote:
> > Andi Kleen wrote:
> > >>>I would copy a relatively simple C implementation, like 
> > >>>arch/h8300/lib/checksum.c
> > >>As long as the h8300 version has the same output as the x86 version.
> > >
> > >The trouble is that the different architecture have different output 
> > >for csum_partial. So you already got a bug when someone wants to move
> > >file systems.
> > >
> > >-Andi
> > 
> > That argues for having only one version of it (in a lib.; my preference)
> > -or- Every module having its own local copy/version of it.  :(
> 
> Wrong.  csum_partial() result is defined modulo 0xffff and it's basically
> "whatever's convenient as intermediate for this architecture".
> 
> reiserfs use of it is just plain broken.  net/* is fine, since all
> final uses are via csum_fold() or equivalents.
> 
> Note that reiserfs use is broken in another way: it takes fixed-endian value
> and feeds it to cpu_to_le32().  IOW, even if everything had literally the
> same csum_partial(), the value it shits on disk would be endian-dependent.
> 
> As for net/*, with proper types it's pretty straightforward.  See
> davem's net-2.6.20 for that...

OK.  I guessed that there was some sanity in there somewhere (either
in the provider or consumer), but apparently there's none in either place.
:(

---
~Randy
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ