diff options
author | Mark Haines <mjark@negativecurvature.net> | 2015-02-26 16:30:19 +0000 |
---|---|---|
committer | Mark Haines <mjark@negativecurvature.net> | 2015-02-26 16:30:19 +0000 |
commit | 09d8e84c7cbbf21195f3fd2eabbcff44042d5a4e (patch) | |
tree | 73a1f072bf86175c266579089fecb21e83d1d22c /tests/test_crypto.cpp | |
parent | 186df91246cc61febb398383e4e742973fc9aaf0 (diff) |
Implement the axlotl ratchet
Diffstat (limited to 'tests/test_crypto.cpp')
-rw-r--r-- | tests/test_crypto.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/test_crypto.cpp b/tests/test_crypto.cpp index 1838132..1b9947b 100644 --- a/tests/test_crypto.cpp +++ b/tests/test_crypto.cpp @@ -44,12 +44,14 @@ std::uint8_t expected_agreement[32] = { 0x76, 0xF0, 0x9B, 0x3C, 0x1E, 0x16, 0x17, 0x42 }; -axolotl::Curve25519KeyPair alice_pair = axolotl::generate_key(alice_private); +axolotl::Curve25519KeyPair alice_pair; +axolotl::generate_key(alice_private, alice_pair); assert_equals(alice_private, alice_pair.private_key, 32); assert_equals(alice_public, alice_pair.public_key, 32); -axolotl::Curve25519KeyPair bob_pair = axolotl::generate_key(bob_private); +axolotl::Curve25519KeyPair bob_pair; +axolotl::generate_key(bob_private, bob_pair); assert_equals(bob_private, bob_pair.private_key, 32); assert_equals(bob_public, bob_pair.public_key, 32); |