Difference between revisions of "XEP-Remarks/XEP-0045: Multi-User Chat"

Jump to navigation Jump to search
(Add Category)
Line 26: Line 26:


(this mechanism doesn't cover MUCs which don't reflect the message ID and do autopastebin. Screw them!)
(this mechanism doesn't cover MUCs which don't reflect the message ID and do autopastebin. Screw them!)
= Mediated MUC Invitations =
The default mechanism to invite somebody into a MUC is [https://xmpp.org/extensions/xep-0045.html#invite-mediated §7.8.2 Mediated Invitation], where the MUC service will invite your friend on your behalf.
* Some MUC services will not invite a JID that is already a MUC member, thus breaking the invitation UX.
* With Mediated Invites, a malicious MUC can send an invite in the name of a user's contact, tricking the user's client into auto-joining.
* [https://xmpp.org/extensions/xep-0249.html XEP-0249: Direct MUC Invitations] is a potential solution to those issues.


= Am I still there? =
= Am I still there? =
Line 34: Line 43:
Sending a "silent" message or presence update to the MUC will lead to O(N²) complexity (if every client does so), killing all our batteries.
Sending a "silent" message or presence update to the MUC will lead to O(N²) complexity (if every client does so), killing all our batteries.


The "most viable" workaround is:
This is solved by [https://xmpp.org/extensions/xep-0410.html XEP-0410: MUC Self-Ping]
 
# set a (short, like maybe 15mins, or periodic) timeout after the last stanza received from a MUC
# on timeout: send a ping IQ to your own participant JID
# (maybe) respond to the reflected ping IQ, depending whether you are the "most active" MSN and on the phase of the moon
# if the ping IQ is responded to with iq-result, service-unavailable (official RFC response for a feature not implemented) or  feature-not-implemented (incorrect but found in the wild response for feature not implemented): phew, we are still joined, we are done
# if the ping IQ is responded to with anything else: we lost the connection to the MUC
#* send presence-unavailable
#* rejoin
# if the ping IQ times out, one of your clients probably lost the connection to the MUC, just to be sure we need to:
#* send presence-unavailable
#* rejoin


= MUC double join =
= MUC double join =

Navigation menu