diff options
author | Niels Möller <nisse@lysator.liu.se> | 2002-10-09 23:13:59 +0200 |
---|---|---|
committer | Niels Möller <nisse@lysator.liu.se> | 2002-10-09 23:13:59 +0200 |
commit | 7fc02e4a9382862e9008200ae3b509f8aef2304b (patch) | |
tree | 6e87e7d5af3d9f9c52b4db1f306ae98a38f8ca87 /dsa.h | |
parent | 21376b08209b4cd1d5892b184fb1a36eb0b18168 (diff) | |
download | nettle-7fc02e4a9382862e9008200ae3b509f8aef2304b.tar.gz |
* dsa.h (DSA_MINIMUM_BITS): New constant.
Rev: src/nettle/dsa.h:1.3
Diffstat (limited to 'dsa.h')
-rw-r--r-- | dsa.h | 25 |
1 files changed, 5 insertions, 20 deletions
@@ -34,6 +34,7 @@ /* For nettle_random_func */ #include "nettle-meta.h" +#define DSA_MINIMUM_BITS 512 struct dsa_public_key { @@ -127,8 +128,6 @@ dsa_verify(const struct dsa_public_key *key, /* Key generation */ -#if 0 -/* Note that the key structs must be initialized first. */ int dsa_generate_keypair(struct dsa_public_key *pub, struct dsa_private_key *key, @@ -136,23 +135,9 @@ dsa_generate_keypair(struct dsa_public_key *pub, void *random_ctx, nettle_random_func random, void *progress_ctx, nettle_progress_func progress, - /* Desired size of modulo, in bits */ - unsigned n_size, - - /* Desired size of public exponent, in bits. If - * zero, the passed in value pub->e is used. */ - unsigned e_size); - - -#define DSA_SIGN(key, algorithm, ctx, length, data, signature) ( \ - algorithm##_update(ctx, length, data), \ - dsa_##algorithm##_sign(key, ctx, signature) \ -) - -#define DSA_VERIFY(key, algorithm, ctx, length, data, signature) ( \ - algorithm##_update(ctx, length, data), \ - dsa_##algorithm##_verify(key, ctx, signature) \ -) -#endif + /* Size of key, in bits. + * Use size = 512 + 64 * l for the official + * NIS key sizes. */ + unsigned bits); #endif /* NETTLE_DSA_H_INCLUDED */ |