#cryptography #finite-fields #elliptic-curves

ark-ed-on-bn254

A Twisted Edwards curve defined over the scalar field of the BN254 curve

5 unstable releases

0.4.0 Jan 17, 2023
0.4.0-alpha.2 Dec 28, 2022
0.4.0-alpha.1 Nov 29, 2022
0.3.0 Jun 6, 2021
0.2.0 Mar 25, 2021

#1063 in Cryptography

Download history 874/week @ 2022-10-08 658/week @ 2022-10-15 830/week @ 2022-10-22 1018/week @ 2022-10-29 467/week @ 2022-11-05 618/week @ 2022-11-12 450/week @ 2022-11-19 2029/week @ 2022-11-26 1164/week @ 2022-12-03 812/week @ 2022-12-10 1427/week @ 2022-12-17 460/week @ 2022-12-24 502/week @ 2022-12-31 1485/week @ 2023-01-07 946/week @ 2023-01-14 1995/week @ 2023-01-21

4,970 downloads per month
Used in fewer than 8 crates

MIT/Apache

43KB
911 lines

This library implements a twisted Edwards curve whose base field is the scalar field of the curve BN254. This allows defining cryptographic primitives that use elliptic curves over the scalar field of the latter curve. This curve is also known as Baby-Jubjub.

Curve information:

  • Base field: q = 21888242871839275222246405745257275088548364400416034343698204186575808495617
  • Scalar field: r = 2736030358979909402780800718157159386076813972158567259200215660948447373041
  • Valuation(q - 1, 2) = 28
  • Valuation(r - 1, 2) = 4
  • Curve equation: ax^2 + y^2 =1 + dx^2y^2, where
    • a = 1
    • d = 168696/168700 mod q = 9706598848417545097372247223557719406784115219466060233080913168975159366771

Dependencies

~4MB
~84K SLoC