Roster changes on Shared group deletion

Wildfire 2.4.4

On deletion of a shared group the subscription status of every user in that group is checked in Roster.java (deleteSharedUser[/b]) and appropriate action is taken to cleanup. One thing is overlooked though. When deleteRosterItem[/b] is called from deleteSharedUser[/b] a presence packet is routed without checking if the item to delete is a shared group item. The result is corrupted rosters. This can be fixed by checking the flag doChecking[/b] in deleteRosterItem[/b], since this flag is used to see if the function call is a result of a shared group modification.

Another thing is the check;

// Do nothing if the existing shared group is not the sharedGroup to remove

if(!item.getSharedGroups().contains(deletedGroup)){

return;

}

/code

that prevents rosteritems from being deleted on the wrong basis is present in the function deleteSharedUser(Group sharedGroup, JID deletedUser)[/b], but is missing in the function deleteSharedUser(JID deletedUser, Collection groups, Group deletedGroup)[/b]. This causes incorrect deletion of rosteritems in the cache.

I am fairly new to Wildfire, so I can be completely wrong. Please tell me if so.

Until this is fixed, do you think the following is a good workaround - set the showtype to “nobody” before deleting a shared group?

Thanks for the bug report and possible fix! I filed this as JM-561. Gato is the expert with the shared group code so he’‘ll need to review the bug report and fix. In any case, we’'ll get that done for the next release.

Regards,

Matt

Hello

we are facing the same bug.

Have you any idea when such a bug could be fixed ?

What we observed is that shared group subscription may override roster’‘s one. It could be interesting to keep in RosterItem class a roster subscription status independant of shared groups’'one. This latest having precedence when the item is both in shared groups and standard rosters.

We also noticed that we received an unsubscribe stanza from the server.

If you are interested we have made a more detailed analysis with some colleagues.

Thanks and Regards.

Message was edited by: pcohen