All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net-next] ipv6: do not set "u" bit for temporary addresses
@ 2014-02-12 11:08 Florent Fourcot
  2014-02-13  0:11 ` Hannes Frederic Sowa
  2014-02-13 23:22 ` David Miller
  0 siblings, 2 replies; 4+ messages in thread
From: Florent Fourcot @ 2014-02-12 11:08 UTC (permalink / raw)
  To: netdev; +Cc: Florent Fourcot

The bit 6 of interface identifier was before the "universal/local bit",
indicating local significance only. This rule is now obsoleted by the
RFC 7136, removing all significance of bits in interface identifier.

The new rule is "In all cases, the bits in an IID have no generic
semantics; in other words, they have opaque values.", so we can remove
the setting of bit 6, it will improve the entropy of random addresses.

Signed-off-by: Florent Fourcot <florent.fourcot@enst-bretagne.fr>
---
 net/ipv6/addrconf.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c
index ad23569..0b2a18e 100644
--- a/net/ipv6/addrconf.c
+++ b/net/ipv6/addrconf.c
@@ -1878,7 +1878,6 @@ static void __ipv6_regen_rndid(struct inet6_dev *idev)
 {
 regen:
 	get_random_bytes(idev->rndid, sizeof(idev->rndid));
-	idev->rndid[0] &= ~0x02;
 
 	/*
 	 * <draft-ietf-ipngwg-temp-addresses-v2-00.txt>:
-- 
1.8.5.3

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH net-next] ipv6: do not set "u" bit for temporary addresses
  2014-02-12 11:08 [PATCH net-next] ipv6: do not set "u" bit for temporary addresses Florent Fourcot
@ 2014-02-13  0:11 ` Hannes Frederic Sowa
  2014-02-13 23:22 ` David Miller
  1 sibling, 0 replies; 4+ messages in thread
From: Hannes Frederic Sowa @ 2014-02-13  0:11 UTC (permalink / raw)
  To: Florent Fourcot; +Cc: netdev

On Wed, Feb 12, 2014 at 12:08:06PM +0100, Florent Fourcot wrote:
> The bit 6 of interface identifier was before the "universal/local bit",
> indicating local significance only. This rule is now obsoleted by the
> RFC 7136, removing all significance of bits in interface identifier.
> 
> The new rule is "In all cases, the bits in an IID have no generic
> semantics; in other words, they have opaque values.", so we can remove
> the setting of bit 6, it will improve the entropy of random addresses.
> 
> Signed-off-by: Florent Fourcot <florent.fourcot@enst-bretagne.fr>

Hmm, the RFC only talks about new methods of IID generation. Not sure
if old software depends on that. I actually know about one commercial
available ip management system which does make use of those bits to
classify ipv6 addresses for displaying purposes (that's how I actually
learned about those bits ;) ).

Greetings,

  Hannes

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH net-next] ipv6: do not set "u" bit for temporary addresses
  2014-02-12 11:08 [PATCH net-next] ipv6: do not set "u" bit for temporary addresses Florent Fourcot
  2014-02-13  0:11 ` Hannes Frederic Sowa
@ 2014-02-13 23:22 ` David Miller
  2014-02-16 20:03   ` Florent Fourcot
  1 sibling, 1 reply; 4+ messages in thread
From: David Miller @ 2014-02-13 23:22 UTC (permalink / raw)
  To: florent.fourcot; +Cc: netdev

From: Florent Fourcot <florent.fourcot@enst-bretagne.fr>
Date: Wed, 12 Feb 2014 12:08:06 +0100

> The bit 6 of interface identifier was before the "universal/local bit",
> indicating local significance only. This rule is now obsoleted by the
> RFC 7136, removing all significance of bits in interface identifier.
> 
> The new rule is "In all cases, the bits in an IID have no generic
> semantics; in other words, they have opaque values.", so we can remove
> the setting of bit 6, it will improve the entropy of random addresses.
> 
> Signed-off-by: Florent Fourcot <florent.fourcot@enst-bretagne.fr>

I'm hesistent to apply this given the feedback you've been given.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH net-next] ipv6: do not set "u" bit for temporary addresses
  2014-02-13 23:22 ` David Miller
@ 2014-02-16 20:03   ` Florent Fourcot
  0 siblings, 0 replies; 4+ messages in thread
From: Florent Fourcot @ 2014-02-16 20:03 UTC (permalink / raw)
  To: David Miller; +Cc: netdev, Hannes Frederic Sowa


> 
> I'm hesistent to apply this given the feedback you've been given.


I understand. I will try to found more convincing references, and
re-send the patch.

Regards,

-- 
Florent.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2014-02-16 20:03 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-02-12 11:08 [PATCH net-next] ipv6: do not set "u" bit for temporary addresses Florent Fourcot
2014-02-13  0:11 ` Hannes Frederic Sowa
2014-02-13 23:22 ` David Miller
2014-02-16 20:03   ` Florent Fourcot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.