arnaucube
arnaucube/ark-curves-cherry-pickedPublic Self-hosted repository
ark-curves-cherry-picked/ed_on_mnt4_753/src/lib.rs
ed_on_mnt4_753/src/lib.rsRaw
 1#![cfg_attr(not(feature = "std"), no_std)]
 2#![deny(
 3    warnings,
 4    unused,
 5    future_incompatible,
 6    nonstandard_style,
 7    rust_2018_idioms
 8)]
 9#![forbid(unsafe_code)]
10
11//! This library implements a twisted Edwards curve whose base field is the
12//! scalar field of the curve MNT4-753. This allows defining cryptographic
13//! primitives that use elliptic curves over the scalar field of the latter
14//! curve.
15//!
16//! Curve information:
17//! * Base field: q = 41898490967918953402344214791240637128170709919953949071783502921025352812571106773058893763790338921418070971888458477323173057491593855069696241854796396165721416325350064441470418137846398469611935719059908164220784476160001
18//! * Scalar field: r = 5237311370989869175293026848905079641021338739994243633972937865128169101571388346632361720473792365177258871486054600656048925740061347509722287043067341250552640264308621296888446513816907173362124418513727200975392177480577
19//! * Valuation(q - 1, 2) = 30
20//! * Valuation(r - 1, 2) = 7
21//! * Curve equation: ax^2 + y^2 =1 + dx^2y^2, where
22//!    * a = -1
23//!    * d = 317690 mod q
24
25#[cfg(feature = "r1cs")]
26pub mod constraints;
27mod curves;
28mod fields;
29
30pub use curves::*;
31pub use fields::*;