Re: [babel] HMAC Key rotation key format (was ripemd)

Toke Høiland-Jørgensen <> Mon, 26 November 2018 22:22 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id 4DEF913103C for <>; Mon, 26 Nov 2018 14:22:10 -0800 (PST)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -2
X-Spam-Status: No, score=-2 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: (amavisd-new); dkim=pass (2048-bit key)
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id PjzS7uTqXjrt for <>; Mon, 26 Nov 2018 14:22:08 -0800 (PST)
Received: from ( [IPv6:2001:470:dc45:1000::1]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by (Postfix) with ESMTPS id 0B618130DFC for <>; Mon, 26 Nov 2018 14:22:08 -0800 (PST)
From: Toke =?utf-8?Q?H=C3=B8iland-J=C3=B8rgensen?= <>
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple;; s=20161023; t=1543270926; bh=DTVpOgj/UhHAO8yPTaTqiFUnJgk6q1MhPNQDBnbow38=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=OYPrZDPNTq9jvjBnSi40DpzM4rPQ2AkJa03tTi4qQrwoB7ehg0xBTTJ/N9MfZhpNh c2PMa52LaP9/2gbvDOE1dRUv6uU0kdYZdzHTRqoIYdVijB1f5SG40+ZjVk8IJsKBXp QvSySfaErpZruOMjw806S+n5AgCmWvuH3ABKxYAFYuv2M+onYwr/pVP+4rZqscOLwt KPIVT1VnC6xl8XcwF9Veeld4XoZXLHRY8QO7q1qj22sBoZOrqBQ8Crpc4gKJhKQnbQ mxODlLoefZdbqwUa4HyWtb3ymmAHHmmhViaNSxjcnN8A8X1REvTWPbq913Ii8FstLs 9SoqDDwtTC25Q==
To: Dave Taht <>
Cc: Juliusz Chroboczek <>, babel-users <>, Babel at IETF <>
In-Reply-To: <>
References: <> <> <> <> <> <> <> <>
Date: Mon, 26 Nov 2018 23:22:05 +0100
X-Clacks-Overhead: GNU Terry Pratchett
Message-ID: <>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
Archived-At: <>
Subject: Re: [babel] HMAC Key rotation key format (was ripemd)
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "A list for discussion of the Babel Routing Protocol." <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Mon, 26 Nov 2018 22:22:10 -0000

Dave Taht <> writes:

> On Mon, Nov 26, 2018 at 1:10 PM Toke Høiland-Jørgensen <> wrote:
>> Dave Taht <> writes:
>> > To me this leaves the biggest problem remaining is key rotation. Me
>> > being me, and remembering just how hard it was to get dnssec working
>> > on systems lacking reliable time,
>> The Babel HMAC extension as currently specified does not rely on wall
>> clock time in any way, so not really sure how a comparison to dnssec is
>> relevant?
> More below. Relative time is ok, too. 3000 seconds from now, start
> rolling over. Stop signing records with the old key as soon as
> everyone you can currently hear uses the new key, 6000 seconds from
> now, retire the old key unconditionally.

Well, you would handle this by whatever mechanism you use to configure
your routers in the first place...

>> > Setting that aside for the moment, having a standardized file format
>> > for babel keys would be a boon and boost interoperability between
>> > bird/babel and other possible implementations.
>> From the point of view of each routing daemon this would just make Babel
>> a special snowflake.
> ok. That leaves how to get new keys into nodes running different
> daemons. Anyone for IKEv2?
> My out of bound way is via scp and ssh.

I think Juliusz' insistence that we shouldn't reinvent key distribution
is wise. See above; you need to configure the daemons in the first place

> Also the present babeld cannot rewrite it's entire config file (so far
> as I know). I think bird can...

Yup, a 'bird reconfigure' will re-read the entire config file and apply
it if it parses successfully.

> but I don't trust it.

Your trust issues are probably best resolved between you and your daemon ;)

>> What we can do is to specify the format in the information model if a
>> cross-implementation format is really needed (which I'm not really
>> convinced of, either)...
> To quote from appendix A:
> "In order to perform key rotation, the new key is added to all the
> nodes; once this is done, both the old and the new key are sent in all
> packets, and packets are accepted if they are properly signed by
> either of the keys. At that point, the old key is removed."
> My key points made here are "the new key is added to *all* the
> nodes"... which may or may not be up over the course of days, or weeks
> for whatever definition of "all" you have ... "Once this is done" -
> how can you tell? -  "and packets are accepted if they are properly
> signed by either of the keys" hopefully you log this ... "the old key
> is removed".
> perhaps "deprecated, no longer actively used for signing, then removed
> after a suitable period"?

Hmm, having a way to mark a key as "verify only" may be useful for
simpler monitoring. But really, you *could* derive the same information
from the opposite bit (track how many neighbours don't sign with the new
key yet). So then it becomes more of an efficiency issue (you could save
one signature on the wire during rotation). Not sure if it's worth
specifying another bit in the spec for this? Or if such a configuration
mode should even be in the spec at all?

> So, if you do a key rotation and X routers are offline or inaccessible
> at that particular time... they are going to stay inaccessible
> forevermore, unless rekey'd via sneakernet, climbing on trees, and
> other forms of manual intervention.

Presumably your key rotation policy would take into account the outage
schedules of the routers in your network? :)