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:	Thu, 11 Jul 2013 22:02:06 +0200
From:	Hannes Frederic Sowa <hannes@...essinduktion.org>
To:	David Miller <davem@...emloft.net>
Cc:	netdev@...r.kernel.org, nicolas.dichtel@...nd.com
Subject: Re: [PATCH net v2] ipv6: only static routes qualify for equal cost multipathing

On Thu, Jul 11, 2013 at 11:44:19AM -0700, David Miller wrote:
> From: Hannes Frederic Sowa <hannes@...essinduktion.org>
> Date: Thu, 11 Jul 2013 19:02:31 +0200
> 
> > +	for (rt = rt0; rt && !(rt->rt6i_flags & RTF_EXPIRES);
> > +	     rt = (struct rt6_info *)rt->dst.from);
> > +	return !(rt && (rt->rt6i_flags & RTF_EXPIRES));
> 
> Please make this logic clearer, something like:
> 
> 
> 	for (rt = rt0; rt; rt = (struct rt6_info *)rt->dst.from) {
> 		if (rt->rt6i_flags & RTF_EXPIRES)
> 			return false;
> 	}
> 	return true;

Ok, I'll revisit this. The reason for this loop (which was taken from
rt6_update_expires) is, that it was only valid to dereference dst.from if
RTF_EXPIRES was not set (before commit ecd9883 ("ipv6: fix race condition
regarding dst->expires and dst->from") dst.from and dst.expires were a
union). I tried to keep this (possible) invariant.

I'll check if this is still needed.

Greetings,

  Hannes

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