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-next>] [day] [month] [year] [list]
Date:	Thu, 06 Mar 2014 17:38:21 +0100
From:	Heiner Kallweit <heiner.kallweit@....de>
To:	netdev@...r.kernel.org
Subject: Bug 71591 - Temporary address re-generated when it should not (public
 address about to expire)

Recently I faced the issue that a public address was about to expire and 
3s before expiry a new temporary address was generated which instantly 
went into deprecated state.
This didn't do any harm however it's wrong IMHO. Problem seems to be in 
function ipv6_create_tempaddr in addrconf.c.
A new temporary address is generated if this condition is met: 
tmp_prefered_lft > regen_advance
tmp_prefered_lft however is an offset from tstamp, not from now.
This condition only checks that the new address is preferred until more 
than regen_advance from tstamp,
but it should check that the new address is preferred until more than 
regen_advance from now.

I submitted this issue to kernel bugzilla -> 71591
Hannes asked me to propose a patch, here it comes.

Rgds, Heiner

diff -uNr linux-3.10.32.vanilla/net/ipv6/addrconf.c 
linux-3.10.32.patched/net/ipv6/addrconf.c
--- linux-3.10.32.vanilla/net/ipv6/addrconf.c    2014-02-22 
14:41:54.000000000 -0600
+++ linux-3.10.32.patched/net/ipv6/addrconf.c    2014-03-06 
17:07:12.953699438 -0600
@@ -1111,8 +1111,9 @@
       * Lifetime is greater than REGEN_ADVANCE time units.  In particular,
       * an implementation must not create a temporary address with a zero
       * Preferred Lifetime.
+     * Note that tmp_prefered_lft is relative to ifp->tstamp not now.
       */
-    if (tmp_prefered_lft <= regen_advance) {
+    if (tmp_prefered_lft <= regen_advance + age) {
          in6_ifa_put(ifp);
          in6_dev_put(idev);
          ret = -1;

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