Date: Fri, 13 Mar 2020 23:37:52 +0100 From: Jan Behrens <jbe-mlist@magnetkern.de> To: Hiroki Sato <hrs@FreeBSD.org> Cc: freebsd-net@freebsd.org Subject: Re: ifconfig prefer_source and IPv6 privacy extensions Message-ID: <20200313233752.43d6fc44f51a60acbe4a9bb8@magnetkern.de> In-Reply-To: <20200314.045143.1650553685773092770.hrs@FreeBSD.org> References: <20200313202833.cbbe8d1679ac0fd7a80788e1@magnetkern.de> <20200314.045143.1650553685773092770.hrs@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, 14 Mar 2020 04:51:43 +0900 (JST) Hiroki Sato <hrs@FreeBSD.org> wrote: > Jan Behrens <jbe-mlist@magnetkern.de> wrote > in <20200313202833.cbbe8d1679ac0fd7a80788e1@magnetkern.de>: > > jb> Is it intended that "net.inet6.ip6.prefer_tempaddr" takes precedence > jb> over "prefer_source"? If yes, why? > > Yes, and the reason is that RFC 6724 specifies that behavior. I'm afraid my knowledge on IPv6 is not good enough yet to fully understand the RFC. Would "net.inet6.ip6.prefer_tempaddr" correspond to Rule 7 and "prefer_source" correspond to Rule 8 (that "MAY be superseded if the implementation has other means of choosing among source addresses")? > Why do you want to use fd<prefix>::2 over fd<prefix>:<random> as the > default source address? I want to use fd<prefix>::2 as the preferred address in order to always appear as fd<prefix>::2 in my local network even if I change my network card. That address won't be used when I access the internet, even if it is preferred (see below). > If prefer_source takes precedence, the tempaddr will nerver be used. That depends on how "prefer_source" competes with other rules for source address selection. Even with current FreeBSD's behavior, if I disable privacy extensions, then for reaching hosts in the internet, 2003:<prefix>:<modified EUI-64> is used, and only for connections to my LAN, fd<prefix>::2 (the address with "prefer_source") is used, i.e. the address with "prefer_source" set is NOT always used. Moreover, preferring temporary addresses over addresses marked with "prefer_source" doesn't seem to make much sense (even if the RFC would demand it). This is because it doesn't seem to make much sense to mark a temporary address as preferred. That assumed, the current behavior of FreeBSD effectivly renders "prefer_source" useless if net.inet6.ip6.prefer_tempaddr=1. > > -- Hiroki Regards, Jan Behrens
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20200313233752.43d6fc44f51a60acbe4a9bb8>