Re: [TLS] certificate type negotiaiton in draft-ietf-tls-oob-pubkey-06

"Hannes Tschofenig" <Hannes.Tschofenig@gmx.net> Fri, 21 December 2012 15:04 UTC

Return-Path: <hannes.tschofenig@gmx.net>
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 4422621F84E8 for <tls@ietfa.amsl.com>; Fri, 21 Dec 2012 07:04:34 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -101.98
X-Spam-Level:
X-Spam-Status: No, score=-101.98 tagged_above=-999 required=5 tests=[AWL=0.000, BAYES_00=-2.599, RCVD_IN_SORBS_WEB=0.619, USER_IN_WHITELIST=-100]
Received: from mail.ietf.org ([64.170.98.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id i4kBUhGuyOtj for <tls@ietfa.amsl.com>; Fri, 21 Dec 2012 07:04:33 -0800 (PST)
Received: from mout.gmx.net (mout.gmx.net [212.227.15.19]) by ietfa.amsl.com (Postfix) with ESMTP id 3400021F84BB for <tls@ietf.org>; Fri, 21 Dec 2012 07:04:33 -0800 (PST)
Received: from mailout-de.gmx.net ([10.1.76.32]) by mrigmx.server.lan (mrigmx001) with ESMTP (Nemesis) id 0M5Jbd-1SsqBt14ed-00zVSv for <tls@ietf.org>; Fri, 21 Dec 2012 16:04:30 +0100
Received: (qmail 3014 invoked by uid 0); 21 Dec 2012 15:04:30 -0000
Received: from 213.162.68.169 by www026.gmx.net with HTTP; Fri, 21 Dec 2012 16:04:28 +0100 (CET)
Content-Type: text/plain; charset="utf-8"
Date: Fri, 21 Dec 2012 16:04:28 +0100
From: Hannes Tschofenig <Hannes.Tschofenig@gmx.net>
In-Reply-To: <50BB09D3.6010106@gnutls.org>
Message-ID: <20121221150428.160970@gmx.net>
MIME-Version: 1.0
References: <50BB09D3.6010106@gnutls.org>
To: Nikos Mavrogiannopoulos <nmav@gnutls.org>, tls@ietf.org
X-Authenticated: #29516787
X-Flags: 0001
X-Mailer: WWW-Mail 6100 (Global Message Exchange)
X-Priority: 3
X-Provags-ID: V01U2FsdGVkX1+9oSx7i9G9pSbJBe1RH9WbvmKO1Pfv+q6e+PistZ gHi4HFeF9qXAMYnH4JcDrHuTX82byvnqb4Vw==
Content-Transfer-Encoding: 8bit
X-GMX-UID: Kx+mcIVfeSEqRpIAqXUhl8Z+IGRvbwB7
Subject: Re: [TLS] certificate type negotiaiton in draft-ietf-tls-oob-pubkey-06
X-BeenThere: tls@ietf.org
X-Mailman-Version: 2.1.12
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: <http://www.ietf.org/mail-archive/web/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: Fri, 21 Dec 2012 15:04:34 -0000

Hi Nikos, 

thanks for your review comments and for spotting a bug. 

In the current draft a single structure is used by both the client and the server to convey information about the "certificate" types they accept and they offer. 

You suggest to encode this information into two different types of payloads and that is similar to what we had in an earlier draft version (see http://tools.ietf.org/html/draft-ietf-tls-oob-pubkey-04). The feedback we got at the summer IETF meeting was that this approach was not preferred. Consequently, we changed it. 

Regarding your remark "Why sbd suggest 0,3 and the server reply with 1,2?". I believe the symbolic names are more intuitive for end users who read the specifications and the semantic is explained in the text. A program does not care what numbers are used for the different options. 

Ciao
Hannes

-------- Original-Nachricht --------
> Datum: Sun, 02 Dec 2012 08:57:07 +0100
> Von: Nikos Mavrogiannopoulos <nmav@gnutls.org>
> An: tls@ietf.org
> CC: paul@nohats.ca, Hannes Tschofenig <hannes.tschofenig@gmx.net>
> Betreff: certificate type negotiaiton in draft-ietf-tls-oob-pubkey-06

> Hello,
>  There is a bug in the draft. The CertTypeExtension structure is defined
> as:
>    struct {
>       select(ClientOrServerExtension)
>           case client:
>             CertificateType certificate_types<1..2^8-1>;
>           case server:
>             CertificateType certificate_type;
>       }
>    } CertTypeExtension;
> 
> but the server is expected to send more than one certificate types (as
> seen in examples). This cannot happen with the current structure.
> 
> Also the whole certificate type negotiation seems complicated. Currently
> the certificate types are defined as:
> 
>    enum { X.509-Accept (0),
>           X.509-Offer (1),
>           RawPublicKey-Accept (2),
>           RawPublicKey-Offer (3),
>           (255)
>          } CertificateType;
> 
> So a client that accepts X.509 certificates and has a raw key will send
> (from the example in the draft)
> 
> certificate_type=(X.509-Accept(0), RawPublicKey-Offer(3)) ->
> 
>                             <-  server_hello,
>                                 certificate_type=(X.509-Offer(1),
>                                      RawPublicKey-Accept(2)),
> 
> Which can be confusing. Why sbd suggest 0,3 and the server reply with 1,2?
> 
> I think it would be much simpler to have the certificate type defined as
>    enum { X.509 (0),
>           RawPublicKey (1),
>           (255)
>          } CertificateType;
> 
> and then modify the extension as:
>    struct {
>       select(ClientOrServerExtension)
>           case client:
>             CertificateType client_certificate_types<1..2^8-1>;
>             CertificateType server_certificate_types<1..2^8-1>;
>           case server:
>             CertificateType client_certificate_type;
>             CertificateType server_certificate_type;
>       }
>    } CertTypeExtension;
> 
> Which will result in a simpler exchange, and there is no need to know
> which side is it in order to interpret the contents of the messages.
> 
> client_certificate_type=(raw(1))
> server_certificate_type=(x509(0))
> 
>                             <-  server_hello,
>                                 client_certificate_type=(raw(1))
>                                 server_certificate_type=(x.509(0))
> 
> regards,
> Nikos