Re: [babel] [Babel-users] key rotation take #2

Toke Høiland-Jørgensen <toke@toke.dk> Wed, 28 November 2018 21:19 UTC

Return-Path: <toke@toke.dk>
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 E292A1274D0 for <babel@ietfa.amsl.com>; Wed, 28 Nov 2018 13:19:46 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2
X-Spam-Level:
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: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=toke.dk
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 GqiYbv1OQzli for <babel@ietfa.amsl.com>; Wed, 28 Nov 2018 13:19:44 -0800 (PST)
Received: from mail.toke.dk (mail.toke.dk [52.28.52.200]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 774A9126DBF for <babel@ietf.org>; Wed, 28 Nov 2018 13:19:44 -0800 (PST)
From: Toke Høiland-Jørgensen <toke@toke.dk>
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=toke.dk; s=20161023; t=1543439982; bh=P7lvcG1eb4UQsTLOMnJO64iQ9qvhnI3zsN8XA9QjDIE=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=Lyt2+QIZADQTxBMptbyfW5WvOgoc4+CxJuSdJH16a/XicSyUbdwwdKYdGrnymqVUp KaItKDQVBCVuAsAi9Y8LJzmj4OSyaGqPneaXP5QIC/FnbHtvTa0zbpIUwWmc2Xsj9D rCU9umLur8E8eKur5o2ejZJnCgieEvaoowj+PQuxcrE1euEXOxkT9R+B0LmGWPglkC owBDGzMQtbKnJvDbgMRU5ny1HFZyI8plXfImwg1Za15IJn6EtEvffT8qE5dTodrtlA mupto2xOEkZtGDBqwqR7scatjCVb9wQwKtlw88QnGWpwTpemlyubOWrAn2alTHWWqZ 7kVuhguohaXBg==
To: Dave Taht <dave.taht@gmail.com>
Cc: Dave Täht <dave@taht.net>, babel-users <babel-users@lists.alioth.debian.org>, Babel at IETF <babel@ietf.org>
In-Reply-To: <CAA93jw5=82X-cvo0_ZXEvwEYt4_r4Nn-trOXTiLtKB_0q5kh2Q@mail.gmail.com>
References: <87in0h1ppd.fsf@taht.net> <87efb5v1y6.fsf@toke.dk> <877egx17w6.fsf@taht.net> <87tvk1t0h9.fsf@toke.dk> <CAA93jw5=82X-cvo0_ZXEvwEYt4_r4Nn-trOXTiLtKB_0q5kh2Q@mail.gmail.com>
Date: Wed, 28 Nov 2018 22:19:41 +0100
X-Clacks-Overhead: GNU Terry Pratchett
Message-ID: <87lg5cucgi.fsf@toke.dk>
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
Archived-At: <https://mailarchive.ietf.org/arch/msg/babel/gvWVKlj2D20pBbm73jP4pVCFNsY>
Subject: Re: [babel] [Babel-users] key rotation take #2
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: Wed, 28 Nov 2018 21:19:47 -0000

Dave Taht <dave.taht@gmail.com> writes:

> On Wed, Nov 28, 2018 at 12:23 PM Toke Høiland-Jørgensen <toke@toke.dk> wrote:
>>
>> Dave Taht <dave@taht.net> writes:
>>
>> > Toke Høiland-Jørgensen <toke@toke.dk> writes:
>> >
>> >> Dave Taht <dave@taht.net> writes:
>> >>
>> >>> so we invent a new keyword "serial".
>> >>
>> >> So what you're trying to express here is the notion of a "receive-only"
>> >> key that is not used for signing outgoing packets, right?
>> >
>> >
>> > No... the old key is retired from active use in the protocol after
>> > concensus is achieved on the new key by the protocol, and not used
>> > again unless a router comes up with an unreadable hmac. In that case
>> > we go back to at least trying to verify (periodically?) that it's not
>> > using the old key (if we still have it around) and if it's using the
>> > old key, we go back to signing stuff with that key.
>> >
>> > Does that concept need to be in the protocol spec?
>>
>> This reads to me like a specific operational procedure for deployment;
>> don't think that should go into the spec, no.
>>
>> >> it would be better to express that explicitly as a property of the key
>> >> config that can be changed on a per-key basis. For one thing, 'serial'
>> >> is misleading as it sounds like something that affects the wire
>> >> format,
>> >
>> > OK. how about "new" and "old" as keywords? That implies two states and
>> > two states only. I liked 0 and X as numbers, so long as the ascending
>> > property is maintained. As for why not 0 and 1, see below.
>> >
>> > Totally open to bikeshedding the name. :) babeltowerno?
>>
>> Don't care what they are called. My point is just that it's a property
>> of a particular key.
>>
>> Bird already has this, BTW: each key can be set to "generate" signatures
>> and "accept" signatures, where the former puts them on the wire, and the
>> latter will accept packets signed with that key. You can set time ranges
>> for each or both. See
>> https://bird.network.cz/?get_doc&v=20&f=bird-3.html (search for
>> "password option"). The Babel HMAC implementation inherits this.
>
> That is essentially my first proposal... in bird syntax. :) Aside from
> needing good time, there are really good reasons to stage key
> rotations that way....
>
> while the odds are much better that a boot/bootstrapping bird router
> has a working rtc, your typical home router doesn't.

No, but you can use the mechanism without the timeouts to mark keys as
active/passive using whatever provisioning system you are using to
distribute the keys (just use "{generate,accept} from 1970-01-01").

-Toke