comparison src/plugins/plugin_xep_0065.py @ 742:03744d9ebc13

plugin XEP-0033: implementation of the addressing feature: - frontends pass the recipients in the extra parameter of sendMessage - backend checks if the target server supports the feature (this is not done yet by prosody plugin) - features and identities are cached per profile and server - messages are duplicated in history for now (TODO: redesign the database) - echos signals are also duplicated to the sender (FIXME)
author souliane <souliane@mailoo.org>
date Wed, 11 Dec 2013 17:16:53 +0100
parents 4f747d7fde8c
children bfabeedbf32e
comparison
equal deleted inserted replaced
741:00318e60a06a 742:03744d9ebc13
805 proxy = self.host.memory.setParam("Proxy port", streamhost_elt.getAttribute("port", ""), 805 proxy = self.host.memory.setParam("Proxy port", streamhost_elt.getAttribute("port", ""),
806 "File Transfer", profile_key=self.parent.profile) 806 "File Transfer", profile_key=self.parent.profile)
807 807
808 def connectionInitialized(self): 808 def connectionInitialized(self):
809 def after_init(ignore): 809 def after_init(ignore):
810 proxy_ent = self.host.memory.getServerServiceEntity("proxy", "bytestreams", self.parent.profile) 810 proxy_ent = self.host.memory.getServerServiceEntity("proxy", "bytestreams", profile=self.parent.profile)
811 if not proxy_ent: 811 if not proxy_ent:
812 debug(_("No proxy found on this server")) 812 debug(_("No proxy found on this server"))
813 return 813 return
814 iq_elt = jabber_client.IQ(self.parent.xmlstream, 'get') 814 iq_elt = jabber_client.IQ(self.parent.xmlstream, 'get')
815 iq_elt["to"] = proxy_ent.full() 815 iq_elt["to"] = proxy_ent.full()