1
mirror of https://github.com/jedisct1/libsodium.git synced 2024-12-19 18:15:18 -07:00

Consistent indentation

This commit is contained in:
Frank Denis 2016-03-09 15:34:32 +01:00
parent 62911edb7f
commit 7c5d30a6a3
2 changed files with 1736 additions and 1727 deletions

File diff suppressed because it is too large Load Diff

View File

@ -8,12 +8,12 @@
typedef int32_t fe[10];
/*
fe means field element.
Here the field is \Z/(2^255-19).
An element t, entries t[0]...t[9], represents the integer
t[0]+2^26 t[1]+2^51 t[2]+2^77 t[3]+2^102 t[4]+...+2^230 t[9].
Bounds on each t[i] vary depending on context.
*/
fe means field element.
Here the field is \Z/(2^255-19).
An element t, entries t[0]...t[9], represents the integer
t[0]+2^26 t[1]+2^51 t[2]+2^77 t[3]+2^102 t[4]+...+2^230 t[9].
Bounds on each t[i] vary depending on context.
*/
#define fe_frombytes crypto_core_curve25519_ref10_fe_frombytes
#define fe_tobytes crypto_core_curve25519_ref10_fe_tobytes
@ -51,55 +51,55 @@ extern void fe_invert(fe,const fe);
extern void fe_pow22523(fe,const fe);
/*
ge means group element.
Here the group is the set of pairs (x,y) of field elements (see fe.h)
satisfying -x^2 + y^2 = 1 + d x^2y^2
where d = -121665/121666.
Representations:
ge_p2 (projective): (X:Y:Z) satisfying x=X/Z, y=Y/Z
ge_p3 (extended): (X:Y:Z:T) satisfying x=X/Z, y=Y/Z, XY=ZT
ge_p1p1 (completed): ((X:Z),(Y:T)) satisfying x=X/Z, y=Y/T
ge_precomp (Duif): (y+x,y-x,2dxy)
*/
ge means group element.
*
Here the group is the set of pairs (x,y) of field elements (see fe.h)
satisfying -x^2 + y^2 = 1 + d x^2y^2
where d = -121665/121666.
*
Representations:
ge_p2 (projective): (X:Y:Z) satisfying x=X/Z, y=Y/Z
ge_p3 (extended): (X:Y:Z:T) satisfying x=X/Z, y=Y/Z, XY=ZT
ge_p1p1 (completed): ((X:Z),(Y:T)) satisfying x=X/Z, y=Y/T
ge_precomp (Duif): (y+x,y-x,2dxy)
*/
#define ge_p2 crypto_core_curve25519_ref10_ge_p2
typedef struct {
fe X;
fe Y;
fe Z;
fe X;
fe Y;
fe Z;
} ge_p2;
#define ge_p3 crypto_core_curve25519_ref10_ge_p3
typedef struct {
fe X;
fe Y;
fe Z;
fe T;
fe X;
fe Y;
fe Z;
fe T;
} ge_p3;
#define ge_p1p1 crypto_core_curve25519_ref10_ge_p1p1
typedef struct {
fe X;
fe Y;
fe Z;
fe T;
fe X;
fe Y;
fe Z;
fe T;
} ge_p1p1;
#define ge_precomp crypto_core_curve25519_ref10_ge_precomp
typedef struct {
fe yplusx;
fe yminusx;
fe xy2d;
fe yplusx;
fe yminusx;
fe xy2d;
} ge_precomp;
#define ge_cached crypto_core_curve25519_ref10_ge_cached
typedef struct {
fe YplusX;
fe YminusX;
fe Z;
fe T2d;
fe YplusX;
fe YminusX;
fe Z;
fe T2d;
} ge_cached;
#define ge_frombytes_negate_vartime crypto_core_curve25519_ref10_ge_frombytes_negate_vartime
@ -147,9 +147,9 @@ extern void ge_double_scalarmult_vartime(ge_p2 *,const unsigned char *,const ge_
extern void ge_scalarmult_vartime(ge_p3 *,const unsigned char *,const ge_p3 *);
/*
The set of scalars is \Z/l
where l = 2^252 + 27742317777372353535851937790883648493.
*/
The set of scalars is \Z/l
where l = 2^252 + 27742317777372353535851937790883648493.
*/
#define sc_reduce crypto_core_curve25519_ref10_sc_reduce
#define sc_muladd crypto_core_curve25519_ref10_sc_muladd