changed WHY2_CHAT_RSA_EXPONENT datatype to string

This commit is contained in:
Václav Šmejkal 2024-04-13 13:33:49 +02:00
parent 6487ea8b85
commit b74995bbab
Signed by: ENGO150
GPG Key ID: 4A57E86482968843
2 changed files with 2 additions and 2 deletions

View File

@ -28,7 +28,7 @@ extern "C" {
//MACROS //MACROS
#define WHY2_CHAT_KEY_BITS 4096 //BITS.. #define WHY2_CHAT_KEY_BITS 4096 //BITS..
#define WHY2_CHAT_PRIME_ITERS 100 //NUMBER OF ITERATIONS WHEN CHECKING PRIME NUMBER #define WHY2_CHAT_PRIME_ITERS 100 //NUMBER OF ITERATIONS WHEN CHECKING PRIME NUMBER
#define WHY2_CHAT_RSA_EXPONENT 65537 //DEFAULT e #define WHY2_CHAT_RSA_EXPONENT "65537" //DEFAULT e
#define WHY2_CHAT_KEY_LOCATION WHY2_CHAT_CONFIG_DIR "/keys" //KEYS LOCATION #define WHY2_CHAT_KEY_LOCATION WHY2_CHAT_CONFIG_DIR "/keys" //KEYS LOCATION
#define WHY2_CHAT_PUB_KEY "pub" #define WHY2_CHAT_PUB_KEY "pub"

View File

@ -111,7 +111,7 @@ void why2_chat_init_keys(void)
generate_prime(q); generate_prime(q);
//SET e //SET e
mpz_set_ui(e, WHY2_CHAT_RSA_EXPONENT); mpz_set_str(e, WHY2_CHAT_RSA_EXPONENT, 10);
//GET n //GET n
mpz_mul(n, p, q); mpz_mul(n, p, q);