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:   Thu, 12 Jan 2017 14:14:35 +0100
From:   Arnd Bergmann <arnd@...db.de>
To:     David Howells <dhowells@...hat.com>
Cc:     linux-kernel@...r.kernel.org, ruchandani.tina@...il.com,
        linux-afs@...ts.infradead.org
Subject: Re: [PATCH 1/2] afs: Move UUID struct to linux/uuid.h

On Thursday, January 12, 2017 11:56:34 AM CET David Howells wrote:
> Move the afs_uuid struct to linux/uuid.h and rename it to uuid_v1.
> 
> Signed-off-by: David Howells <dhowells@...hat.com>
> 

Looks good to me, but I wonder if this part:

                r = call->request;
-               r->time_low                     = ntohl(b[0]);
-               r->time_mid                     = ntohl(b[1]);
-               r->time_hi_and_version          = ntohl(b[2]);
+               r->time_low                     = b[0];
+               r->time_mid                     = htons(ntohl(b[1]));
+               r->time_hi_and_version          = htons(ntohl(b[2]));
                r->clock_seq_hi_and_reserved    = ntohl(b[3]);
                r->clock_seq_low                = ntohl(b[4]);
 
should be considered a bugfix and split out into a
separate patch. From what I understand about the mess in UUID
formats, the time fields can either be big-endian (as defined)
or little-endian (for all things Microsoft), and you are changing
the representation from CPU-specific to big-endian, which makes
it different for x86 and most ARM at least.

	Arnd

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