diff options
author | Werner Koch <wk@gnupg.org> | 2013-11-05 17:25:02 +0100 |
---|---|---|
committer | Werner Koch <wk@gnupg.org> | 2013-11-05 17:26:52 +0100 |
commit | f09ffe8a4802af65a116e79eceeb1cb4ed4fa2f4 (patch) | |
tree | 294ee667a0c27bd20c333eab4fb69bb04b8c8de3 /src/ec-context.h | |
parent | 630aca794ddf057fb7265b7dc346374743036af4 (diff) | |
download | libgcrypt-f09ffe8a4802af65a116e79eceeb1cb4ed4fa2f4.tar.gz |
ecc: Fully implement Ed25519 compression in ECDSA mode.
* src/ec-context.h (mpi_ec_ctx_s): Add field FLAGS.
* mpi/ec.c (ec_p_init): Add arg FLAGS. Change all callers to pass it.
* cipher/ecc-curves.c (point_from_keyparam): Add arg EC, parse as
opaque mpi and use eddsa decoding depending on the flag.
(_gcry_mpi_ec_new): Rearrange to parse Q and D after knowing the
curve.
Signed-off-by: Werner Koch <wk@gnupg.org>
Diffstat (limited to 'src/ec-context.h')
-rw-r--r-- | src/ec-context.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/ec-context.h b/src/ec-context.h index a118608e..60ca7590 100644 --- a/src/ec-context.h +++ b/src/ec-context.h @@ -27,6 +27,8 @@ struct mpi_ec_ctx_s enum ecc_dialects dialect; /* The ECC dialect used with the curve. */ + int flags; /* Public key flags (not always used). */ + unsigned int nbits; /* Number of bits. */ /* Domain parameters. Note that they may not all be set and if set |