Re: [MLS] Unpredictable epochs?

Benjamin Beurdouche <benjamin.beurdouche@inria.fr> Mon, 22 April 2019 22:52 UTC

Return-Path: <benjamin.beurdouche@inria.fr>
X-Original-To: mls@ietfa.amsl.com
Delivered-To: mls@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 41D981201F3 for <mls@ietfa.amsl.com>; Mon, 22 Apr 2019 15:52:30 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -6.899
X-Spam-Level:
X-Spam-Status: No, score=-6.899 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, HTML_MESSAGE=0.001, MIME_QP_LONG_LINE=0.001, RCVD_IN_DNSWL_HI=-5, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
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 ENDIlElHcPus for <mls@ietfa.amsl.com>; Mon, 22 Apr 2019 15:52:27 -0700 (PDT)
Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) (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 001F3120168 for <mls@ietf.org>; Mon, 22 Apr 2019 15:52:26 -0700 (PDT)
X-IronPort-AV: E=Sophos;i="5.60,383,1549926000"; d="scan'208,217";a="379704753"
Received: from unknown (HELO [10.131.166.155]) ([37.171.231.17]) by mail2-relais-roc.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 23 Apr 2019 00:52:25 +0200
Content-Type: multipart/alternative; boundary="Apple-Mail-C9FCEB9D-F9A6-4616-BD56-0B4E5911C189"
Mime-Version: 1.0 (1.0)
From: Benjamin Beurdouche <benjamin.beurdouche@inria.fr>
X-Mailer: iPhone Mail (16E227)
In-Reply-To: <CAL02cgR8gQ6cH_QXd_9v46aJ5aeo=b=1GiYu9YxCNYzJb0tOFQ@mail.gmail.com>
Date: Tue, 23 Apr 2019 00:52:24 +0200
Cc: Messaging Layer Security WG <mls@ietf.org>
Content-Transfer-Encoding: 7bit
Message-Id: <B36BF8F5-EAE9-4C96-A867-82CDFBF830C0@inria.fr>
References: <CAL02cgSE1xTF2Wsq-u=BCu2Z_4UzMzqMPi=D_H7_7hbRpUMVVA@mail.gmail.com> <2D195D14-9F9A-4D64-92EF-35C601C52C01@inria.fr> <CAL02cgR8gQ6cH_QXd_9v46aJ5aeo=b=1GiYu9YxCNYzJb0tOFQ@mail.gmail.com>
To: Richard Barnes <rlb@ipv.sx>
Archived-At: <https://mailarchive.ietf.org/arch/msg/mls/svsHXQdvMlAv43v1_WoPt2F19i4>
Subject: Re: [MLS] Unpredictable epochs?
X-BeenThere: mls@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Messaging Layer Security <mls.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/mls>, <mailto:mls-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/mls/>
List-Post: <mailto:mls@ietf.org>
List-Help: <mailto:mls-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/mls>, <mailto:mls-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 22 Apr 2019 22:52:30 -0000

+1

> On Apr 23, 2019, at 12:49 AM, Richard Barnes <rlb@ipv.sx> wrote:
> 
> True, you could have one unpredictable identifier that identifies both the group ID and the epoch.  I like how that looks on the wire, but would require a bit more bookkeeping in clients.  I might be inclined to go ahead and land an unpredictable-epoch PR in -05 (since that's a pretty small change), then look at folding in the group ID later.
> --RLB
> 
> 
>> On Mon, Apr 22, 2019 at 6:42 PM Benjamin Beurdouche <benjamin.beurdouche@inria.fr> wrote:
>> Side note before I forget. After merging the common framing, the only two things potentially remaining in the clear will be the group identifier and the epoch number (because we need those to pick the group key necessary to decrypt the sender info). Raphael and I talked about adopting a similar approach but generating an ephemeral Group Id at the same time. That could help a bit on the meta data protection side by making it harder for an adversarial DS to be able to correlate messages in delivery queues across groups and across epochs. The fact that this might be useful or not depends a lot on architecture assumptions though....
>> 
>> B.
>> 
>>> On Apr 23, 2019, at 12:11 AM, Richard Barnes <rlb@ipv.sx> wrote:
>>> 
>>> Hey all,
>>> 
>>> As I've been working with Benjamin on updating and landing the common framing PR, I noticed that the epoch is still exposing more information to the DS than it needs to.  
>>> 
>>> Right now, the epoch just increments by one every time the epoch changes.  This lets the DS track epochs statelessly -- it can take any two messages and see which was before the other, without the need for any ongoing tracking.
>>> 
>>> However, the epoch only needs to be intelligible to members of the group, so we could generate epoch values in a way that would only be intelligible to members.  For example [1]:
>>> 
>>> epoch_[n] = HKDF-Expand-Label(some_secret_for_epoch_[n], epoch_[n-1], "epoch", 4)
>>> 
>>> That way, the DS could observe epoch changes, and observe how many messages were sent within each epoch.  But it wouldn't be able to understand the sequence unless it tracked things all along.
>>> 
>>> A side benefit of this is that it allows the group to have forks in its history more cleanly, since different forks will have different epoch numbers.  That could allow some softness in the ordering requirement, as long as the group can eventually figure out which branch is the right one [2].
>>> 
>>> Does this seem worthwhile to people?  The cost is a few extra hashes.  To me, the completeness/consistency seems like a marginal benefit, but the clean forking seems pretty convincing.  If folks think this worthwhile, I'm happy to write up a PR.
>>> 
>>> Thanks,
>>> --Richard
>>> 
>>> 
>>> [1] I would probably keep epochs at 4 bytes, because any more seems wasteful.
>>> [2] http://mycours.es/gamedesign2012/files/2012/08/The-Garden-of-Forking-Paths-Jorge-Luis-Borges-1941.pdf
>>> _______________________________________________
>>> MLS mailing list
>>> MLS@ietf.org
>>> https://www.ietf.org/mailman/listinfo/mls