Skip to content
Snippets Groups Projects
Commit bf2749fb authored by Niels Möller's avatar Niels Möller
Browse files

* rsa-compat.c: Adapted to new private key struct.

* rsa_md5.c: Likesize.
* rsa_sha1.c: Likesize.

Rev: src/nettle/rsa_md5.c:1.4
Rev: src/nettle/rsa_sha1.c:1.4
parent 917b9d20
No related branches found
No related tags found
No related merge requests found
......@@ -46,9 +46,9 @@ rsa_md5_sign(struct rsa_private_key *key,
struct md5_ctx *hash,
mpz_t s)
{
assert(key->pub.size >= 45);
assert(key->size >= 45);
pkcs1_encode_md5(s, key->pub.size - 1, hash);
pkcs1_encode_md5(s, key->size - 1, hash);
rsa_compute_root(key, s, s);
}
......
......@@ -46,9 +46,9 @@ rsa_sha1_sign(struct rsa_private_key *key,
struct sha1_ctx *hash,
mpz_t s)
{
assert(key->pub.size >= 45);
assert(key->size >= 45);
pkcs1_encode_sha1(s, key->pub.size - 1, hash);
pkcs1_encode_sha1(s, key->size - 1, hash);
rsa_compute_root(key, s, s);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment