RANDOM_IP_ID sysctl?
Andre Oppermann
andre at freebsd.org
Sat Jul 3 00:39:00 PDT 2004
Mike Silbersack wrote:
>
> On Tue, 29 Jun 2004, David Malone wrote:
>
> > It seems to me that RANDOM_IP_ID might be better as a sysctl rather
> > than a kernel option. Would anyone mind if I changed this?
> >
> > David.
>
> I'd rather see a sysctl that switched between incremental frag IDs and
> arc4random() based IDs, followed by the removal of RANDOM_IP_ID.
>
> For more info, see:
>
> http://cvsweb.netbsd.org/bsdweb.cgi/src/sys/netinet/ip_id.c
>
> (I think we're still using the old code that's collision prone.)
>
> Given that we're in a 16-bit space anyway, it's simpler to just use
> arc4random and stop pretending that we can avoid collisions.
>
> Remember: An IP ID collision is equivalent to a packet being lost; this
> is not a big deal.
An ip_id collision is only a problem (packet loss) if it is being
fragmented along the way and the delivery of the fragments happens
out-of-order, so that a fragment from a different packet gets re-
assembled with part of an earlier one. Having many concurrent
connections to the same remote end-point with fragmentation in between
is of course making the chances bigger to hit this.
--
Andre
More information about the freebsd-net
mailing list