aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/tls/tls_messages.h
diff options
context:
space:
mode:
authorRenĂ© Korthaus <[email protected]>2016-09-28 13:06:36 +0200
committerRenĂ© Korthaus <[email protected]>2016-10-03 12:18:24 +0200
commitf38841305ecd3fd0d13285823497a5a9d3b5c19f (patch)
treed01a3263baa7df488cf58fc997d1c9710dbfb0a4 /src/lib/tls/tls_messages.h
parentab2842d6f28680b1cac18d5ff6b70b395d1ffb65 (diff)
Support encoding of supported point formats extension
Diffstat (limited to 'src/lib/tls/tls_messages.h')
-rw-r--r--src/lib/tls/tls_messages.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/lib/tls/tls_messages.h b/src/lib/tls/tls_messages.h
index 698dbc99f..25228c865 100644
--- a/src/lib/tls/tls_messages.h
+++ b/src/lib/tls/tls_messages.h
@@ -121,6 +121,15 @@ class BOTAN_DLL Client_Hello final : public Handshake_Message
return std::vector<std::string>();
}
+ bool prefers_compressed_ec_points() const
+ {
+ if(Supported_Point_Formats* ecc_formats = m_extensions.get<Supported_Point_Formats>())
+ {
+ return ecc_formats->prefers_compressed();
+ }
+ return false;
+ }
+
std::string sni_hostname() const
{
if(Server_Name_Indicator* sni = m_extensions.get<Server_Name_Indicator>())
@@ -328,6 +337,15 @@ class BOTAN_DLL Server_Hello final : public Handshake_Message
std::set<Handshake_Extension_Type> extension_types() const
{ return m_extensions.extension_types(); }
+ bool prefers_compressed_ec_points() const
+ {
+ if(auto ecc_formats = m_extensions.get<Supported_Point_Formats>())
+ {
+ return ecc_formats->prefers_compressed();
+ }
+ return false;
+ }
+
Server_Hello(Handshake_IO& io,
Handshake_Hash& hash,
const Policy& policy,