NullPointerException while processing stanza without 'to' or 'from'
guusdk opened this issue · 1 comments
guusdk commented
I've found this in the logs of Ignite, after deploying the mucrtbl plugin:
2023.02.23 19:56:31 ERROR [message-archive-handler-3211]: org.jivesoftware.openfire.interceptor.InterceptorManager - Error in interceptor: org.igniterealtime.openfire.plugin.mucrtbl.PubSubHandler@41668615 while intercepting:
<message to="redacted@igniterealtime.org/redacted">
<result xmlns="urn:xmpp:mam:2" queryid="redacted" id="redacted">
<forwarded xmlns="urn:xmpp:forward:0">
<delay xmlns="urn:xmpp:delay" stamp="redacted"/>
<message xmlns="jabber:client" type="chat" id="redacted" from="redacted@igniterealtime.org/redacted" to="alsoredacted@igniterealtime.org">
<body>redacted</body>
<markable xmlns="urn:xmpp:chat-markers:0"></markable>
<origin-id xmlns="urn:xmpp:sid:0" id="redacted"></origin-id>
</message>
</forwarded>
</result>
</message>
java.lang.NullPointerException: null
at org.igniterealtime.openfire.plugin.mucrtbl.PubSubHandler.interceptPacket(PubSubHandler.java:87) ~[?:?]
at org.jivesoftware.openfire.interceptor.InterceptorManager.invokeInterceptors(InterceptorManager.java:268) ~[xmppserver-4.7.4.jar:4.7.4]
at org.jivesoftware.openfire.interceptor.InterceptorManager.invokeInterceptors(InterceptorManager.java:230) ~[xmppserver-4.7.4.jar:4.7.4]
at org.jivesoftware.openfire.MessageRouter.route(MessageRouter.java:89) ~[xmppserver-4.7.4.jar:4.7.4]
at org.jivesoftware.openfire.spi.PacketRouterImpl.route(PacketRouterImpl.java:79) ~[xmppserver-4.7.4.jar:4.7.4]
at com.reucon.openfire.plugin.archive.xep0313.IQQueryHandler.sendMessageResult(IQQueryHandler.java:586) ~[?:?]
at com.reucon.openfire.plugin.archive.xep0313.IQQueryHandler.lambda$handleIQ$2(IQQueryHandler.java:291) ~[?:?]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_342]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_342]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_342]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_342]
at java.lang.Thread.run(Thread.java:750) [?:1.8.0_342]
guusdk commented
THe pubsub handler expects every stanza to have both a 'to' and 'from' address. That's not always the case.