Subject: CVS commit: src/sys/netinet
To: None <>
From: Jonathan Stone <>
List: source-changes
Date: 11/19/2003 18:39:34
Module Name:	src
Committed By:	jonathan
Date:		Wed Nov 19 18:39:34 UTC 2003

Modified Files:
	src/sys/netinet: in.h ip_id.c ip_input.c ip_mroute.c ip_output.c

Log Message:
Patch back support for (badly) randomized IP ids, by request:

* Include "opt_inet.h" everywhere IP-ids are generated with ip_newid(),
  so the RANDOM_IP_ID option is visible. Also in ip_id(), to ensure
  the prototype for ip_randomid() is made visible.

* Add new sysctl to enable randomized IP-ids, provided the kernel was
  configured with RANDOM_IP_ID. (The sysctl defaults to zero, and is
  a read-only zero if RANDOM_IP_ID is not configured).

Note that the implementation of randomized IP ids is still defective,
and should not be enabled at all (even if configured) without
very careful deliberation. Caveat emptor.

To generate a diff of this commit:
cvs rdiff -r1.63 -r1.64 src/sys/netinet/in.h
cvs rdiff -r1.2 -r1.3 src/sys/netinet/ip_id.c
cvs rdiff -r1.183 -r1.184 src/sys/netinet/ip_input.c
cvs rdiff -r1.81 -r1.82 src/sys/netinet/ip_mroute.c
cvs rdiff -r1.127 -r1.128 src/sys/netinet/ip_output.c
cvs rdiff -r1.77 -r1.78 src/sys/netinet/raw_ip.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.