Re: [TLS] A flags extension

Hubert Kario <hkario@redhat.com> Thu, 28 March 2019 13:54 UTC

Return-Path: <hkario@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 7A3161204D2 for <tls@ietfa.amsl.com>; Thu, 28 Mar 2019 06:54:21 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -6.9
X-Spam-Level:
X-Spam-Status: No, score=-6.9 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_HI=-5, SPF_PASS=-0.001, URIBL_BLOCKED=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 S13DafpkHEuw for <tls@ietfa.amsl.com>; Thu, 28 Mar 2019 06:54:16 -0700 (PDT)
Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 3B0921204D0 for <tls@ietf.org>; Thu, 28 Mar 2019 06:54:10 -0700 (PDT)
Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 5BA89307E068; Thu, 28 Mar 2019 13:54:04 +0000 (UTC)
Received: from pintsize.usersys.redhat.com (unknown [10.43.21.83]) by smtp.corp.redhat.com (Postfix) with ESMTP id AD4B8437F; Thu, 28 Mar 2019 13:54:03 +0000 (UTC)
From: Hubert Kario <hkario@redhat.com>
To: tls@ietf.org
Date: Thu, 28 Mar 2019 14:54:02 +0100
Message-ID: <2095110.rQzEGthnPs@pintsize.usersys.redhat.com>
In-Reply-To: <dcdcba29-9571-4747-880e-2aba9f649775@www.fastmail.com>
References: <A7EC005E-3463-406B-930F-925B4D2338E4@gmail.com> <8CCF5B81-9873-41AB-B062-AD109365A80A@gmail.com> <dcdcba29-9571-4747-880e-2aba9f649775@www.fastmail.com>
MIME-Version: 1.0
Content-Type: multipart/signed; boundary="nextPart3449075.hRGToHpW1S"; micalg="pgp-sha512"; protocol="application/pgp-signature"
X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13
X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.42]); Thu, 28 Mar 2019 13:54:04 +0000 (UTC)
Archived-At: <https://mailarchive.ietf.org/arch/msg/tls/3ujxhuf5s_OO_YOfKgMdd93kdCU>
Subject: Re: [TLS] A flags extension
X-BeenThere: tls@ietf.org
X-Mailman-Version: 2.1.29
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, 28 Mar 2019 13:54:28 -0000

On Wednesday, 27 March 2019 14:42:49 CET Martin Thomson wrote:
> Why not go all in - make this a byte string and start from 0x80 in the first
> byte.  When we define the 9th flag, we add another byte.  Then you have up
> to 2040 flags (though it might pay to split the space before that).
> 
> struct {
>   opaque<1..255> flags;
> } Flags;
> 
> Otherwise, the first adopter of this pays 10 bytes where they would
> previously have paid 4.  Obviously there is a network effect at the third. 
> Since I'm writing a draft that will aim to depend on this, I have a vested
> interest in using this.

this will be the only place with a bit mask in TLS, I have serious doubts 
about the correctness of code that will handle this stuff
 
> If you wanted to make it more attractive to me, then maybe porting some of
> the existing flags across might make it more appealing.

what about making sure that the legacy and flags remain in-sync? we will have 
to send the legacy encoding for many years to come, so only thing it would 
possibly reduce the size of is ServerHello or EncryptedExtensions

> On Wed, Mar 27, 2019, at 13:08, Yoav Nir wrote:
> > > On 27 Mar 2019, at 12:26, Daniel Kahn Gillmor <dkg@fifthhorseman.net>
> > > wrote:> > 
> > > On Wed 2019-03-27 10:52:20 +0100, Nikos Mavrogiannopoulos wrote:
> > >> Right. What about defining a set of extensions (e.g., 2 extensions) of
> > >> flags as:
> > >> 
> > >> struct {
> > >> 
> > >>  uint64 flags;
> > >> 
> > >> } Flags;
> > > 
> > > If we're going to be doing this kind of bit-shaving, this is the way to
> > > go, starting with a single CommonFlags extension -- and maybe even a
> > > uint32 or uint16, with the bitfield registry under tight WG control. If
> > > we exhaust that space, then we just define a CommonFlags2 extension.
> > > 
> > > If someone wants an experimental boolean extension to play with, they
> > > can always use an empty extension. They can apply for a bit in
> > > CommonFlags if they find that the compactness is warranted.
> > 
> > OK. You got me convinced.
> > 
> > In the spirit of revising quickly and revising often, I’ve uploaded
> > version -01:
> > 
> > HTML: https://datatracker.ietf.org/doc/html/draft-nir-tls-tlsflags
> > DIFF: https://www.ietf.org/rfcdiff?url2=draft-nir-tls-tlsflags-01
> > 
> > Yoav
> > 
> > _______________________________________________
> > TLS mailing list
> > TLS@ietf.org
> > https://www.ietf.org/mailman/listinfo/tls
> 
> _______________________________________________
> TLS mailing list
> TLS@ietf.org
> https://www.ietf.org/mailman/listinfo/tls


-- 
Regards,
Hubert Kario
Senior Quality Engineer, QE BaseOS Security team
Web: www.cz.redhat.com
Red Hat Czech s.r.o., Purkyňova 115, 612 00  Brno, Czech Republic