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: <0049a78200f573d8acc64aa879d4412c.squirrel@webmail.itwm.fhg.de>
Date:	Wed, 5 Mar 2014 02:01:52 +0100
From:	"Phoebe Buckheister" <phoebe.buckheister@...m.fraunhofer.de>
To:	"David Miller" <davem@...emloft.net>
Cc:	phoebe.buckheister@...m.fraunhofer.de, netdev@...r.kernel.org,
	linux-zigbee-devel@...ts.sourceforge.net
Subject: Re: [PATCH net-next v4 1/4] ieee802154: add generic header 
 handling routines

> SUre it would, store the addresses in your internal data structures
> as a __be64 too.  That's what IPV4/IPV6 do, we store addresses and
> ports in the socket in network byte order.  Comparisons just work.

That's the thing - there are so many different byte orders floating around
at the moment. Network byte order is little endian. Hardware addresses are
big endian in the network layer and 6lowpan though, and our sockaddrs are
host byte order for some parts and big endian for others. It's a real
mess. The solution in my patch seemed the cleanest option to me.

Storing *everything* in network byte order would require a small adaption
layer at every interaction with userspace to fix byte ordering, but that's
doable. 6lowpan would have to do an extra byteswap for the address that I
currently do in the header ops.

I'll change everything that might come in contact with the network to __le
variants and add explicit swaps where required.

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