plugin_e2ee: prevent empty JID from being passed to plugin

Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
This commit is contained in:
Maxime “pep” Buquet 2020-01-11 12:47:24 +01:00
parent 30a7ac052a
commit 7f73a664a3

View file

@ -428,7 +428,10 @@ class E2EEPlugin(BasePlugin):
break
# If we encrypt to all of these JIDs is up to the plugin, we
# just tell it who is in the room.
jids.append(user.jid)
# XXX: user.jid shouldn't be empty. That's a MucTab/slixmpp
# bug.
if user.jid.bare:
jids.append(user.jid)
if not self._encryption_enabled(tab.jid):
raise NothingToEncrypt()