673 |
} |
} |
674 |
|
|
675 |
DEBUG(("Generating client random\n")); |
DEBUG(("Generating client random\n")); |
|
/* Generate a client random, and hence determine encryption keys */ |
|
|
generate_random(inr); |
|
676 |
// This is what the MS client do: |
// This is what the MS client do: |
677 |
// memset(inr, 0, SEC_RANDOM_SIZE); |
memset(inr, 0, SEC_RANDOM_SIZE); |
678 |
// *ARIGL!* |
/* *ARIGL!* Plaintext attack, anyone? |
679 |
|
I tried doing: |
680 |
|
generate_random(inr); |
681 |
|
..but that generates connection errors now and then (yes, |
682 |
|
"now and then". Something like 0 to 3 attempts needed before a |
683 |
|
successful connection. Nice. Not! |
684 |
|
*/ |
685 |
|
|
686 |
generate_random(client_random); |
generate_random(client_random); |
687 |
if (NULL != server_public_key) |
if (NULL != server_public_key) |
688 |
{ /* Which means we should use |
{ /* Which means we should use |