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>] [day] [month] [year] [list]
Message-ID: <20080318124736.GC6977@ens-lyon.fr>
Date:	Tue, 18 Mar 2008 13:47:36 +0100
From:	Benoit Boissinot <benoit.boissinot@...-lyon.org>
To:	netdev@...r.kernel.org
Cc:	yoshfuji@...ux-ipv6.org
Subject: [PATCH] [IPv6] Do not update all temporary address, only the one
	with the same prefix

Only the temporary address with the same prefix should be updated

Signed-off-by: Benoit Boissinot <benoit.boissinot@...-lyon.org>

---
I was wondering why my temporary address would always become deprecated,
the reason was that my ISP is advertizing two prefixes, one is with
preferred lifetime = 0, the other isn't.
As soon as an RA came, it updated the lifetime of both adresses to 0.

The check for the prefix_len isn't necessary since it should always be 64,
maybe it could be removed, I don't know

diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c
index 101e0e7..5d0e404 100644
--- a/net/ipv6/addrconf.c
+++ b/net/ipv6/addrconf.c
@@ -1831,6 +1848,10 @@ ok:
                                 * lifetimes of an existing temporary address
                                 * when processing a Prefix Information Option.
                                 */
+                               if (ift->prefix_len != ifp->prefix_len ||
+                                   !ipv6_prefix_equal(&ift->addr, &ifp->addr, ifp->prefix_len))
+                                       continue;
+
                                spin_lock(&ift->lock);
                                flags = ift->flags;
                                if (ift->valid_lft > valid_lft &&


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