summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormathieui <mathieui@mathieui.net>2014-12-11 14:46:52 +0100
committermathieui <mathieui@mathieui.net>2014-12-11 14:46:52 +0100
commit423974f90d4e9e7e25b99a690799419d48c4e644 (patch)
tree486bd2b45d47a36a675fb872f0bd67329011bfb4
parent5fcf08a4156849fdba5eaba103f59f37082735c6 (diff)
downloadslixmpp-423974f90d4e9e7e25b99a690799419d48c4e644.tar.gz
slixmpp-423974f90d4e9e7e25b99a690799419d48c4e644.tar.bz2
slixmpp-423974f90d4e9e7e25b99a690799419d48c4e644.tar.xz
slixmpp-423974f90d4e9e7e25b99a690799419d48c4e644.zip
Fix xep-0257 for slixmpp, and fix an element name
-rw-r--r--slixmpp/plugins/xep_0257/client_cert_management.py16
-rw-r--r--slixmpp/plugins/xep_0257/stanza.py2
2 files changed, 9 insertions, 9 deletions
diff --git a/slixmpp/plugins/xep_0257/client_cert_management.py b/slixmpp/plugins/xep_0257/client_cert_management.py
index 0d03eb14..d7ca50c9 100644
--- a/slixmpp/plugins/xep_0257/client_cert_management.py
+++ b/slixmpp/plugins/xep_0257/client_cert_management.py
@@ -31,35 +31,35 @@ class XEP_0257(BasePlugin):
register_stanza_plugin(Iq, DisableCert)
register_stanza_plugin(Iq, RevokeCert)
- def get_certs(self, ifrom=None, block=True, timeout=None, callback=None):
+ def get_certs(self, ifrom=None, timeout=None, callback=None):
iq = self.xmpp.Iq()
iq['type'] = 'get'
iq['from'] = ifrom
iq.enable('sasl_certs')
- return iq.send(block=block, timeout=timeout, callback=callback)
+ return iq.send(timeout=timeout, callback=callback)
def add_cert(self, name, cert, allow_management=True, ifrom=None,
- block=True, timeout=None, callback=None):
+ timeout=None, callback=None):
iq = self.xmpp.Iq()
iq['type'] = 'set'
iq['from'] = ifrom
iq['sasl_cert_append']['name'] = name
iq['sasl_cert_append']['x509cert'] = cert
iq['sasl_cert_append']['cert_management'] = allow_management
- return iq.send(block=block, timeout=timeout, callback=callback)
+ return iq.send(timeout=timeout, callback=callback)
- def disable_cert(self, name, ifrom=None, block=True,
+ def disable_cert(self, name, ifrom=None,
timeout=None, callback=None):
iq = self.xmpp.Iq()
iq['type'] = 'set'
iq['from'] = ifrom
iq['sasl_cert_disable']['name'] = name
- return iq.send(block=block, timeout=timeout, callback=callback)
+ return iq.send(timeout=timeout, callback=callback)
- def revoke_cert(self, name, ifrom=None, block=True,
+ def revoke_cert(self, name, ifrom=None,
timeout=None, callback=None):
iq = self.xmpp.Iq()
iq['type'] = 'set'
iq['from'] = ifrom
iq['sasl_cert_revoke']['name'] = name
- return iq.send(block=block, timeout=timeout, callback=callback)
+ return iq.send(timeout=timeout, callback=callback)
diff --git a/slixmpp/plugins/xep_0257/stanza.py b/slixmpp/plugins/xep_0257/stanza.py
index 7c2da743..86b63451 100644
--- a/slixmpp/plugins/xep_0257/stanza.py
+++ b/slixmpp/plugins/xep_0257/stanza.py
@@ -10,7 +10,7 @@ from slixmpp.xmlstream import ElementBase, ET, register_stanza_plugin
class Certs(ElementBase):
- name = 'query'
+ name = 'items'
namespace = 'urn:xmpp:saslcert:1'
plugin_attrib = 'sasl_certs'
interfaces = set()