Subject: [Cfrg] Edwards ladder

From: Watson Ladd <[email-masked]>
Date: Tue, 2 Dec 2014 09:06:30 -0800

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.

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.

As a result, I think we don't have an alternative to Montgomery
x-coordinate only that is as efficient and as secure, and certainly
not as simple.  I think that most people on the list are in agreement
about this.

This leaves signatures and which form of Montgomery ladder ECDH to use
as open issues.

Sincerely,
Watson Ladd

---

From: Robert Ransom <[email-masked]>
Date: Tue, 2 Dec 2014 09:53:02 -0800

> 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.)

> 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

---

From: Mike Hamburg <[email-masked]>
Date: Tue, 02 Dec 2014 10:11:00 -0800

> software, and found that they were slower than the Montgomery-form
IIRC I just guessed at the Edwards ladder's based on microbenchmarks, 
and figured it would be slower.  What was slower in my measurements, but 
faster in Microsoft's, was Edward fixed-window, which I may have 
mistakenly called "Edward ladder" in an email.  The discrepancy was 
partly because it requires point decompression, but MS ECCLib doesn't 
implement that, and partly for reasons unknown.
>> not as simple.  I think that most people on the list are in agreement
Yep.  There's also the option of a single-coordinate unified format, but 
those add quite a bit of complexity.  The one I used in Goldilocks also 
doesn't work when p==1 mod 4.

-- Mike