Projects tigase _server server-core Issues #205
Packet DefaultHandler issue with delivery of some packets (#205)
Won't Fix
wojciech.kapcia@tigase.net opened 1 decade ago

As per Plugin stop working with tigase-server 5.2 version it seems that with recent changes to PacketDefautHandler not all stanzas are correctly forwarded if the enclosing packet doesn't have proper addressing.

Artur Hefczyc commented 1 decade ago

As you have already looked into the problem, could you please provide more details about it. Which addresses affect the processing (Stanza/Packet/From/To). Ideally use case how to reproduce the problem or point me to the DefaultPacketHandler part of the code which incorrectly handles such packets.

wojciech.kapcia@tigase.net commented 1 decade ago

It was caused by the following change:

https://projects.tigase.org/projects/tigase-server/repository/revisions/43ffa897dd3668646ca3a02a38b18d64ed709a96

and most exactly this new code:

if (resource == null) {

	// In default packet handler we deliver packets to a specific resource only
	result = Authorization.FEATURE_NOT_IMPLEMENTED.getResponseMessage(packet,
			"The feature is not supported yet.", true);
	result.setPacketFrom(null);
	result.setPacketTo(null);
} 

and example stanza:

<ack type="subscribe" xmlns="myapp:event:presence-ack" jid="tigase1@atlantiscity" to="admin@atlantiscity"/>

Basically stanzas outside normative XMPP, without resource won't be forwarded to any connection but simply dropped.

It remains to be discussed what would be best option to handle such scenarios.

Artur Hefczyc commented 1 decade ago

I think current implementation does the right thing. If there is not resource then Tigase should not do anything about unknown stanza and simply return an error. As far as I understand RFC XMPP server should reject any unknown stanza whether there is a resource or not, so Tigase now is even more forgiving.

It seems that current implementation does make most sense as it kind of protects people from malicious stanzas sent by strangers. Those who have your resource are most likely your friends from a roster.

issue 1 of 1
Type
Bug
Priority
Normal
Assignee
RedmineID
1326
Version
tigase-server-5.2.0
Issue Votes (0)
Watchers (0)
Reference
tigase/_server/server-core#205
Please wait...
Page is in error, reload to recover