Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 11 Dec 2018 15:07:02 +0300
From:      "Andrey V. Elsukov" <bu7cher@yandex.ru>
To:        Donald Sharp <sharpd@cumulusnetworks.com>, freebsd-net@freebsd.org
Subject:   Re: RFC 5549?
Message-ID:  <e4dc5bcb-15ba-a4b6-ddfb-a3fff7720dfb@yandex.ru>
In-Reply-To: <CAK989yck%2BW7co1QvTOEiHNHAf3nv1kDBx6cjwo9dLX9r6TvGFw@mail.gmail.com>
References:  <CAK989yck%2BW7co1QvTOEiHNHAf3nv1kDBx6cjwo9dLX9r6TvGFw@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
--Ku6wxjGO5nhYYy8A6US7o1ptNce3as4oU
Content-Type: multipart/mixed; boundary="wVekJHS5FYZCJljBNxF0zEFw9eYAS2zTZ";
 protected-headers="v1"
From: "Andrey V. Elsukov" <bu7cher@yandex.ru>
To: Donald Sharp <sharpd@cumulusnetworks.com>, freebsd-net@freebsd.org
Message-ID: <e4dc5bcb-15ba-a4b6-ddfb-a3fff7720dfb@yandex.ru>
Subject: Re: RFC 5549?
References: <CAK989yck+W7co1QvTOEiHNHAf3nv1kDBx6cjwo9dLX9r6TvGFw@mail.gmail.com>
In-Reply-To: <CAK989yck+W7co1QvTOEiHNHAf3nv1kDBx6cjwo9dLX9r6TvGFw@mail.gmail.com>

--wVekJHS5FYZCJljBNxF0zEFw9eYAS2zTZ
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: quoted-printable

On 24.10.2018 23:10, Donald Sharp wrote:
> All -
>=20
> The FRRouting project has some basic support for rfc 5549 and I've
> been asked to see if it is possible to get this bit of code working
> with the FRRouting freebsd kernel interface.  What is RFC 5549 you
> ask?  The tl;dr of it is that you have v4 prefixes w/ a v6 gateway.
> For some more background the linux implementation cheats ( and I would
> like to emphatically point out that I'm not suggesting this solution,
> I'm giving the linux solution to the problem as a data point to how it
> was solved in one instance ) by installing a neighbor entry for
> `169.254.0.1 <outgoing interface> <mac address on the other side>` and
> when installing the v4 prefix we see the v6 nexthop and replace it
> with `169.254.0.1 <outgoing interface>` in the netlink message to the
> kernel.  Is support of RFC 5549 possible in Freebsd?

Hi,

I have thought a bit about this, and have some ideas how implement this.
In general we can install into the kernel routes that has IPv6 address
as gateway for IPv4 (currently this is not allowed by default, but it is
easy to allow). So, as a routing daemon developer you can use generic
API to install routes where RTAX_GATEWAY is IPv6 address.

Then we need to modify ip_forward, ip_output, ip_tryforward to correctly
handle such routes. layer2 output routines should already correctly
handle IPv4 packets that are going trough the IPv6 gateway and it will
use ND6 lookup code to obtain Layer2 addresses.

The most complex it seems will the modification of ip_tryforward code,
since it is optimized for IPv4 and doesn't have enough room for
extending. With such changes IPv6 only router should be able to do IPv4
forwarding.

The problems that come to mind are inability to correctly send ICMP
messages, since there are no IPv4 addresses that can be used as IPv4
source, and how existing programs will handle such routes when they will
appear in a routing socket.

--=20
WBR, Andrey V. Elsukov


--wVekJHS5FYZCJljBNxF0zEFw9eYAS2zTZ--

--Ku6wxjGO5nhYYy8A6US7o1ptNce3as4oU
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----
Comment: Using GnuPG with Thunderbird - https://www.enigmail.net/

iQEzBAEBCAAdFiEE5lkeG0HaFRbwybwAAcXqBBDIoXoFAlwPqGoACgkQAcXqBBDI
oXqbtQf+JKygrqeBvbVLoR6wQTGTRR/P1aVADHAwrRjUrl9Pj2C/dHEUkuW9jxrE
FKkfKk7u9qTquoTArXEeaYnINCixNIXUv0Ye2Q3mTjQlCsF2eUsJWejBMoCVYHA5
xbQv1m1y82GOCSyxQ78Kl/FgIjEpnNv01Dn/2HmB/HYN8hrCZ2Bk6Zz4d+W5NAOt
PHeLBBTH9I6P/fotaL+OF3gPZtoaboT7DB3YPO4cpNgBi9HD92iLth24Zgoe2qHo
FKoWuwWmWLgxpZI7rsTF+leBVMt/gp7jTcSblI1+KCmDc9Wmi8sHFUfbIrrRgieT
B+TtIru4+xdU82KxSpSeUaXASRXSew==
=dxYd
-----END PGP SIGNATURE-----

--Ku6wxjGO5nhYYy8A6US7o1ptNce3as4oU--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?e4dc5bcb-15ba-a4b6-ddfb-a3fff7720dfb>