[PATCH] Babel: add RFC9229 (v4 via v6) support
Ondrej Zajicek
santiago at crfreenet.org
Tue Feb 14 19:13:52 CET 2023
On Tue, Feb 14, 2023 at 06:25:33PM +0100, Juliusz Chroboczek wrote:
> > 1) Changed the name of the option to 'extended next hop', for consistency
> > with BGP (and in the future also with other protocols). As the option is
> > enabled by default, the name likely does not matter that much.
>
> I rather like v4-via-v6, which succintly and clearly states what it is
> about.
I am not sure about that. Without knowing the context and that it is
about next hops, i would guess that 'v4-via-v6' is some kind of automatic
tunneling (like 4over6) provisioned by Babel.
In general, we prefer to use the same name for equivalent features
between protocols, that is not first such case. There are cases where
it was not done, and it annoys me everytime when i mistake one option
name in place where the other name should be used.
Also, there is a possibility of reverse usage (IPv6 routes with IPv4 next
hops, perhaps encoded as IPv4-mapped IPv6 addresses in regular AE 2 ?).
But that is not useful now, as we do not (AFAIR) support third-party next
hops anyways.
> > 3) In babel_handle_update(), move condition 'Reject IPv4 via IPv6 routes
> > if disabled' above 'Retraction'. In your patch it was below, so
> > retractions in AE 4 were accepted even on interfaces with this feature
> > disabled.
>
> That's reasonable enough, it shouldn't matter either way. Perhaps the
> former behaviour was more robust in the case where a node loses its IPv4
> address and then immediately retracts the routes that it previously
> announced.
I thought that next hops are sent in retractions, but now i see they are
not used here, in that case it would make more sense to ignore it,
perhaps on the parser level.
btw, there is one question that i noticed. If an Update is ignored for
semantic reasons (e.g. update with valid metric, but missing next hop or
router id), should it update last prefix with P-flag? RFC says that for
sub-TLV errors but not for other errors:
"Update TLVs with a matching address encoding within the same packet, even if this TLV is otherwise ignored due to an unknown mandatory sub-TLV"
BIRD currently does not remember prefix of ignored update for missing
next hop, but does remember prefix of ignored update for missing router id.
> Just a minor inconsistency, v4-via-v6 requests are accepted even if the
> option is disabled (line 1084).
Good point.
--
Elen sila lumenn' omentielvo
Ondrej 'Santiago' Zajicek (email: santiago at crfreenet.org)
OpenPGP encrypted e-mails preferred (KeyID 0x11DEADC3, wwwkeys.pgp.net)
"To err is human -- to blame it on a computer is even more so."
More information about the Bird-users
mailing list