SSLXMPPConnection lock

I am having problems with the SSLXMPPConnection locking up when using the “normal” port (i.e. 5222 rather than 5223). Obviously this should either fail or warn the user that the connection is not secure but the call to create a new SSLXMPPConnection never returns. Is there a workaround for this situation? Is there a way to test the port to determine if it is “normal” or SSL in advance of creating a connection?

Thanks

Hi,

as far as I understand SSLXMPPConnection is used to use the old SSL method and not TLS. Old SSL uses port 5223, I have no idea how to configure Smack to use unencrypted XMPPConnections.

Is the place where the lock occurs? I use eclipse and the debug mode - after a while I press Suspend:

BufferedReader.close() line: na

SSLXMPPCOnnection(XMPPConnection).init() line: 891

if (reader != null) {

try {

reader.close(); // this one locks

} catch (Throwable ignore) { /* ignore */ }

reader = null;

}

/code

Sometimes it does not block, or only for a minute.

Could a blocking close() be a java bug or is this normal?

LG

I am not sure exactly where it locks as I do not have the Smack source code. I am using the jar. I do believe that may be the place where it locks as I can see a Reader and Writer thread when I debug through IntelliJ. When I break the thread is always in some core Java SSL code which I also do not have the source to. Every time it has locked for me it has never unlocked even after 30+ minutes.

Hi,

the source code is available here: http://www.jivesoftware.org/source.jsp if you want to use it instead of the jar.

LG