freebsd-skq/sbin
Hiroki Sato e7fa8d0ada - Accept Router Advertisement messages even when net.inet6.ip6.forwarding=1.
- A new per-interface knob IFF_ND6_NO_RADR and sysctl IPV6CTL_NO_RADR.
  This controls if accepting a route in an RA message as the default route.
  The default value for each interface can be set by net.inet6.ip6.no_radr.
  The system wide default value is 0.

- A new sysctl: net.inet6.ip6.norbit_raif.  This controls if setting R-bit in
  NA on RA accepting interfaces.  The default is 0 (R-bit is set based on
  net.inet6.ip6.forwarding).

Background:

 IPv6 host/router model suggests a router sends an RA and a host accepts it for
 router discovery.  Because of that, KAME implementation does not allow
 accepting RAs when net.inet6.ip6.forwarding=1.  Accepting RAs on a router can
 make the routing table confused since it can change the default router
 unintentionally.

 However, in practice there are cases where we cannot distinguish a host from
 a router clearly.  For example, a customer edge router often works as a host
 against the ISP, and as a router against the LAN at the same time.  Another
 example is a complex network configurations like an L2TP tunnel for IPv6
 connection to Internet over an Ethernet link with another native IPv6 subnet.
 In this case, the physical interface for the native IPv6 subnet works as a
 host, and the pseudo-interface for L2TP works as the default IP forwarding
 route.

Problem:

 Disabling processing RA messages when net.inet6.ip6.forwarding=1 and
 accepting them when net.inet6.ip6.forward=0 cause the following practical
 issues:

 - A router cannot perform SLAAC.  It becomes a problem if a box has
   multiple interfaces and you want to use SLAAC on some of them, for
   example.  A customer edge router for IPv6 Internet access service
   using an IPv6-over-IPv6 tunnel sometimes needs SLAAC on the
   physical interface for administration purpose; updating firmware
   and so on (link-local addresses can be used there, but GUAs by
   SLAAC are often used for scalability).

 - When a host has multiple IPv6 interfaces and it receives multiple RAs on
   them, controlling the default route is difficult.  Router preferences
   defined in RFC 4191 works only when the routers on the links are
   under your control.

Details of Implementation Changes:

 Router Advertisement messages will be accepted even when
 net.inet6.ip6.forwarding=1.  More precisely, the conditions are as
 follow:

 (ACCEPT_RTADV && !NO_RADR && !ip6.forwarding)
	=> Normal RA processing on that interface. (as IPv6 host)

 (ACCEPT_RTADV && (NO_RADR || ip6.forwarding))
	=> Accept RA but add the router to the defroute list with
	   rtlifetime=0 unconditionally.  This effectively prevents
	   from setting the received router address as the box's
	   default route.

 (!ACCEPT_RTADV)
	=> No RA processing on that interface.

 ACCEPT_RTADV and NO_RADR are per-interface knob.  In short, all interface
 are classified as "RA-accepting" or not.  An RA-accepting interface always
 processes RA messages regardless of ip6.forwarding.  The difference caused by
 NO_RADR or ip6.forwarding is whether the RA source address is considered as
 the default router or not.

 R-bit in NA on the RA accepting interfaces is set based on
 net.inet6.ip6.forwarding.  While RFC 6204 W-1 rule (for CPE case) suggests
 a router should disable the R-bit completely even when the box has
 net.inet6.ip6.forwarding=1, I believe there is no technical reason with
 doing so.  This behavior can be set by a new sysctl net.inet6.ip6.norbit_raif
 (the default is 0).

Usage:

 # ifconfig fxp0 inet6 accept_rtadv
	=> accept RA on fxp0
 # ifconfig fxp0 inet6 accept_rtadv no_radr
	=> accept RA on fxp0 but ignore default route information in it.
 # sysctl net.inet6.ip6.norbit_no_radr=1
	=> R-bit in NAs on RA accepting interfaces will always be set to 0.
