aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/tls/tls_heartbeats.h
diff options
context:
space:
mode:
authorlloyd <[email protected]>2015-01-07 13:05:20 +0000
committerlloyd <[email protected]>2015-01-07 13:05:20 +0000
commitbb1228d8a9e6f823f4875a1f6bafa9726ef506ae (patch)
treedee0b5414eb8eb7d29b85768cf22c54b78e34a31 /src/lib/tls/tls_heartbeats.h
parent5fd3c7adffa9fe705e493f81def04d9d57db4442 (diff)
Support setting the number of pad bytes in a heartbeat message. Use
random instead of all-zero padding. Check on sanity of received pads to the extent possible. Bugzilla 269.
Diffstat (limited to 'src/lib/tls/tls_heartbeats.h')
-rw-r--r--src/lib/tls/tls_heartbeats.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/lib/tls/tls_heartbeats.h b/src/lib/tls/tls_heartbeats.h
index 00b197089..c17c5606f 100644
--- a/src/lib/tls/tls_heartbeats.h
+++ b/src/lib/tls/tls_heartbeats.h
@@ -1,6 +1,6 @@
/*
* TLS Heartbeats
-* (C) 2012 Jack Lloyd
+* (C) 2012,2015 Jack Lloyd
*
* Released under the terms of the Botan license
*/
@@ -30,10 +30,11 @@ class Heartbeat_Message
Heartbeat_Message(const std::vector<byte>& buf);
- Heartbeat_Message(Type type, const byte payload[], size_t payload_len);
+ Heartbeat_Message(Type type, const byte payload[], size_t payload_len,
+ const std::vector<byte>& padding);
private:
Type m_type;
- std::vector<byte> m_payload;
+ std::vector<byte> m_payload, m_padding;
};
}