diff options
author | lloyd <[email protected]> | 2012-07-28 19:35:09 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2012-07-28 19:35:09 +0000 |
commit | 9e52358bb627c68d0e8c94a2a12d5e46aa6376d3 (patch) | |
tree | 45a0236bb019c9f46552006574f0fbfb983da35a /src/tls/tls_handshake_hash.h | |
parent | 4d0008edca9d3c0a119518e7d9b49c81d7dbe33c (diff) |
Add format() hook to Handshake_Writer, so that Handshake_Hash does not
need to know what the handshake format is.
Remove unused functions from Handshake_Hash and store all handshake
data as a plain std::vector, since as handshake information it is not
sensitive.
Diffstat (limited to 'src/tls/tls_handshake_hash.h')
-rw-r--r-- | src/tls/tls_handshake_hash.h | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/src/tls/tls_handshake_hash.h b/src/tls/tls_handshake_hash.h index 02943977f..bf6c8ff8b 100644 --- a/src/tls/tls_handshake_hash.h +++ b/src/tls/tls_handshake_hash.h @@ -1,6 +1,6 @@ /* * TLS Handshake Hash -* (C) 2004-2006,2011 Jack Lloyd +* (C) 2004-2006,2011,2012 Jack Lloyd * * Released under the terms of the Botan license */ @@ -27,28 +27,19 @@ class Handshake_Hash void update(const byte in[], size_t length) { data += std::make_pair(in, length); } - void update(const secure_vector<byte>& in) - { data += in; } - void update(const std::vector<byte>& in) { data += in; } - void update(byte in) - { data.push_back(in); } - - void update(Handshake_Type handshake_type, - const std::vector<byte>& handshake_msg); - secure_vector<byte> final(Protocol_Version version, const std::string& mac_algo); secure_vector<byte> final_ssl3(const secure_vector<byte>& master_secret); - const secure_vector<byte>& get_contents() const + const std::vector<byte>& get_contents() const { return data; } private: - secure_vector<byte> data; + std::vector<byte> data; }; } |