2011-06-06 02:14:23 +00:00
..
adjkerntz
atacontrol Re-encode files from ISO-8859-1 to UTF-8 2011-05-22 14:03:30 +00:00
atm
badsect
bsdlabel Widen fields that display partition offset/length. 2011-03-10 08:24:33 +00:00
camcontrol When calling XPT_REL_SIMQ to ajust number of openings, do not try to really 2011-04-20 14:16:22 +00:00
ccdconfig mdoc: drop redundant .Pp and .LP calls 2010-10-08 12:40:16 +00:00
clri
comcontrol
conscontrol Changed "conscontrol unset" to accept an existing virtual 2011-04-18 20:28:07 +00:00
ddb Plug an fd leak 2010-11-22 07:00:47 +00:00
devd Typo. For USB devices, 'serial' should be 'sernum'. 2011-05-10 02:34:11 +00:00
devfs
dhclient Use resolvconf(8) to update /etc/resolv.conf. 2011-03-18 12:23:20 +00:00
dmesg
dump The dump, fsck_ffs, fsdb, fsirand, newfs, makefs, and quot utilities 2011-01-24 06:17:05 +00:00
dumpfs We now have multiple filesystems (UFS, ZFS, ...), so for tools that only 2011-05-08 12:34:31 +00:00
dumpon
fdisk Supply maximum value as an argument to the decimal() function 2011-01-25 04:35:07 +00:00
fdisk_pc98
ffsinfo
fsck
fsck_ffs Add an -E option to mirror newfs's. The idea is that if you have a system 2011-04-29 23:00:23 +00:00
fsck_msdosfs
fsdb The dump, fsck_ffs, fsdb, fsirand, newfs, makefs, and quot utilities 2011-01-24 06:17:05 +00:00
fsirand The dump, fsck_ffs, fsdb, fsirand, newfs, makefs, and quot utilities 2011-01-24 06:17:05 +00:00
gbde
geom Generally clean up markup. 2011-06-03 10:39:36 +00:00
ggate Because ggatel(8) operates on local GEOM providers, use unlimited queue size in 2011-04-02 06:59:05 +00:00
growfs We now have multiple filesystems (UFS, ZFS, ...), so for tools that only 2011-05-08 12:34:31 +00:00
gvinum * Add the readline(3) API to libedit. The libedit versions of 2011-04-05 18:41:01 +00:00
hastctl Keep statistics on number of BIO_READ, BIO_WRITE, BIO_DELETE and BIO_FLUSH 2011-05-23 21:15:19 +00:00
hastd Read from the socket using the same max buffer size as we use while 2011-06-04 16:01:30 +00:00
ifconfig - Accept Router Advertisement messages even when net.inet6.ip6.forwarding=1. 2011-06-06 02:14:23 +00:00
init init(8): Document that login(1) is now responsible for recording logouts. 2011-01-23 14:54:45 +00:00
ipf
ipfw Add tablearg support for ipfw setfib. 2011-05-30 05:37:26 +00:00
iscontrol Fix compilation with debug on. 2011-01-25 22:25:16 +00:00
kldconfig
kldload
kldstat In printfile(), exit the process instead of only printing the warning. 2010-11-13 16:49:07 +00:00
kldunload
ldconfig
mca
md5
mdconfig Somewhere around the 473rd time I mistyped "mdconfig file" instead of 2011-04-29 22:40:11 +00:00
mdmfs
mknod Fix some more warnings found by clang. 2010-11-22 20:10:48 +00:00
mksnap_ffs Note that a UFS filesystem can have up to 20 active snapshots. 2011-02-15 07:25:54 +00:00
mount Another man page update related to the switchover of the 2011-04-29 01:14:12 +00:00
mount_cd9660
mount_ext2fs
mount_hpfs
mount_msdosfs
mount_nfs Implemented a mount option "nocto" that disables cache coherency 2011-05-04 13:27:45 +00:00
mount_ntfs
mount_nullfs
mount_reiserfs Re-encode files from ISO-8859-1 to UTF-8 2011-05-22 14:03:30 +00:00
mount_std
mount_udf
mount_unionfs Fix SYNOPSIS. 2011-03-23 13:44:09 +00:00
natd Furthermore condition IP waiting behaviour also on -dynamic flag. 2011-04-18 23:45:50 +00:00
newfs Update the manual page to reflect the new 32K/4K defaults. 2011-05-28 15:14:50 +00:00
newfs_msdos
nfsiod
nos-tun
pfctl
pflogd Append to CFLAGS, don't clobber it. 2010-11-05 11:31:39 +00:00
ping
ping6 Add __unused. Ansi prototypes. 2010-12-19 13:40:38 +00:00
quotacheck
rcorder
reboot Remove vestiges of disklabel(5). 2011-04-14 08:53:04 +00:00
recoverdisk recoverdisk(8): treat output file consistently and abort on EINVAL 2011-05-01 20:14:10 +00:00
resolvconf Add resolvconf(8) which manages resolv.conf. 2011-03-18 12:18:52 +00:00
restore mdoc: make pages render with mandoc 2010-10-21 12:27:13 +00:00
route - Fix array bounds checking. [1] 2010-12-08 15:12:37 +00:00
routed Fix use of AND operator: should be bitwise instead of logical. 2010-11-22 19:40:27 +00:00
rtsol
savecore Remove the advertising clause from UCB copyrighted files in sbin. This 2010-12-12 21:26:12 +00:00
sconfig
setkey mdoc: fix markup 2011-06-02 09:56:42 +00:00
shutdown For compatibility with Linux and Solaris add poweroff(8). 2010-12-30 18:06:31 +00:00
spppcontrol
sunlabel mdoc: drop even more redundant .Pp calls 2010-10-19 12:35:40 +00:00
swapon
sysctl Introduce signed and unsigned version of CTLTYPE_QUAD, renaming 2011-01-19 23:00:25 +00:00
tunefs We now have multiple filesystems (UFS, ZFS, ...), so for tools that only 2011-05-08 12:34:31 +00:00
umount Add a sentence to the umount.8 man page to clarify the behaviour 2011-05-31 18:27:18 +00:00
Makefile Add resolvconf(8) which manages resolv.conf. 2011-03-18 12:18:52 +00:00
Makefile.amd64
Makefile.arm
Makefile.i386
Makefile.ia64
Makefile.inc
Makefile.mips
Makefile.pc98
Makefile.sparc64