Looking at the log files on the open fire server i found the below exception:
2012.07.10 17:10:52 Closing connection due to error while processing message: <response xmlns="urn:ietf:params:xml:ns:xmpp-sasl">dXNlcm5hbWU9IjExNjgwMDEiLHJlYWxtPSJ4bX BwLXFhLm1pdGNoZWxsLmNvbSIsbm9uY2U9InQ1djhTWTBrYndMQnZKcG9XV2tlVlhGeFJzM3Jqd1NjU2 tSNWJlSUMiLGNub25jZT0iMGVjZjRiMGExNGNhYzRhNjM2OTdlZmUwMWI0OGE1ZjhmMjY0MTM2ZTYwM2 RjMTNlZDA3NmU1NzJhMzg1ZTgyNCIsbmM9MDAwMDAwMDEscW9wPWF1dGgsZGlnZXN0LXVyaT0ieG1wcC 94bXBwLXFhLm1pdGNoZWxsLmNvbSIsY2hhcnNldD11dGYtOCxyZXNwb25zZT1lNWMxMGU2ODM3YTBiY2 M4NTk0ODY4NDZiZmEwODgyZg==</response>
java.lang.NullPointerException
at org.jivesoftware.openfire.net.SASLAuthentication.handle(SASLAuthentication.java :298)
at org.jivesoftware.openfire.net.StanzaHandler.process(StanzaHandler.java:183)
at org.jivesoftware.openfire.nio.ConnectionHandler.messageReceived(ConnectionHandl er.java:169)
at org.apache.mina.common.support.AbstractIoFilterChain$TailFilter.messageReceived (AbstractIoFilterChain.java:570)
at org.apache.mina.common.support.AbstractIoFilterChain.callNextMessageReceived(Ab stractIoFilterChain.java:299)
at org.apache.mina.common.support.AbstractIoFilterChain.access$1100(AbstractIoFilt erChain.java:53)
at org.apache.mina.common.support.AbstractIoFilterChain$EntryImpl$1.messageReceive d(AbstractIoFilterChain.java:648)
at org.apache.mina.common.IoFilterAdapter.messageReceived(IoFilterAdapter.java:80)
at org.apache.mina.common.support.AbstractIoFilterChain.callNextMessageReceived(Ab stractIoFilterChain.java:299)
at org.apache.mina.common.support.AbstractIoFilterChain.access$1100(AbstractIoFilt erChain.java:53)
at org.apache.mina.common.support.AbstractIoFilterChain$EntryImpl$1.messageReceive d(AbstractIoFilterChain.java:648)
at org.apache.mina.filter.codec.support.SimpleProtocolDecoderOutput.flush(SimplePr otocolDecoderOutput.java:58)
at org.apache.mina.filter.codec.ProtocolCodecFilter.messageReceived(ProtocolCodecF ilter.java:185)
at org.apache.mina.common.support.AbstractIoFilterChain.callNextMessageReceived(Ab stractIoFilterChain.java:299)
at org.apache.mina.common.support.AbstractIoFilterChain.access$1100(AbstractIoFilt erChain.java:53)
at org.apache.mina.common.support.AbstractIoFilterChain$EntryImpl$1.messageReceive d(AbstractIoFilterChain.java:648)
at org.apache.mina.filter.executor.ExecutorFilter.processEvent(ExecutorFilter.java :239)
at org.apache.mina.filter.executor.ExecutorFilter$ProcessEventsRunnable.run(Execut orFilter.java:283)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at org.apache.mina.util.NamePreservingRunnable.run(NamePreservingRunnable.java:51)
at java.lang.Thread.run(Unknown Source)
I looked at the source code (SASLAuthentication.java) where the exception is being thrown and figured out that the value for "SaslMechanism" key in the session is returning a null value. Below is the code snippet:
mechanism = (String) session.getSessionData("SaslMechanism");
Above line is from SASLAuthentication.java line no 297 (handle method).
So, I would like to understand what could cause the value to be returned null for the key "SaslMechanism" in the session.
We are using OpenFire Server version 3.7.0
Your help is much appreciated.