aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/tls/tls_record.h
diff options
context:
space:
mode:
authorJack Lloyd <[email protected]>2019-07-04 15:13:45 -0400
committerJack Lloyd <[email protected]>2019-07-04 15:13:45 -0400
commit24ef3c3bea9aaaf1fa0d50b57250b17552ee6949 (patch)
tree96f68bb38c6a487b0f1b0e14601c3fe93599df54 /src/lib/tls/tls_record.h
parentae37dd372bb7ccd9afb25866ecededa4de10a36a (diff)
Remove Record_Raw_Input
Diffstat (limited to 'src/lib/tls/tls_record.h')
-rw-r--r--src/lib/tls/tls_record.h32
1 files changed, 5 insertions, 27 deletions
diff --git a/src/lib/tls/tls_record.h b/src/lib/tls/tls_record.h
index 3a29164b5..e3eab5239 100644
--- a/src/lib/tls/tls_record.h
+++ b/src/lib/tls/tls_record.h
@@ -105,31 +105,6 @@ class Record final
size_t m_size;
};
-class Record_Raw_Input final
- {
- public:
- Record_Raw_Input(const uint8_t* data, size_t size, size_t& consumed,
- bool is_datagram)
- : m_data(data), m_size(size), m_consumed(consumed),
- m_is_datagram(is_datagram) {}
-
- const uint8_t*& get_data() { return m_data; }
-
- size_t& get_size() { return m_size; }
-
- size_t& get_consumed() { return m_consumed; }
- void set_consumed(size_t consumed) { m_consumed = consumed; }
-
- bool is_datagram() { return m_is_datagram; }
-
- private:
- const uint8_t* m_data;
- size_t m_size;
- size_t& m_consumed;
- bool m_is_datagram;
- };
-
-
/**
* Create a TLS record
* @param write_buffer the output record is placed here
@@ -157,8 +132,11 @@ typedef std::function<std::shared_ptr<Connection_Cipher_State> (uint16_t)> get_c
* Decode a TLS record
* @return zero if full message, else number of bytes still needed
*/
-size_t read_record(secure_vector<uint8_t>& read_buffer,
- Record_Raw_Input& raw_input,
+size_t read_record(bool is_datagram,
+ secure_vector<uint8_t>& read_buffer,
+ const uint8_t input[],
+ size_t input_len,
+ size_t& consumed,
Record& rec,
Connection_Sequence_Numbers* sequence_numbers,
get_cipherstate_fn get_cipherstate);