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:	Mon, 16 Mar 2015 11:29:14 -0700
From:	Eric Dumazet <eric.dumazet@...il.com>
To:	David Laight <David.Laight@...LAB.COM>
Cc:	'Ben Hutchings' <ben@...adent.org.uk>,
	Stephen Hemminger <shemming@...cade.com>,
	netdev <netdev@...r.kernel.org>
Subject: Re: [PATCH iproute2] ss: better 32bit support

On Mon, 2015-03-16 at 16:39 +0000, David Laight wrote:

> I wondered if the code should be reading the value in the host's natural
> endianness?
> Then the code might be optimisable to:
> 	return *(unsigned long long *)cookie;

This will trap on arches requesting 8 bytes alignment.

Not all linux hosts run x86

Look at rta_getattr_u64(), and you'll see that manipulating 64bit values
in netlink requires a memcpy() because we have no 64bit alignment
guarantee.

> which rather begs the question as to why cookie is uint32_t[2] instead of
> uint64_t.
> 

This question comes too late, inet_diag was added years ago,
and we must keep ABI compatibility forever.



--
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