powered by Jive Software

Smack bug 232

Hello,

I think I found something of use for bug232. When attempting to add a contact that has an “@” in it, For example, if you have a federated network foo.com, you can have aim contacts that are testAccount@foo.com. This will cause an error in parsing I believe, because you guys are looking for testAccount@aim.testOpenfireServer.com, but you receive testAccount@foo.com@aim.testOpenfireServer.com. I hope this helps!

I’ll try to get the important part of the log up as quick as possible.

As promised, here are the logs, they are anonymized. Anything surrounded by braces was anonymized.

02:40:31 PM SENT (11814316): <iq id=“VcWh8-57” type=“set”><query

xmlns="jabber:i

q:roster"><item

jid="@.com@.com" name="@.com"><group>BuddiesYJ0</group></item></query></iq > 02:40:31 PM RCV (11814316): <iq type=“error” id=“VcWh8-57” to=“alfa1_aim@.com/Smack”><query xmlns=“jabber:iq:roster”><item jid="@.com@.com" name="@.com"><group>Bud
diesYJ0</group></item></query><error code=“400” type=“modify”><jid-malformed xml
ns=“urn:ietf:params:xml:ns:xmpp-stanzas”/></error></iq> The RCV packet I believe causes the error in the gateway: 2007.10.25 13:55:37 Rejecting packet. JID malformed
java.lang.IllegalArgumentException: Illegal JID: @.com@.com

at

org.xmpp.packet.JID.init(JID.java:384)

at

org.xmpp.packet.JID.<init>(JID.java:259)

at

org.xmpp.packet.Packet.<init>(Packet.java:73)

at

org.xmpp.packet.Presence.<init>(Presence.java:64)

at

org.jivesoftware.openfire.net.StanzaHandler.process(StanzaHandler.java:191)

at

org.jivesoftware.openfire.net.StanzaHandler.process(StanzaHandler.java:153)

at

org.jivesoftware.openfire.nio.ConnectionHandler.messageReceived(ConnectionHandle r.java:132)

at

org.apache.mina.common.support.AbstractIoFilterChain$TailFilter.messageReceived( AbstractIoFilterChain.java:570)

at

org.apache.mina.common.support.AbstractIoFilterChain.callNextMessageReceived(Abs tractIoFilterChain.java:299)

at

org.apache.mina.common.support.AbstractIoFilterChain.access$1100(AbstractIoFilte rChain.java:53)

at

org.apache.mina.common.support.AbstractIoFilterChain$EntryImpl$1.messageReceived (AbstractIoFilterChain.java:648)

at

org.apache.mina.filter.codec.support.SimpleProtocolDecoderOutput.flush(SimplePro tocolDecoderOutput.java:58)

at

org.apache.mina.filter.codec.ProtocolCodecFilter.messageReceived(ProtocolCodecFi lter.java:176)

at

org.apache.mina.common.support.AbstractIoFilterChain.callNextMessageReceived(Abs tractIoFilterChain.java:299)

at

org.apache.mina.common.support.AbstractIoFilterChain.access$1100(AbstractIoFilte rChain.java:53)

at

org.apache.mina.common.support.AbstractIoFilterChain$EntryImpl$1.messageReceived (AbstractIoFilterChain.java:648)

at

org.apache.mina.filter.executor.ExecutorFilter.processEvent(ExecutorFilter.java: 239)

at

org.apache.mina.filter.executor.ExecutorFilter$ProcessEventsRunnable.run(Executo rFilter.java:283)

at

java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:8 85)

at

java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)

at

java.lang.Thread.run(Thread.java:619)

Caused by:

org.jivesoftware.stringprep.IDNAException: Contains non-LDH characters.

at

org.jivesoftware.stringprep.IDNA.toASCII(IDNA.java:106)

at

org.jivesoftware.stringprep.IDNA.toASCII(IDNA.java:46)

at

org.xmpp.packet.JID.init(JID.java:355)

… 20 more

It probably also causes the Null Pointer Exception in Smack bug 232.