diff options
author | lloyd <[email protected]> | 2012-01-23 21:51:18 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2012-01-23 21:51:18 +0000 |
commit | 01039638f8b5387540c4bacd4d236a8b8e806d0f (patch) | |
tree | 4aada3b77da95061b8a6778b23afbd3569696392 /src/tls/tls_session.h | |
parent | a12a50cc0eaf5113d2f0687f4c1d4be5ff820838 (diff) |
Add Ciphersuite::to_string
Add a convenience function to Session that returns the ciphersuite
class since mostly users won't care about the underlying code point.
Diffstat (limited to 'src/tls/tls_session.h')
-rw-r--r-- | src/tls/tls_session.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/tls/tls_session.h b/src/tls/tls_session.h index e44967c00..96ef6514e 100644 --- a/src/tls/tls_session.h +++ b/src/tls/tls_session.h @@ -10,6 +10,7 @@ #include <botan/x509cert.h> #include <botan/tls_version.h> +#include <botan/tls_suites.h> #include <botan/tls_magic.h> #include <botan/secmem.h> @@ -70,9 +71,14 @@ class BOTAN_DLL Session Protocol_Version version() const { return m_version; } /** - * Get the ciphersuite of the saved session + * Get the ciphersuite code of the saved session */ - u16bit ciphersuite() const { return m_ciphersuite; } + u16bit ciphersuite_code() const { return m_ciphersuite; } + + /** + * Get the ciphersuite info of the saved session + */ + Ciphersuite ciphersuite() const { return Ciphersuite::lookup_ciphersuite(m_ciphersuite); } /** * Get the compression method used in the saved session |