04.11.2012 Views

1 Montgomery Modular Multiplication in Hard- ware

1 Montgomery Modular Multiplication in Hard- ware

1 Montgomery Modular Multiplication in Hard- ware

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

FEI KEMT<br />

handicap of the <strong>Montgomery</strong> form is the fact that not every arbitrary curve can be<br />

transformed <strong>in</strong>to this form. Hence, there is merely <strong>in</strong>terest <strong>in</strong> implement<strong>in</strong>g ECC<br />

based on <strong>Montgomery</strong> form curves.<br />

The residue class of P +Q <strong>in</strong> this set can be computed from P , Q and P −Q us<strong>in</strong>g<br />

4 multiplications and 1 squar<strong>in</strong>g (see Equation 3.9). A doubl<strong>in</strong>g, i. e. 2P , can be<br />

computed from P and curve parameter A (see 3.8) us<strong>in</strong>g 5 squar<strong>in</strong>gs (Equation 3.10).<br />

S<strong>in</strong>ce we are only <strong>in</strong>terested <strong>in</strong> check<strong>in</strong>g whether we obta<strong>in</strong> the po<strong>in</strong>t at <strong>in</strong>f<strong>in</strong>ity O<br />

for some prime divisor of n comput<strong>in</strong>g <strong>in</strong> S is no restriction.<br />

Addition: (3.9)<br />

xP +Q ≡ zP −Q[(xP − zP )(xQ + zQ) + (xP + zP )(xQ − zQ)] 2<br />

zP +Q ≡ xP −Q[(xP − zP )(xQ + zQ) − (xP + zP )(xQ − zQ)] 2<br />

(mod n)<br />

(mod n)<br />

Doubl<strong>in</strong>g: (3.10)<br />

4xP zP ≡ (xP + zP ) 2 − (xP − zP ) 2<br />

x2P ≡ (xP + zP ) 2 (xP − zP ) 2<br />

(mod n)<br />

(mod n)<br />

z2P ≡ 4xP zP [(xP − zP ) 2 + 4xP zP (A + 2)/4] (mod n)<br />

F<strong>in</strong>d<strong>in</strong>g Suitable Curves <strong>in</strong> <strong>Montgomery</strong> Form Assume a curve of the form<br />

By 2 = x 3 + Ax 2 + x with gcd((A 2 − 4)B, n) = 1 (3.11)<br />

Such curves have a group order divisible by 4. To obta<strong>in</strong> an order divisible by 12,<br />

choose A and B such that<br />

The po<strong>in</strong>t<br />

A = −3a4 − 6a2 + 1<br />

4a3 , B = (a2 − 1) 2<br />

4a3 , with a = t2 − 1<br />

t2 + 3<br />

� √ �<br />

2 3a + 1 3a2 + 1<br />

(x0, y0) = ,<br />

4a 4a<br />

(3.12)<br />

(3.13)<br />

is on the curve, if 3a 2 + 1 = 4(t 4 + 3)/(t 2 + 3) 2 is a rational square, which can be<br />

obta<strong>in</strong>ed by t 2 = (u 2 − 12)/4u with u 2 − 12u be<strong>in</strong>g a rational square.<br />

First Phase of the ECM If the triple (P, mP, (m + 1)P ) is given <strong>in</strong> the Mont-<br />

gomery form, we can compute (P, 2mP, (2m + 1)P ) or (P, (2m + 1)P, (2m + 2)P )<br />

by perform<strong>in</strong>g one addition (follow<strong>in</strong>g the Equations 3.9) and one doubl<strong>in</strong>g (follow-<br />

<strong>in</strong>g the Equations 3.10) <strong>in</strong> <strong>Montgomery</strong>’s form. Thus, Q = kP can be calculated<br />

52

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!