diff options
| author | J08nY | 2017-02-19 18:58:26 +0100 |
|---|---|---|
| committer | J08nY | 2017-02-19 18:58:26 +0100 |
| commit | 888ca8052e0eb3acbe33dbf180e3af27341002eb (patch) | |
| tree | 589be6afcec5d8986462911fdf41608c39eba8e3 /src/math/types.h | |
| parent | c1be6dbea0f6e2b8d9cb8c422bc2e1cfb41524da (diff) | |
| download | ecgen-888ca8052e0eb3acbe33dbf180e3af27341002eb.tar.gz ecgen-888ca8052e0eb3acbe33dbf180e3af27341002eb.tar.zst ecgen-888ca8052e0eb3acbe33dbf180e3af27341002eb.zip | |
Added generators
- Added new type of gen_t, essentially only for generators. Since they
are points with a special property.
- Added order_smallfact generator
- Added generators to csv and json output
Diffstat (limited to 'src/math/types.h')
| -rw-r--r-- | src/math/types.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/math/types.h b/src/math/types.h index 575f583..70696ad 100644 --- a/src/math/types.h +++ b/src/math/types.h @@ -16,6 +16,7 @@ typedef struct seed_t { GEN seed; } seed_t; typedef struct point_t { GEN point; GEN order; + GEN cofactor; } point_t; typedef struct curve_t { @@ -25,6 +26,8 @@ typedef struct curve_t { GEN b; GEN curve; GEN order; + point_t **generators; + size_t ngens; point_t **points; size_t npoints; } curve_t; @@ -36,6 +39,7 @@ enum curve_offset { OFFSET_B, OFFSET_CURVE, OFFSET_ORDER, + OFFSET_GENERATORS, OFFSET_POINTS, OFFSET_END }; @@ -45,7 +49,7 @@ typedef struct arg_t { size_t nargs; } arg_t; -typedef int (*gen_t)(curve_t *, config_t *, arg_t *args); +typedef int (*gen_t)(curve_t *, config_t *, arg_t *); int gen_skip(curve_t *curve, config_t *config, arg_t *args); |
