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: <1291056363.3435.1338.camel@edumazet-laptop>
Date:	Mon, 29 Nov 2010 19:46:03 +0100
From:	Eric Dumazet <eric.dumazet@...il.com>
To:	John Haxby <john.haxby@...cle.com>
Cc:	NetDev <netdev@...r.kernel.org>,
	Stephen Hemminger <shemminger@...tta.com>
Subject: Re: inet_hash_connect: source port allocation

Le lundi 29 novembre 2010 à 18:29 +0000, John Haxby a écrit :

> Sorry,  I think I phrased my question badly.
> 
> inet_csk_get_port() starts its search for a free port with
> 
>      smallest_rover = rover = net_random() % remaining + low;
> 
> whereas __inet_hash_connect() basically misses out that call to 
> net_random() so you get a predictable port number.
> 
> Is there any good reason why that is the case?
> 

It seems random select was done at bind() time only in commit
6df716340da3a6f ([TCP/DCCP]: Randomize port selection)

It probably should be done in autobind too.



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