Re: [TLS] Curve25519 in TLS and Additional Curves in TLS

Watson Ladd <watsonbladd@gmail.com> Thu, 03 April 2014 16:53 UTC

Return-Path: <watsonbladd@gmail.com>
X-Original-To: tls@ietfa.amsl.com
Delivered-To: tls@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 986FD1A025F for <tls@ietfa.amsl.com>; Thu, 3 Apr 2014 09:53:06 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.7
X-Spam-Level:
X-Spam-Status: No, score=-1.7 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, MIME_8BIT_HEADER=0.3, SPF_PASS=-0.001] autolearn=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 kBEgkhNG8ezd for <tls@ietfa.amsl.com>; Thu, 3 Apr 2014 09:53:02 -0700 (PDT)
Received: from mail-yk0-x22b.google.com (mail-yk0-x22b.google.com [IPv6:2607:f8b0:4002:c07::22b]) by ietfa.amsl.com (Postfix) with ESMTP id 9C7231A021B for <tls@ietf.org>; Thu, 3 Apr 2014 09:53:02 -0700 (PDT)
Received: by mail-yk0-f171.google.com with SMTP id q9so1810029ykb.30 for <tls@ietf.org>; Thu, 03 Apr 2014 09:52:58 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=a1YWVqWWgbOrD/f4WMesQNtLB5McGuENwCE317lrENI=; b=Zzz6a2TBwry7R/YMNucY6hN2yFxIkf7UEr6m0dTSZLJbnLI20aqHUsCp02SsQsuUiQ IJGAEdzD4ketumsWisEFlBfpmOXFR8NMuN/vqELVwl7MpPPEYyQaep0OlQXVj829sJSu x4lC2CkjxxhrXT7AAr5er09+wmPRQFaOz3Mlixz07NrG/2FxeUzgFLylZB7kmmkOZk7A E0TwpCrxAv/f9Fp4N1517cnoh9WwM98R+CKuRCjiNC6Kybp8Fh1ATIBrQXzXWIvN3hOJ NlCcYYR4W19yejznwDHhCyjLIDiqSXIf22VGWjVr8J9gca06ZFriR+Sa+Okh5z8kumki IO8w==
MIME-Version: 1.0
X-Received: by 10.236.191.67 with SMTP id f43mr9836445yhn.60.1396543978215; Thu, 03 Apr 2014 09:52:58 -0700 (PDT)
Received: by 10.170.63.197 with HTTP; Thu, 3 Apr 2014 09:52:58 -0700 (PDT)
In-Reply-To: <533D2207.807@polarssl.org>
References: <87ob3456s1.fsf@latte.josefsson.org> <20140402164340.GA14790@roeckx.be> <533C554A.7080607@akr.io> <533CF9C5.7030107@brainhub.org> <533D2207.807@polarssl.org>
Date: Thu, 03 Apr 2014 09:52:58 -0700
Message-ID: <CACsn0cmevdjDv0TgS3mczcxpeSz=1cbc3Wp_d--VeXqvPgitww@mail.gmail.com>
From: Watson Ladd <watsonbladd@gmail.com>
To: Manuel Pégourié-Gonnard <mpg@polarssl.org>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Archived-At: http://mailarchive.ietf.org/arch/msg/tls/PyP38InJlz6NaGTP9lrYdZwVkJE
Cc: "tls@ietf.org" <tls@ietf.org>
Subject: Re: [TLS] Curve25519 in TLS and Additional Curves in TLS
X-BeenThere: tls@ietf.org
X-Mailman-Version: 2.1.15
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: Thu, 03 Apr 2014 16:53:06 -0000

On Thu, Apr 3, 2014 at 1:55 AM, Manuel Pégourié-Gonnard
<mpg@polarssl.org> wrote:
> On 03/04/2014 08:03, Andrey Jivsov wrote:
>> The ECPoint is defined as follows,
>>
>>             struct {
>>                 opaque point <1..2^8-1>;
>>             } ECPoint;
>>
>> Is the format on the wire per section 2.3
>>     33 32 xx xx xx ... xx
>> or, suggested,
>>     65 64 xx xx xx ... xx yy yy yy ... yy ?
>>
>> Or I am reading it incorrectly and the extra byte mentioned in the draft
>> is actully a part of standard TLS encoding of the length byte?
>>
> The intention of the current draft is that the wire format be
>
> 32 xx xx ... xx
>
> So the "additional length byte" is indeed just the one from the TLS encoding.
>
> In the next iteration of the draft, it might change to
>
> 33 tt xx xx .. xx
>
> Where tt would be an "encoding type" which would allow for future extensions
> like transmitting y too, or a bit of y, or (parts of) other representation (eg
> Edwards coordinates).

I don't think this is a good idea. At the time when one side sees the
point it is too late to negotiate. So points with different encodings
should be indicated as different in the Client Hello message to enable
negotiation of which one to send. Furthermore, I don't see benefit to
the potential extensions yet for pure DH.

Also, do we really need a length prefix on a string that is always 32
bytes long? I get that the TLS encoding provides that, but length
prefix formats are a can of worms: what should happen when 33 0 or 32
32 xx .. are encountered?

Sincerely,
Watson Ladd

>
> Manuel.
>
> _______________________________________________
> TLS mailing list
> TLS@ietf.org
> https://www.ietf.org/mailman/listinfo/tls



-- 
"Those who would give up Essential Liberty to purchase a little
Temporary Safety deserve neither  Liberty nor Safety."
-- Benjamin Franklin