Skip to content
Snippets Groups Projects
Commit 05a1dae0 authored by Charles Wright's avatar Charles Wright
Browse files

More detailed debug output for computing the shared secret key

parent 6c9891eb
No related branches found
No related tags found
No related merge requests found
......@@ -385,6 +385,8 @@ bsspeke_client_derive_shared_key(const uint8_t B[32],
{
// Compute the two Diffie-Hellman shared secrets
debug(LOG_DEBUG, "Computing Diffie-Hellman shared secrets");
print_point("A", client->A);
print_point("B", B);
// DH shared secret from a * B
uint8_t a_B[32];
crypto_x25519(a_B, client->a, B);
......@@ -441,6 +443,8 @@ bsspeke_server_derive_shared_key(const uint8_t A[32],
debug(LOG_DEBUG, "Computing Diffie-Hellman shared secrets");
// DH shared secret from b * A
uint8_t b_A[32];
print_point("A", A);
print_point("B", server->B);
crypto_x25519(b_A, server->b, A);
print_point("b * A", b_A);
// DH shared secret from b * V
......
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