aboutsummaryrefslogtreecommitdiffstats
path: root/src/exception.cpp
diff options
context:
space:
mode:
authorVincent Richard <[email protected]>2005-10-03 21:29:04 +0000
committerVincent Richard <[email protected]>2005-10-03 21:29:04 +0000
commit7d2d25da3eb891a70ec5dfd3b077b0e130571472 (patch)
tree44b1930480276fe83b6f94ecda308e5a9ceb3162 /src/exception.cpp
parentReduced waiting time. (diff)
downloadvmime-7d2d25da3eb891a70ec5dfd3b077b0e130571472.tar.gz
vmime-7d2d25da3eb891a70ec5dfd3b077b0e130571472.zip
Added TLS/SSL support.
Diffstat (limited to 'src/exception.cpp')
-rw-r--r--src/exception.cpp54
1 files changed, 54 insertions, 0 deletions
diff --git a/src/exception.cpp b/src/exception.cpp
index f2106e89..9620a310 100644
--- a/src/exception.cpp
+++ b/src/exception.cpp
@@ -719,6 +719,60 @@ const char* no_auth_information::name() const throw() { return "no_auth_informat
#endif // VMIME_HAVE_SASL_SUPPORT
+#if VMIME_HAVE_TLS_SUPPORT
+
+
+//
+// tls_exception
+//
+
+tls_exception::~tls_exception() throw() {}
+tls_exception::tls_exception(const string& what, const exception& other)
+ : exception(what, other) {}
+
+exception* tls_exception::clone() const { return new tls_exception(*this); }
+const char* tls_exception::name() const throw() { return "tls_exception"; }
+
+
+//
+// certificate_exception
+//
+
+certificate_exception::~certificate_exception() throw() {}
+certificate_exception::certificate_exception(const string& what, const exception& other)
+ : tls_exception(what, other) {}
+
+exception* certificate_exception::clone() const { return new certificate_exception(*this); }
+const char* certificate_exception::name() const throw() { return "certificate_exception"; }
+
+
+//
+// certificate_verification_exception
+//
+
+certificate_verification_exception::~certificate_verification_exception() throw() {}
+certificate_verification_exception::certificate_verification_exception(const string& what, const exception& other)
+ : certificate_exception(what, other) {}
+
+exception* certificate_verification_exception::clone() const { return new certificate_verification_exception(*this); }
+const char* certificate_verification_exception::name() const throw() { return "certificate_verification_exception"; }
+
+
+//
+// unsupported_certificate_type
+//
+
+unsupported_certificate_type::~unsupported_certificate_type() throw() {}
+unsupported_certificate_type::unsupported_certificate_type(const string& type, const exception& other)
+ : certificate_exception("Unsupported certificate type: '" + type + "'", other) {}
+
+exception* unsupported_certificate_type::clone() const { return new unsupported_certificate_type(*this); }
+const char* unsupported_certificate_type::name() const throw() { return "unsupported_certificate_type"; }
+
+
+#endif // VMIME_HAVE_TLS_SUPPORT
+
+
} // exceptions