Re: [TLS] TLS 1.3 multiple session tickets from the client?

Nikos Mavrogiannopoulos <nmav@redhat.com> Thu, 17 May 2018 14:09 UTC

Return-Path: <nmav@redhat.com>
X-Original-To: tls@ietfa.amsl.com
Delivered-To: tls@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 8EF81126D45 for <tls@ietfa.amsl.com>; Thu, 17 May 2018 07:09:04 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.921
X-Spam-Level:
X-Spam-Status: No, score=-1.921 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, 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 QhW72fA-r2OD for <tls@ietfa.amsl.com>; Thu, 17 May 2018 07:08:59 -0700 (PDT)
Received: from mail-wm0-f41.google.com (mail-wm0-f41.google.com [74.125.82.41]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 8554D124BFA for <tls@ietf.org>; Thu, 17 May 2018 07:08:59 -0700 (PDT)
Received: by mail-wm0-f41.google.com with SMTP id n10-v6so9340253wmc.1 for <tls@ietf.org>; Thu, 17 May 2018 07:08:59 -0700 (PDT)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:date:in-reply-to :references:mime-version:content-transfer-encoding; bh=MeBB3599I6W2gZN8gXynHRDpcgzzfAOyQCWnnSpgkKg=; b=NjayNcEtmvl031qzOMvqFgdeVQ3rbWJW5897qJxw2oJDLZHjn2j08jpcypIqPxq8ah Pfkq7uPtisfmCZQr5PdOvJlKcRNdhljAojeuivVQuKpTEa2b8lgc8tsYQNFk9PpzNkF1 SfHIQi0xd0pD7EpswUGBYf3HfYOoiBzT6TTVEYG8/2v0yUHmtgugkmiYP65inFSS2MKR F2nkZ8CU1FbfMTlxazgHDh7tQBA20DaQbzAA5JwJd1Bn6/iBZvpz7ALNz1E3e/Eg7J7F StBjaNPwEMW99P7uik2xHATJikZCpQtQspvB3qisqEoHPKlsNfkDdbQSd43AeHGyza0T ODMg==
X-Gm-Message-State: ALKqPwey+xHS97yYz4fV3CH1XbGPKZFuqVadYY7U7ODnHCLDuJ+993e9 oI3lakkQJxk0L4EawTSMXT5b5Fc+bzc=
X-Google-Smtp-Source: AB8JxZoI4VKTDUEGMtZvXf1g9ckLJmBewPuIakkr8uBJKy1Hoz4qOXFvVUstN/uOc7gbF63Tt4mQwA==
X-Received: by 2002:a1c:6b57:: with SMTP id g84-v6mr1804894wmc.127.1526566137956; Thu, 17 May 2018 07:08:57 -0700 (PDT)
Received: from dhcp-10-40-1-102.brq.redhat.com (nat-pool-brq-t.redhat.com. [213.175.37.10]) by smtp.gmail.com with ESMTPSA id z10-v6sm6312119wre.43.2018.05.17.07.08.56 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 17 May 2018 07:08:57 -0700 (PDT)
Message-ID: <cd5b5a79a1b6aab525a4d4f32cd44da4660b32ef.camel@redhat.com>
From: Nikos Mavrogiannopoulos <nmav@redhat.com>
To: a@juaristi.eus, tls@ietf.org
Date: Thu, 17 May 2018 16:08:56 +0200
In-Reply-To: <6ce06cc0b8e699aba0578b75618d30a0@juaristi.eus>
References: <773A6343-2978-4195-BF53-B5253E3B9129@dukhovni.org> <CABkgnnXNnheqdRBO_h6XVK5uvr-qoM9_xSMq4EEH5CgKLWqabw@mail.gmail.com> <CABcZeBPqVTWaZ5pXBf66jt+2m0rXA6LoqaddQB8onvwjE+39QQ@mail.gmail.com> <71974FFA-DEA4-4C66-BDAE-FAD7BF46463B@dukhovni.org> <CABcZeBN1gF7gtQbxKg_5xs4DSimKR1Gf=-0Pm9=b1D_M6rSY3A@mail.gmail.com> <BBFEDE28-AC26-4748-9F49-8B6EBF12F1F1@dukhovni.org> <8ae36587211182108801d686475474d2d34c9084.camel@redhat.com> <6ce06cc0b8e699aba0578b75618d30a0@juaristi.eus>
Content-Type: text/plain; charset="UTF-8"
X-Mailer: Evolution 3.28.2 (3.28.2-1.fc28)
Mime-Version: 1.0
Content-Transfer-Encoding: 8bit
Archived-At: <https://mailarchive.ietf.org/arch/msg/tls/DzgQ600QjPI6Y05XxmtYrRylUCo>
Subject: Re: [TLS] TLS 1.3 multiple session tickets from the client?
X-BeenThere: tls@ietf.org
X-Mailman-Version: 2.1.22
Precedence: list
List-Id: "This is the mailing list for the Transport Layer Security working group of the IETF." <tls.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/tls>, <mailto:tls-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/tls/>
List-Post: <mailto:tls@ietf.org>
List-Help: <mailto:tls-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/tls>, <mailto:tls-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 17 May 2018 14:09:04 -0000

On Wed, 2018-05-16 at 11:30 +0200, Ander Juaristi wrote:
> El 2018-05-11 09:05, Nikos Mavrogiannopoulos escribió:
> > On Thu, 2018-05-10 at 11:46 -0400, Viktor Dukhovni wrote:
> > > 
> > > Good to know.  Does any implementation other than OpenSSL support
> > > external PSKs?  How do you distinguish between external PSKs and
> > > resumption PSKs?
> > 
> > gnutls does. For external PSKs It checks for ticket age being zero
> > and
> > the username/identity within acceptable bounds.
> 
> Hey Nikos,
> 
> I remember we had this discussion, but wanted to transfer it to the
> list 
> as even though I believe that approach
> will work almost always, by reading the current draft my
> understanding 
> is that being the ticket age zero is no more than a hint
> that it *might* be a PSK.
> 
> What's wrong with trying to decrypt it first and then if decryption 
> fails treat it as an external PSK and look up
> its identity in the database? GnuTLS encrypts the tickets with EtA
> so 
> with "decrypt" I mean checking the MAC first,
> and then decrypting. Isn't this a stronger check?

Decrypting a ticket may not always be possible. For example, server
keys may get rotated, or a server may receive key which were destined
for another server in the pool.

> Another option to remove some ambiguity out of here would just be to 
> change the draft to say that externally set PSKs
> MUST have a ticket age of zero (rather than SHOULD). This way a
> server 
> can instantly recognize an external PSK. A real
> ticket can never have an obfuscated ticket age of zero, right? Or it 
> can?

I think that ticket age could be zero even for non-preshared keys (not
very likely though).

A field which could potentially be used to distinguish tickets is the
key_name of an rfc5077 formatted ticket.

regards,
Nikos