aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorlloyd <[email protected]>2012-03-02 02:03:17 +0000
committerlloyd <[email protected]>2012-03-02 02:03:17 +0000
commit03ff8576e98e22aef25439d991c3fd8a1db71237 (patch)
treec1d2f29875e3029a3f674af8077246ca508994e6 /src
parent92883d3d593479eb2307eb0696f1161f4fec28fc (diff)
Move min_version and pref_version to the source file so they can be
overridden easily in a new release without changing binaries linked against an earlier version.
Diffstat (limited to 'src')
-rw-r--r--src/tls/tls_policy.cpp10
-rw-r--r--src/tls/tls_policy.h6
2 files changed, 12 insertions, 4 deletions
diff --git a/src/tls/tls_policy.cpp b/src/tls/tls_policy.cpp
index 49f74975b..1ab55f7c6 100644
--- a/src/tls/tls_policy.cpp
+++ b/src/tls/tls_policy.cpp
@@ -89,6 +89,16 @@ std::vector<std::string> Policy::allowed_ecc_curves() const
return curves;
}
+Protocol_Version Policy::min_version() const
+ {
+ return Protocol_Version::SSL_V3;
+ }
+
+Protocol_Version Policy::pref_version() const
+ {
+ return Protocol_Version::TLS_V12;
+ }
+
namespace {
class Ciphersuite_Preference_Ordering
diff --git a/src/tls/tls_policy.h b/src/tls/tls_policy.h
index cd00331a5..f53b9bab6 100644
--- a/src/tls/tls_policy.h
+++ b/src/tls/tls_policy.h
@@ -97,14 +97,12 @@ class BOTAN_DLL Policy
/**
* @return the minimum version that we are willing to negotiate
*/
- virtual Protocol_Version min_version() const
- { return Protocol_Version::SSL_V3; }
+ virtual Protocol_Version min_version() const;
/**
* @return the version we would prefer to negotiate
*/
- virtual Protocol_Version pref_version() const
- { return Protocol_Version::TLS_V12; }
+ virtual Protocol_Version pref_version() const;
/**
* Return allowed ciphersuites, in order of preference