From owner-freebsd-net@freebsd.org Wed Jul 31 12:57:24 2019 Return-Path: Delivered-To: freebsd-net@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 9B6F3BDECE for ; Wed, 31 Jul 2019 12:57:24 +0000 (UTC) (envelope-from zarychtam@plan-b.pwste.edu.pl) Received: from plan-b.pwste.edu.pl (plan-b.pwste.edu.pl [IPv6:2001:678:618::40]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "plan-b.pwste.edu.pl", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 45zD3R6t63z3Jft for ; Wed, 31 Jul 2019 12:57:23 +0000 (UTC) (envelope-from zarychtam@plan-b.pwste.edu.pl) Received: from fomalhaut.potoki.eu (static62133140050.ostnet.pl [62.133.140.50]) (authenticated bits=0) by plan-b.pwste.edu.pl (8.15.2/8.15.2) with ESMTPSA id x6VCv7tN089769 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NO); Wed, 31 Jul 2019 14:57:07 +0200 (CEST) (envelope-from zarychtam@plan-b.pwste.edu.pl) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=plan-b.pwste.edu.pl; s=plan-b-mailer; t=1564577827; bh=ROkcl7YhgaC8S7VVd0VTeWGLVBLwOVOssJgCkyI7zy0=; h=To:References:From:Subject:Date:In-Reply-To; b=Ev8IezyQsNtXUcM/2sefhnUyKWDTkuWy1wb3BKYBzg3SaZmUwVRQjRz+vHVg8y1WC c+qD0S2l2vBUf5ddwHeLOyTEcSRF8YeaXntvna7bop+XjA5+j6Be93Xcj8kkDmPReV 34dB292a8zCEA+JWIEOI35wdz57XQVERNCbyTwu80yyYCal1AnNdsPe8myGTAud10n scsgcybahWPrucPjt6Mk2Dn42vkHdV9cJHIRhLcFl6tyv+ESMqpd/WgikKAsmWBsYb PkxChLMcnc+oHPiB6khZ8NEEkQ3tDJk+/D5e9HXBP7BEMSmE+ofyqZugzZ2JcRhVU2 RMX4AeeGHWPwQ== X-Authentication-Warning: plan-b.pwste.edu.pl: Host static62133140050.ostnet.pl [62.133.140.50] claimed to be fomalhaut.potoki.eu To: Viktor Dukhovni , freebsd-net@freebsd.org References: <20190731120705.GC24255@straasha.imrryr.org> From: Marek Zarychta Openpgp: preference=signencrypt Autocrypt: addr=zarychtam@plan-b.pwste.edu.pl; prefer-encrypt=mutual; keydata= mQENBFfi3cMBCADLecMTFXad4uDXqv3eRuB4qJJ8G9tzzFezeRnnwxOsPdytW5ES2z1ibSrR IsiImx6+PTqrAmXpTInxAi7yiZGdSiONRI4CCxKY9d1YFiNYT/2WyNXCekm9x29YeIU7x0JB Llbz0f/9HC+styBIu2H+PY/X98Clzm110CS+n/b9l1AtiGxTiVFj7/uavYAKxH6LNWnbkuc5 v8EVNc7NkEcl5h7Z9X5NEtzDxTOiBIFQ/kOT7LAtkYUPo1lqLeOM2DtWSXTXQgXl0zJI4iP1 OAu4qQYm2nXwq4b2AH9peknelvnt1mpfgDCGSKnhc26q6ibTfMwydp+tvUtQIQYpA6b9ABEB AAG0N01hcmVrIFphcnljaHRhIChQbGFuLWIpIDx6YXJ5Y2h0YW1AcGxhbi1iLnB3c3RlLmVk dS5wbD6JATcEEwEIACEFAlfi4LkCGwMFCwkIBwIGFQgJCgsCBBYCAwECHgECF4AACgkQHZW8 vIFppoJXdgf8D9X3VRFSNaR9lthSx/+uqas17J3FJKBo1xMQsC2a+44vzNvYJSuPGLLJ+LW2 HPVazjP/BWZJbxOYpliY4zxNRU0YCp0BLIVLibc//yax+mE42FND/+NiIZhqJscl6MLPrSwo sIwXec4XYkldkyqW/xBbBYXoIkBqdKB9j5j42Npy1IV/RizOSdmvTWY27ir8e/yGMR1RLr4F 8P5K3OWTdlGy2H2F/3J8bIPBLG6FpaIyLQw4dHSx8V02PYqDxK1c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Hp5Pruvb0x4MfFLNwaKtWK+UnJGPT4umj8PMP6XLsFC3g+SGoP aWoYRDI297ZGx4IBWEaJq181oEC5iUQ6WREti9fNQ3TsAB3Q2CjNlkx1geSczIFJSyOHmyJZ RqAocw1sIuPopvhWtR0AEQEAAYkCRAQYAQgADwUCV+OTdwIbAgUJCWYBgAEpCRAdlby8gWmm gsBdIAQZAQgABgUCV+OTdwAKCRB1n+z//VKNLOETCAC3ggwAAQij4hkIxQFapnRuIVb5vq7D AwJ9+Ld5/zYHOj2Tfu+BPSNGzI2edqboz2w1t55UHEYzYDp2axxIfPrZrXsBV4DsjtGwzVV/ jZ9or5qTaYFDEStRkzL4mRpTyYhl/T7GgWpwOJWOih+cU7RWzjSOxiYMi4QSYlkpDUCcZew0 C3HfcxeFqpeL46zgysHC2ptjINXQ+xR2/F6dbed+l7OsvJAfkBqJoQ/48m+8ly1lbViKck7q gWw143ljaKn2qGIjZdb95zcI/CP4L45SXq8NOweACdx2NfUphLrIMbNCqLkMUJcrnruKfbnp C8OMjFJIqlu+PsW593NcZyOugEAH/0cBsDxlSauSVK4kp8ald26pcBI6igNnIMgjaxMiZBjn eoxBiKAOAO93sPnPr9/64CMMwv1T+0vU2lj8SMKOdHVrB9sW/ICGji5skE85xPEAtUkdAQN+ +c2clotujcaj9lBZKJdncKmSxY0SshEa66H+s76u+2Q3jGK6vOrdxakWYCvh2P0/l52Nd/t2 eazLFgwtk5rbo7O0MSC1GNXUsG07vtZ+zxJXFRx7PQ3ZIn0Y4HqwvXUvqgZ9EHiKy8F+ondz 9IS8/Fs81N5ieujHhSWqbaibapnpeDHvT/FWf8iXfJqWq+F7C8lGShSkmsS5AOhB4TNNH5/m ZzECJa1ql64= Subject: Re: Preferring internal IPv6 source address over gif tunnel IP? Message-ID: <228a86f5-8c93-be6e-3847-896c89d430dc@plan-b.pwste.edu.pl> Date: Wed, 31 Jul 2019 14:57:01 +0200 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:60.0) Gecko/20100101 Thunderbird/60.7.0 MIME-Version: 1.0 In-Reply-To: <20190731120705.GC24255@straasha.imrryr.org> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="PczUBOGNFEvpyi4slqFcTrTGqNOq9OAnS" X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 31 Jul 2019 12:57:24 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --PczUBOGNFEvpyi4slqFcTrTGqNOq9OAnS Content-Type: multipart/mixed; boundary="w8hs3posPVBiwINpQHyBwh6igtE8MSeJn"; protected-headers="v1" From: Marek Zarychta To: Viktor Dukhovni , freebsd-net@freebsd.org Message-ID: <228a86f5-8c93-be6e-3847-896c89d430dc@plan-b.pwste.edu.pl> Subject: Re: Preferring internal IPv6 source address over gif tunnel IP? References: <20190731120705.GC24255@straasha.imrryr.org> In-Reply-To: <20190731120705.GC24255@straasha.imrryr.org> --w8hs3posPVBiwINpQHyBwh6igtE8MSeJn Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: quoted-printable W dniu 31.07.2019 o=C2=A014:07, Viktor Dukhovni pisze: >=20 > My FreeBSD machine is also my router, and for lack IPv6 support by > Verizon, now uses a "gif" tunnel via Hurricane Electric. >=20 > HE provides me with two prefixes: >=20 > 1. Point to point tunnel /128: >=20 > cloned_interfaces=3D"gif0" > create_args_gif0=3D"tunnel " > ifconfig_gif0_ipv6=3D"inet6 ::2 ::1 pref= ixlen 128" > ipv6_defaultrouter=3D"::1" >=20 > 2. A /64 for my network: >=20 > ipv6_network_interfaces=3D"igb1" > ifconfig_igb1_ipv6=3D"inet6 ::1 prefixlen 64" >=20 > They support DNS reverse resolution delegation for "my-network" > (the /64), but not the point-to-point "tunnel-prefix" (the /128). >=20 > Since a bunch of my traffic is SMTP, I need reverse resolution for > outgoing IPv6, which means that I need the outgoing sources address > to be ::1, not ::2, even though the > routing table lists "gif0" as the interface with the default route. >=20 > Is it possible to configure my system to use the internal /64 address > as the default source address of outgoing IPv6 packets? >=20 > If it would help, I can assign the "::1" address to the > external physical network interface (same one that has the tunnel > v4 address) or the loopback interface... RFC3484 section4 hints > at such possibilities (https://tools.ietf.org/html/rfc3484#page-9): >=20 > It is RECOMMENDED that the candidate source addresses be the set of > unicast addresses assigned to the interface that will be used to sen= d > to the destination. (The "outgoing" interface.) On routers, the > candidate set MAY include unicast addresses assigned to any interfac= e > that forwards packets, subject to the restrictions described below. >=20 > Discussion: The Neighbor Discovery Redirect mechanism [14] > requires that routers verify that the source address of a packet > identifies a neighbor before generating a Redirect, so it is > advantageous for hosts to choose source addresses assigned to the= > outgoing interface. Implementations that wish to support the use= > of global source addresses assigned to a loopback interface shoul= d > behave as if the loopback interface originates and forwards the > packet. >=20 > Or could I assign an explicit non-global scope to the tunnel address? > Or ... (whatever works). Any help much appreciated. >=20 Setting source address for MTA will be sufficient in this case. For example Sendmail requires ClientPortOptions to be set in .mc config file:= CLIENT_OPTIONS(`Family=3Dinet6, Addr=3D::1') --=20 Marek Zarychta --w8hs3posPVBiwINpQHyBwh6igtE8MSeJn-- --PczUBOGNFEvpyi4slqFcTrTGqNOq9OAnS Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAEBCAAdFiEEMOqvKm6wKvS1/ZeCdZ/s//1SjSwFAl1BkCMACgkQdZ/s//1S jSwxMAgAqIEAH+7Ggtzbd66G5RYHDqBYH9CfdXb/wYVKjAeChyo8To6Afe7WqCVe cc0k1wjPCqk3P19s6hM47kp8/DRy+jM+MnpmLl6NgLbGVBf1/SqsbR3q7MuS++6Q doHdLgCGtspEBACwWQ3J6jQ1SiRVdt1iN1ncsz1vgGUJ5JFaXAf0St8NpLxyWaSK 81pRwNAX049A01bknwXDOIh/XH8CEhsl13lmv31O52093onz3LzwkPVFaq4jUfe1 pOIn8go/zN1TfsjmFzKY4GitScyFz/7YU0U5ZMDRbIH3CTTtS9FH7oFYw8A02c5i HZ5AKKVU0z5MgQK3vBtpXlIau/Wd2g== =xeAT -----END PGP SIGNATURE----- --PczUBOGNFEvpyi4slqFcTrTGqNOq9OAnS--