[babel] Babel v4-over-v6 extension

Théophile Bastian <theophile.bastian@ens.fr> Fri, 13 March 2020 08:08 UTC

Return-Path: <theophile.bastian@ens.fr>
X-Original-To: babel@ietfa.amsl.com
Delivered-To: babel@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 0BE133A134F for <babel@ietfa.amsl.com>; Fri, 13 Mar 2020 01:08:55 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.097
X-Spam-Level:
X-Spam-Status: No, score=-2.097 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=ens.fr
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id LyKvNx8Litrm for <babel@ietfa.amsl.com>; Fri, 13 Mar 2020 01:08:53 -0700 (PDT)
Received: from nef.ens.fr (nef2.ens.fr [129.199.96.40]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id E35243A134C for <babel@ietf.org>; Fri, 13 Mar 2020 01:08:52 -0700 (PDT)
X-ENS-nef-client: 129.199.1.22
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ens.fr; s=default; t=1584086930; bh=72yUYA0KDagh4gP9PAZATWCFH5Kwbc4PWmbqRlsU2hY=; h=To:From:Subject:Date:From; b=M3jdX0pJdRTBcoyvpFrbLpnl5ErcPkM5xKH9+gtViPmBAd7f7ajhfuNAKlA+1eYVE DZuGm3Nx/5+PtNqCEPnbdurMg9HiND0NQ2c4tPs/+7c+yrt7TxyqM2l6g0JaVMMTDp uFqlDVbOQSRXviQlbWilL3fry0Y46+ZhxT1oOQxs=
Received: from clipper.ens.fr (clipper-gw.ens.fr [129.199.1.22]) by nef.ens.fr (8.14.4/1.01.28121999) with ESMTP id 02D88oPj008109 for <babel@ietf.org>; Fri, 13 Mar 2020 09:08:50 +0100
Received: from [192.168.0.14] using smtps by clipper.ens.fr (8.14.4/jb-1.1) id 02D88opG074034 for <babel@ietf.org>; Fri, 13 Mar 2020 09:08:50 +0100 (authenticated user tbastian)
X-ENS-Received: (91-160-99-187.subs.proxad.net [91.160.99.187])
X-Envelope-To: <babel@ietf.org>
To: Babel at IETF <babel@ietf.org>
From: Théophile Bastian <theophile.bastian@ens.fr>
Message-ID: <df08cb39-04b9-dd13-4af6-8d8803cc71ad@ens.fr>
Date: Fri, 13 Mar 2020 09:08:50 +0100
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.5.0
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"; format="flowed"
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (nef.ens.fr [129.199.96.32]); Fri, 13 Mar 2020 09:08:50 +0100 (CET)
Archived-At: <https://mailarchive.ietf.org/arch/msg/babel/uwnWeagqFUNvPoSf_uZ2u9Vp8rg>
Subject: [babel] Babel v4-over-v6 extension
X-BeenThere: babel@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "A list for discussion of the Babel Routing Protocol." <babel.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/babel>, <mailto:babel-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/babel/>
List-Post: <mailto:babel@ietf.org>
List-Help: <mailto:babel-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/babel>, <mailto:babel-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 13 Mar 2020 08:08:55 -0000

Dear all,

I am a new intern working with Juliusz on Babel.

My goal at the moment is to implement v6-over-v4 routing in Babel, that
is, using an IPv6 address as a next hop for an IPv4 packet. This
would allow, for instance, a router without IPv4 address to be used as
a next hop for an IPv4 packet, since this feature was recently
introduced in the Linux kernel [1].

I have so far experimentally implemented this feature in a fork of
babeld [here](https://github.com/tobast/babeld). This code is NOT
production-ready, and needs to be mostly re-written. It does not
reflect the exact changes we propose either yet.

We have considered three options to design this extension:

(i) One possibility, due to Toke, is to add a v4-over-v6 route whenever
   a router receives an UPDATE for a v4 prefix without a preceding v4 NH
   TLV. The next hop would then be the latest v6 NH TLV, if any, or the
   link-local address of the neighbour announcing the update otherwise —
   just as it would be done for a v6 UPDATE.

* Another possibility is to introduce a new AE for v4-over-v6. This AE
   would behave in the same way as AE 1 (IPv4) in all contexts except
   NH — in which case it would behave as AE 2 (non-link-local IPv6).

   In this case, we have to consider the state of the protocol.

   When parsing an IPv4 address, if `omitted != 0`, we use a stored
   prefix from previous TLVs for compression. This prefix cannot be
   reused with this new AE to preserve backwards compatibility. Indeed,
   a v4-over-v6 TLV might change the v4 compression prefix. Yet, this
   TLV will be ignored by any older implementation of babel, thus
   breaking the protocol state.

   However, we see no such argument that would prevent us from reusing
   the AE 2 (IPv6) next-hop. We this have two options:

   (ii)  either we use as a next-hop the address from the latest AE 2 NH
         TLV, if any, or the link-local address of the neighbour
         otherwise;
   (iii) or we use a distinct state to store NH TLVs for this new AE: we
         use as a next-hop the address from the latest NH TLV with this
         new AE, if any, or the link-local address of the neighbour
         otherwise.

Here, backwards compatibility is especially important to take into
account, since we are not only considering the case where a router is
using an old version of Babel, but also the case in which the host
system of a router does not support v6-over-v4 routes.

So far, we are more inclined to choose option (iii).

We prefer (ii/iii) over (i), because option (i) does not signal clearly
in any way that an extension of the protocol is being used, and might
confuse older versions. We also believe it is easier to understand,
debug and trace, and comes at a price of only a small overhead wrt.
(i).

Between (ii) and (iii), Juliusz is in favour of (iii), since option
(ii) mixes reuse and separate state in a weird way, and might be
confusing. I do not have yet a clear opinion on this, but I am inclined
to agree with him.

Any opinion on this choice is appreciated!


In the current experimental version, I implement this using AE 4, but I
will change it very soon to AE 240 to ensure this experimental version
does not break any future production implementation if this ID is fine
for everyone — see the previous mail from Juliusz regarding this.


[1] 
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=d15662682db232da77136cd348f4c9df312ca6f9

Best regards,
-- Théophile