Date: Fri, 02 Aug 2019 03:00:53 +0900 (JST) From: Hiroki Sato <hrs@allbsd.org> To: viktor@dukhovni.org Cc: freebsd-net@freebsd.org Subject: Re: Preferring internal IPv6 source address over gif tunnel IP? Message-ID: <20190802.030053.435733628684510322.hrs@allbsd.org> In-Reply-To: <20190731120705.GC24255@straasha.imrryr.org> References: <20190731120705.GC24255@straasha.imrryr.org>
next in thread | previous in thread | raw e-mail | index | archive | help
----Security_Multipart(Fri_Aug__2_03_00_53_2019_115)-- Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Viktor Dukhovni <viktor@dukhovni.org> wrote in <20190731120705.GC24255@straasha.imrryr.org>: vi> 1. Point to point tunnel /128: vi> vi> cloned_interfaces="gif0" vi> create_args_gif0="tunnel <my-public-ipv4> <their-tunnel-ipv4>" vi> ifconfig_gif0_ipv6="inet6 <tunnel-prefix>::2 <tunnel-prefix>::1 prefixlen 128" vi> ipv6_defaultrouter="<tunnel-prefix>::1" You do not need to use ifconfig_gif0_ipv6 for a point-to-point configuration with <tunnel-prefix>. The following configuration should do the trick while this is different from suggested one from he.net: cloned_interfaces="gif0" create_args_gif0="tunnel <my-public-ipv4> <their-tunnel-ipv4>" ifconfig_gif0_ipv6="inet6 auto_linklocal" ipv6_defaultrouter="-interface gif0" Using this configuration, your source IPv6 address will be that on igb1. And if you have two or more physical interfaces you can define ip6addrctl.conf to control which address is used for the source address depending on the destination address. -- Hiroki ----Security_Multipart(Fri_Aug__2_03_00_53_2019_115)-- Content-Type: application/pgp-signature Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- iEYEABECAAYFAl1DKNUACgkQTyzT2CeTzy0HfgCdF+niasXw35fCE2svw+SmPjvs DGcAn0VefsDd7hiedp7Z0TNddXBXk+hc =GbEW -----END PGP SIGNATURE----- ----Security_Multipart(Fri_Aug__2_03_00_53_2019_115)----
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20190802.030053.435733628684510322.hrs>