aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/tls/tls_session_key.h
diff options
context:
space:
mode:
authorJack Lloyd <[email protected]>2019-05-24 19:58:52 -0400
committerJack Lloyd <[email protected]>2019-05-24 19:58:52 -0400
commit6ea7db98d8fa394efac32b544d8906b68882d3ed (patch)
treeb2ce267561f0261ed3676a45041dda0f9c81e13b /src/lib/tls/tls_session_key.h
parent1e320e6e5b5edd6680136231db040fa8ad01c311 (diff)
More record layer refactorings
Diffstat (limited to 'src/lib/tls/tls_session_key.h')
-rw-r--r--src/lib/tls/tls_session_key.h32
1 files changed, 11 insertions, 21 deletions
diff --git a/src/lib/tls/tls_session_key.h b/src/lib/tls/tls_session_key.h
index 2c1eac523..5f0ea3a66 100644
--- a/src/lib/tls/tls_session_key.h
+++ b/src/lib/tls/tls_session_key.h
@@ -8,7 +8,7 @@
#ifndef BOTAN_TLS_SESSION_KEYS_H_
#define BOTAN_TLS_SESSION_KEYS_H_
-#include <botan/symkey.h>
+#include <botan/secmem.h>
namespace Botan {
@@ -23,34 +23,24 @@ class Session_Keys final
{
public:
/**
- * @return client encipherment key
+ * @return client AEAD key
*/
- const SymmetricKey& client_cipher_key() const { return m_c_cipher; }
+ const secure_vector<uint8_t>& client_aead_key() const { return m_c_aead; }
/**
- * @return client encipherment key
+ * @return server AEAD key
*/
- const SymmetricKey& server_cipher_key() const { return m_s_cipher; }
+ const secure_vector<uint8_t>& server_aead_key() const { return m_s_aead; }
/**
- * @return client MAC key
+ * @return client nonce
*/
- const SymmetricKey& client_mac_key() const { return m_c_mac; }
+ const std::vector<uint8_t>& client_nonce() const { return m_c_nonce; }
/**
- * @return server MAC key
+ * @return server nonce
*/
- const SymmetricKey& server_mac_key() const { return m_s_mac; }
-
- /**
- * @return client IV
- */
- const InitializationVector& client_iv() const { return m_c_iv; }
-
- /**
- * @return server IV
- */
- const InitializationVector& server_iv() const { return m_s_iv; }
+ const std::vector<uint8_t>& server_nonce() const { return m_s_nonce; }
/**
* @return TLS master secret
@@ -70,8 +60,8 @@ class Session_Keys final
private:
secure_vector<uint8_t> m_master_sec;
- SymmetricKey m_c_cipher, m_s_cipher, m_c_mac, m_s_mac;
- InitializationVector m_c_iv, m_s_iv;
+ secure_vector<uint8_t> m_c_aead, m_s_aead;
+ std::vector<uint8_t> m_c_nonce, m_s_nonce;
};
}