diff sat/core/xmpp.py @ 2688:943e78e18882

core (xmpp): added missing disco#info namespace to disco info result.
author Goffi <goffi@goffi.org>
date Sat, 10 Nov 2018 10:16:38 +0100
parents e9cd473a2f46
children 1ecceac3df96
line wrap: on
line diff
--- a/sat/core/xmpp.py	Sat Nov 10 10:16:35 2018 +0100
+++ b/sat/core/xmpp.py	Sat Nov 10 10:16:38 2018 +0100
@@ -43,6 +43,10 @@
 import sys
 
 
+NS_X_DATA = u"jabber:x:data"
+NS_DISCO_INFO = u"http://jabber.org/protocol/disco#info"
+
+
 class SatXMPPEntity(object):
     """Common code for Client and Component"""
     _reason = None  # reason of disconnection
@@ -1351,9 +1355,17 @@
 
 
 class SatDiscoProtocol(disco.DiscoClientProtocol):
+    implements(iwokkel.IDisco)
+
     def __init__(self, host):
         disco.DiscoClientProtocol.__init__(self)
 
+    def getDiscoInfo(self, requestor, target, nodeIdentifier=""):
+        return [disco.DiscoFeature(NS_DISCO_INFO)]
+
+    def getDiscoItems(self, requestor, target, nodeIdentifier=""):
+        return []
+
 
 class SatFallbackHandler(generic.FallbackHandler):
     def __init__(self, host):