diff --git a/source/org/jivesoftware/smack/SSLXMPPConnection.java b/source/org/jivesoftware/smack/SSLXMPPConnection.java index 76e540e23..33c8d883f 100644 --- a/source/org/jivesoftware/smack/SSLXMPPConnection.java +++ b/source/org/jivesoftware/smack/SSLXMPPConnection.java @@ -120,6 +120,10 @@ public class SSLXMPPConnection extends XMPPConnection { super.init(); } + public boolean isSecureConnection() { + return true; + } + /** * An SSL socket factory that will let any certifacte past, even if it's expired or * not singed by a root CA. diff --git a/source/org/jivesoftware/smack/XMPPConnection.java b/source/org/jivesoftware/smack/XMPPConnection.java index 9586056c0..f88f8eebe 100644 --- a/source/org/jivesoftware/smack/XMPPConnection.java +++ b/source/org/jivesoftware/smack/XMPPConnection.java @@ -483,6 +483,15 @@ public class XMPPConnection { return connected; } + /** + * Returns true if the connection is a secured one, such as an SSL connection. + * + * @return true if a secure connection to the server. + */ + public boolean isSecureConnection() { + return false; + } + /** * Returns true if currently authenticated by successfully calling the login method. *