Re: [TLS] Comments on TLS-ECJ-PAKE draft

Feng Hao <feng.hao@newcastle.ac.uk> Wed, 20 July 2016 15:14 UTC

Return-Path: <feng.hao@newcastle.ac.uk>
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 B957212D7DA for <tls@ietfa.amsl.com>; Wed, 20 Jul 2016 08:14:12 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -4.202
X-Spam-Level:
X-Spam-Status: No, score=-4.202 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=newcastle.onmicrosoft.com
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 Nnov2WVgYTQj for <tls@ietfa.amsl.com>; Wed, 20 Jul 2016 08:14:08 -0700 (PDT)
Received: from cheviot12.ncl.ac.uk (cheviot12.ncl.ac.uk [128.240.234.12]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 5681B12D7DB for <tls@ietf.org>; Wed, 20 Jul 2016 08:14:08 -0700 (PDT)
Received: from exhubvm02.ncl.ac.uk ([128.240.234.9] helo=EXHUBVM02.campus.ncl.ac.uk) by cheviot12.ncl.ac.uk with esmtp (Exim 4.63) (envelope-from <feng.hao@newcastle.ac.uk>) id 1bPtCI-0008Mc-BK; Wed, 20 Jul 2016 16:14:06 +0100
Received: from EUR01-VE1-obe.outbound.protection.outlook.com (213.199.154.239) by exhub.ncl.ac.uk (128.240.234.9) with Microsoft SMTP Server (TLS) id 14.3.266.1; Wed, 20 Jul 2016 16:13:59 +0100
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=newcastle.onmicrosoft.com; s=selector1-newcastle-ac-uk; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=zhSWLesJhtn+t+D69Zt1sMyeAlZIotA5zGcsgEDejxI=; b=lnookAUrdm3l3QCXuPbTcqWewliRykGJcG06MXa5vKpha8nCo0mh/kMuRiOxLdAgOGIEOhXVEBOslWBZbS4G0vnD3+DXQshcGpZKiEcrnd5wXiC8qeSAakpDxa1ZBdhCZ5gTEkgcbGzJjwREihBijX89Ts4UFKtkg0wA96wPowA=
Received: from DB5PR0701MB1928.eurprd07.prod.outlook.com (10.167.228.24) by DB5PR0701MB1925.eurprd07.prod.outlook.com (10.167.228.21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.544.10; Wed, 20 Jul 2016 15:13:56 +0000
Received: from DB5PR0701MB1928.eurprd07.prod.outlook.com ([10.167.228.24]) by DB5PR0701MB1928.eurprd07.prod.outlook.com ([10.167.228.24]) with mapi id 15.01.0544.014; Wed, 20 Jul 2016 15:13:56 +0000
From: Feng Hao <feng.hao@newcastle.ac.uk>
To: Dan Harkins <dharkins@lounge.org>
Thread-Topic: [TLS] Comments on TLS-ECJ-PAKE draft
Thread-Index: AQHR4NwvKPpbhbjrqEGFHD5Bf6yEOKAgLS+AgADxAwCAAC48EA==
Date: Wed, 20 Jul 2016 15:13:56 +0000
Message-ID: <DB5PR0701MB1928838A1C8962766AA6F01BD4080@DB5PR0701MB1928.eurprd07.prod.outlook.com>
References: <CADrU+d+V3MNuUPp-FmJopS=SRn5Zp673758i5Y+Sg4qP+gUaMA@mail.gmail.com> <52173e33a5b14592b16ac6b6eae8fe81.squirrel@www.trepanning.net> <CADrU+dL6e-kou3QDmYZpseXkBYzPF4haLOmUzoZzNBw5Z-XivQ@mail.gmail.com> <2ee1801e4404fd17c2a1694ac12f79d3.squirrel@www.trepanning.net>
In-Reply-To: <2ee1801e4404fd17c2a1694ac12f79d3.squirrel@www.trepanning.net>
Accept-Language: en-GB, en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
authentication-results: spf=none (sender IP is ) smtp.mailfrom=feng.hao@newcastle.ac.uk;
x-originating-ip: [128.240.225.103]
x-ms-office365-filtering-correlation-id: ecaec035-fada-42bc-192d-08d3b0b0780e
x-microsoft-exchange-diagnostics: 1; DB5PR0701MB1925; 6:Z5C2GFZV9pOkzzDcJcZIGuXrt8zUnmnEF5b4OKn7eruLN1hIrZP+GVkWiTlAB2anF1WUxzNpMTgCNIK9oTpdbMcT2mhPa2fxEKPZShmfYv+jjiwHJvTsZiYSHPRlqDBRq8jlrykR8dCV53fSY7lYb5DEQNyrLu+OElXms/OxGYZRLk0tSrQzMbyXDKCR0/pHBne6MakOkbPuRO3lDrTqdQe8QXm4419dKT8mAvRJsTsUmuA1HhGKobg68OEcRTOp2pYBBHzbbQgksFq03x6KIkwzdN2rC0zoWJw4i0GYmZU=; 5:iPdENwk5Cl40DU8h50e7cLp0AEjt47KYukZr7VuOGxmm0D08vXlWAMbLTIx3gotftD3uS9z81ZHIv6exBs8tAo9widHztGoPWY6ugZIbsYpDXHelLCtoO/IJQvRIp03BI0rGMMmPxT/ITHJi2VK5jA==; 24:J9EZiAlSVp2En59yxR++5dIaTO62Snm7nIQscTaNVkItjgh1YVQqZwz90NIWzcapQ5xHrr70e6ICkMqLwFCmn6Ell4nwAJ5F8iI9GA3IPbA=; 7:NI1QSEciQi+w4cLbgBHPphy/1LDY9ko2ErUDgt+FRD+SjwOmCEO7Z/TGOihnvOks/tTqyvHn3mYsDje3h6rRJefbIXX+Ftm+pe0vufLL0NTlyGRIb/JCE2xhuRKfFe4cmcYY8bBpERniXDve1X9yaE65TxfC+58BdE8Xyl5SctNAxkneQ2mVazMJCGND/7cLzyU+2o+YGZiNp5aUD50/IR5kzVrpQFT011uNJVDQXPUJho7XjFhIo5xegYpuiugd
x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:DB5PR0701MB1925;
x-microsoft-antispam-prvs: <DB5PR0701MB1925CEA452BCBB288757C876D4080@DB5PR0701MB1925.eurprd07.prod.outlook.com>
x-exchange-antispam-report-test: UriScan:(158342451672863)(278428928389397)(166708455590820)(192374486261705);
x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(601004)(2401047)(8121501046)(5005006)(10201501046)(3002001); SRVR:DB5PR0701MB1925; BCL:0; PCL:0; RULEID:; SRVR:DB5PR0701MB1925;
x-forefront-prvs: 000947967F
x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(6009001)(7916002)(377454003)(24454002)(13464003)(189002)(199003)(230783001)(102836003)(11100500001)(66066001)(4326007)(2906002)(74316002)(87936001)(106116001)(8936002)(106356001)(33656002)(3846002)(3280700002)(3660700001)(9686002)(6116002)(74482002)(122556002)(76576001)(10400500002)(2950100001)(2900100001)(15975445007)(77096005)(5002640100001)(105586002)(81166006)(81156014)(93886004)(86362001)(76176999)(50986999)(54356999)(97736004)(68736007)(15395725005)(586003)(189998001)(7846002)(7696003)(305945005)(8676002)(92566002)(19580405001)(101416001)(19580395003)(110136002)(7736002)(5003600100003); DIR:OUT; SFP:1101; SCL:1; SRVR:DB5PR0701MB1925; H:DB5PR0701MB1928.eurprd07.prod.outlook.com; FPR:; SPF:None; PTR:InfoNoRecords; MX:1; A:1; LANG:en;
received-spf: None (protection.outlook.com: newcastle.ac.uk does not designate permitted sender hosts)
spamdiagnosticoutput: 1:99
spamdiagnosticmetadata: NSPM
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
MIME-Version: 1.0
X-MS-Exchange-CrossTenant-originalarrivaltime: 20 Jul 2016 15:13:56.1362 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 9c5012c9-b616-44c2-a917-66814fbe3e87
X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB5PR0701MB1925
X-OriginatorOrg: newcastle.ac.uk
Archived-At: <https://mailarchive.ietf.org/arch/msg/tls/XPvjlVAslpMWC3J6fcIgkDz64ds>
Cc: "tls@ietf.org" <tls@ietf.org>
Subject: Re: [TLS] Comments on TLS-ECJ-PAKE draft
X-BeenThere: tls@ietf.org
X-Mailman-Version: 2.1.17
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: Wed, 20 Jul 2016 15:14:13 -0000

Hi Dan,

On your first comment, Yes, J-PAKE requires one more flow, but for the following benefits

 * Unlike EKE and SRP, it has the flexibility to work in any prime-order subgroup over a finite field (e.g., DSA-like groups). 
 * Unlike SPAKE2, it doesn't require setting up two generators whose discrete logarithm must be unknown. The design of J-PAKE is to let end users have the complete control of the randomness (by generating two ephemeral public keys which are random and unrelated) rather than trusting an external party to set the randomness in the group parameters.
 * Unlike Dragonfly, it doesn't require any hashing-to-curve function. It merely needs a curve, a base point and +/* operations. Hence, it can be easily applied to any EC curve that is suitable for cryptography (as long as the DDH assumption holds).

On your second comment, is there any fundamental reason why the first flow (client hello) can't contain key exchange messages? Kindly note that:

 * The proposed PAKE usage is not meant for web browsers (for reasons explained in the draft). But TLS should be useful for applications other than just web browsers. 
 * In a non-browser setting for realizing secure communication between two remote parties and considering the fact that J-PAKE is a balanced PAKE (same as Dragonfly), it seems sensible to let client initiate the choice of ciphersuit and see if the server supports it (here, I use client and server for convenience, but they are more like peers with equal say).

Cheers,
Feng

-----Original Message-----
From: TLS [mailto:tls-bounces@ietf.org] On Behalf Of Dan Harkins
Sent: 20 July 2016 11:18
To: Robert Cragie <robert.cragie@gmail.com>;
Cc: tls@ietf.org
Subject: Re: [TLS] Comments on TLS-ECJ-PAKE draft


  Hi Robert,

  Sorry for the confusing comments. There are 2 but one follows because of the other.

  The first comment concerns the fact that J-PAKE is a 4 message handshake. This is different than other PAKES like EKE, SPAKE2, dragonfly, or SRP which all establish their shared key in a single
2 message exchange. A 2 message exchange falls into the TLS handshake elegantly, e.g.:

  - figure 1 in https://tools.ietf.org/html/rfc5054#page-5
and
  - figure 1 in https://tools.ietf.org/html/draft-ietf-tls-pwd-07#page-10

as opposed to:

  - figure 1 in
https://tools.ietf.org/html/draft-cragie-tls-ecjpake-00#page-7

where as you are making the TLS "Hello phase" into a "Hello plus one-half of the key exchange phase". This is my comment about this being a fundamental change to TLS.

  Now the 2nd comment that follows out of the 1st is that by overloading the Hello Phase to include half the key exchange phase you remove all ability to do negotiation. When TLS-ECJ-PAKE is used it is the only thing that can be used. The client can only offer it and it can only talk to servers that support it. Which is why my 2nd comment is that this is fundamentally a proprietary protocol. You don't need a cipher suite assignment for this because you have no ability to negotiate it. You could make it 0xFF,0xFC-FF (reserved for private use) and have no issues. You will never have interop issues with some other TLS-like private protocol that also uses 0xFF,0xFC-FF because you'll never talk to them. Your TLS-ECJ-PAKE client always and only talks to your TLS-ECJ-PAKE server so your private assignment of the private use cipher suites cannot conflict with any other private assignment. Proprietary protocols don't need cipher suite assignments and this is a proprietary extension of TLS.

  regards,

  Dan.

On Tue, July 19, 2016 12:55 pm, Robert Cragie wrote:
> Hi Dan,
>
> What you say regarding the NamedCurve/EllipticCurveList is of course 
> right.
> Whether this constitutes a fundamental change to TLS is debatable. The 
> aim was never to propose this as a cipher suite for general inclusion 
> in a range of supported cipher suites in a browser/server scenario as 
> is pointed out in various places in the draft. The aim was to reuse 
> TLS (a well-known and widely implemented protocol) as a vehicle to 
> support the ECJ-PAKE method and to deliberately constrain the 
> implementation parameters a priori. To me, that does not make this a 
> proprietary protocol and the ease by which existing TLS 
> implementations have been adapted to support TLS-ECJ-PAKE. I guess it 
> does raise the wider question of "what is TLS"
> though and whether this approach flouts conventional thinking about 
> TLS (which, IMHO, it doesn't).
>
> Robert
>
> On 18 July 2016 at 11:06, Dan Harkins <dharkins@lounge.org>; wrote:
>
>>
>>   Hi Robert,
>>
>>   This draft moves the NamedCurve/EllipticCurveList into the 
>> ClientHello, and since the client sends X1 and ZKP(X1) in the 
>> ClientHello it means that is going to be a list of 1. It basically 
>> moves the client's key exchange portion from ClientKeyExchange into 
>> ClientHello. So basically, if a client wants to do TLS-ECJ-PAKE then 
>> that's the only thing it can offer and the parameters of that 
>> exchange are all selected by the client, not the server.
>>
>>   This is a fundamental change to TLS. If it's going to be offered, 
>> it's the only thing that can be offered and therefore the only thing 
>> that can be used. Seems like for a deployment either it's never used 
>> or it's the only thing used and that makes it sort of a proprietary 
>> protocol, not TLS.
>>
>>   Dan.
>>
>> On Thu, June 16, 2016 2:51 am, Robert Cragie wrote:
>> > I would like to ask the working group for comments on the 
>> > TLS-ECJ-PAKE
>> > draft:
>> >
>> > https://tools.ietf.org/html/draft-cragie-tls-ecjpake-00
>> >
>> > Some brief notes:
>> >
>> > * This intended status is informational.
>> > * The draft is based on TLS/DTLS 1.2 as the Thread group required
>> basis
>> on
>> > existing RFCs wherever possible. For that reason and due to the WGs
>> focus
>> > on TLS 1.3, I have understood from the chairs that it would not 
>> > have received a great deal of attention from the WG, hence the 
>> > intended
>> status
>> > of informational.
>> > * The draft reflects the current use of the
>> TLS_ECJPAKE_WITH_AES_128_CCM_8
>> > cipher suite in Thread (http://threadgroup.org/).
>> > * There is an experimental implementation in mbed TLS (
>> > https://github.com/ARMmbed/mbedtls)
>> > * The Thread group would like to get IANA assignments for 4 cipher
>> suite
>> > values and one ExtensionType value as soon as possible.
>> > * There are at least four independent implementations, which have 
>> > been used in interop. testing over the last 18 months.
>> > * The security considerations recommend restriction of the use of 
>> > this cipher suite to Thread and similar applications and recommends 
>> > it
>> should
>> > not be used with web browsers and servers (mainly due to the long 
>> > discussions regarding the use of PAKEs on this and other mailing
>> lists).
>> >
>> > Robert
>> > _______________________________________________
>> > 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