- wrote diffie_hellman_t but not tested

This commit is contained in:
Jan Hutter
2005-11-18 08:19:12 +00:00
parent d768cb6790
commit 99400f979e
4 changed files with 515 additions and 0 deletions
+1
View File
@@ -130,6 +130,7 @@ static status_t init_prime (private_gmp_helper_t *this, mpz_t *prime, int bytes)
allocator_free(random_bytes.ptr);
random_bytes.ptr = NULL;
/* composites are possible but should never occur */
mpz_nextprime (*(prime),*(prime));
return SUCCESS;
+2
View File
@@ -53,6 +53,8 @@ struct gmp_helper_s {
status_t (*init_prime) (gmp_helper_t *this, mpz_t *var, int bytes);
/* Convert network form (binary bytes, big-endian) to mpz_t of gmp library.
*
* mpz_t gets initialized in this function.
*
* @param this calling private_gmp_helper_t object
* @param mpz_value pointer to a mpz_t value