Re: [Cfrg] Edwards ladder

Robert Ransom <rransom.8774@gmail.com> Tue, 02 December 2014 17:53 UTC

Return-Path: <rransom.8774@gmail.com>
X-Original-To: cfrg@ietfa.amsl.com
Delivered-To: cfrg@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 735431A1BFB for <cfrg@ietfa.amsl.com>; Tue, 2 Dec 2014 09:53:04 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.75
X-Spam-Level:
X-Spam-Status: No, score=-1.75 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, 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 ErQVtn7QqVUb for <cfrg@ietfa.amsl.com>; Tue, 2 Dec 2014 09:53:03 -0800 (PST)
Received: from mail-qg0-x22c.google.com (mail-qg0-x22c.google.com [IPv6:2607:f8b0:400d:c04::22c]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 365B91A0392 for <cfrg@irtf.org>; Tue, 2 Dec 2014 09:53:03 -0800 (PST)
Received: by mail-qg0-f44.google.com with SMTP id z60so9829093qgd.3 for <cfrg@irtf.org>; Tue, 02 Dec 2014 09:53:02 -0800 (PST)
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; bh=GPgcg1Gv8ErXi7yVu5yrpn04z6aOGz30xptJAhMZJsE=; b=X1Suw+Zvd2bVui17jLHgTlf/HS6eRExAmjTklvKjvAJ0mCr9e8QZHJJOBDdHPnYJ4h DFwUgQRL8RGqkBC6HwUjqmLRB6Xy54RKQ15JOGjeD/jWoeJgGMOF8AxdkDnUqFJ2NFPN zA814u6A39ezaT+Xob4ddGy/lBcJY64ItqTfeo3VeFqScFHNmPb317oW88IU7amzAafo XliKS1j+dCS/ye5Z3Qe83mCUdpA8PQhrrKzsmlozhXf0QCcWzr4SvDETKuO43CePRJRB tplEm0E6fmT05FFzzhzanAXH8HUuqTcHn3D5FJvL2JW87wnAS8xbUXEebRXzWc8J1ZkR F/aw==
MIME-Version: 1.0
X-Received: by 10.224.129.9 with SMTP id m9mr740578qas.50.1417542782302; Tue, 02 Dec 2014 09:53:02 -0800 (PST)
Received: by 10.140.30.100 with HTTP; Tue, 2 Dec 2014 09:53:02 -0800 (PST)
In-Reply-To: <CACsn0cmbFO8q--_=gwHUGO=aA=W_yJk3zGho1MWkiobB_qoQhw@mail.gmail.com>
References: <CACsn0cmbFO8q--_=gwHUGO=aA=W_yJk3zGho1MWkiobB_qoQhw@mail.gmail.com>
Date: Tue, 02 Dec 2014 09:53:02 -0800
Message-ID: <CABqy+sphAzC-rX06f61YVT8rjZVZbyMjGneouTb=ry0S783_+A@mail.gmail.com>
From: Robert Ransom <rransom.8774@gmail.com>
To: Watson Ladd <watsonbladd@gmail.com>
Content-Type: text/plain; charset="UTF-8"
Archived-At: http://mailarchive.ietf.org/arch/msg/cfrg/WXe1POS8I6AFKO6qWT47GapIH8c
Cc: "cfrg@irtf.org" <cfrg@irtf.org>
Subject: Re: [Cfrg] Edwards ladder
X-BeenThere: cfrg@irtf.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: Crypto Forum Research Group <cfrg.irtf.org>
List-Unsubscribe: <http://www.irtf.org/mailman/options/cfrg>, <mailto:cfrg-request@irtf.org?subject=unsubscribe>
List-Archive: <http://www.irtf.org/mail-archive/web/cfrg/>
List-Post: <mailto:cfrg@irtf.org>
List-Help: <mailto:cfrg-request@irtf.org?subject=help>
List-Subscribe: <http://www.irtf.org/mailman/listinfo/cfrg>, <mailto:cfrg-request@irtf.org?subject=subscribe>
X-List-Received-Date: Tue, 02 Dec 2014 17:53:04 -0000

On 12/2/14, Watson Ladd <watsonbladd@gmail.com> wrote:
> Dear all,
>
> The formulas on the EFD for a y-coordinate only Edwards ladder require
> d to be a square. They are slightly more efficient than the Montgomery
> ladder when squaring is specially optimized. Unfortunately, the
> Edwards curve formulas we are considering don't have d square.

In order for the ladder formula shown on
<http://hyperelliptic.org/EFD/g1p/auto-edwards-yzsquared.html> to be
even close to more efficient, s must be chosen to be a small integer;
r is then a ratio of small integers and 1*r requires two small-integer
multiplies.

Mike Hamburg tried that formula with an earlier version of his Ed448
software, and found that they were slower than the Montgomery-form
ladder.


In addition, that formula has an exceptional case when Y1=0 (the
affine points of order 4), which is relatively harmless for
cryptographic purposes but makes implementation-distinguishing attacks
more likely and makes a mathematically correct implementation more
complex than a merely interoperable implementation.

I don't see the point of investigating those formulas further.


(If anyone else wants to try them, I found a twist-secure curve
optimized for that formula over the same field as Curve3617; the curve
parameter's value was 2170.  I think the parameter was s.)


> The relatively little amount of thought I've given to this matter
> hasn't produced an isogeny that makes d square. Furthermore, picking d
> square makes the addition laws not complete: it's not possible to have
> both the efficient ladder and a complete addition law simultaneously
> when using Edwards coordinates.

You can map a complete Edwards curve with cofactor 8 (or divisible by
8) to an Edwards curve with square d by using the E_d -> L_d map shown
in <https://eprint.iacr.org/2011/135>.  (It's also in one of Dr.
Bernstein's papers, but I don't remember exactly where.)

(But you don't gain anything by doing that for an existing curve.  The
Gaudry et al. formulas are only worth considering if you can choose a
new curve to suit them.)



Robert Ransom