aboutsummaryrefslogtreecommitdiff
path: root/src/ratchet.cpp
diff options
context:
space:
mode:
authorMark Haines <mark.haines@matrix.org>2015-06-12 14:09:41 +0100
committerMark Haines <mark.haines@matrix.org>2015-06-12 14:09:41 +0100
commit6ecea67718803e96e00a18f97ae8abc83ecaa1c2 (patch)
tree41de34500c1dfa104b791606a67b6bcf84a14ed9 /src/ratchet.cpp
parent08a7e44a966047a10d7e959d4a8cdeaaf4139ce0 (diff)
Implement the session key exchange
Diffstat (limited to 'src/ratchet.cpp')
-rw-r--r--src/ratchet.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/ratchet.cpp b/src/ratchet.cpp
index 91e5ce6..87d79b7 100644
--- a/src/ratchet.cpp
+++ b/src/ratchet.cpp
@@ -184,7 +184,7 @@ void axolotl::Ratchet::initialise_as_bob(
std::uint8_t derived_secrets[64];
axolotl::hkdf_sha256(
shared_secret, shared_secret_length,
- NULL, 0,
+ nullptr, 0,
kdf_info.root_info, kdf_info.root_info_length,
derived_secrets, sizeof(derived_secrets)
);
@@ -203,7 +203,7 @@ void axolotl::Ratchet::initialise_as_alice(
std::uint8_t derived_secrets[64];
axolotl::hkdf_sha256(
shared_secret, shared_secret_length,
- NULL, 0,
+ nullptr, 0,
kdf_info.root_info, kdf_info.root_info_length,
derived_secrets, sizeof(derived_secrets)
);
@@ -477,7 +477,7 @@ std::size_t axolotl::Ratchet::decrypt(
return std::size_t(-1);
}
- ReceiverChain * chain = NULL;
+ ReceiverChain * chain = nullptr;
for (axolotl::ReceiverChain & receiver_chain : receiver_chains) {
if (0 == std::memcmp(
receiver_chain.ratchet_key.public_key, reader.ratchet_key,