comparison sat/bridge/dbus_bridge.py @ 2743:da59ff099b32

core (memory/encryption), plugin OTR: finished OTR integration in encryption: - messageEncryptionStart and messageEncryptionStop are now async - an encryption plugin can now have a startEncryption and endEncryption method, which are called automatically when suitable - trust is now put in "trusted" key of message_data, and markAsTrusted has been added, it is used in OTR - getTrustUI implemented for OTR, using legacy authenticate code - catch potr.crypt.InvalidParameterError on decryption - fixed some service OTR messages which were not correctly marked as not for storing, and thus were added to MAM archive/carbon copied - other bug fixes
author Goffi <goffi@goffi.org>
date Thu, 03 Jan 2019 21:00:00 +0100
parents e347e32aa07f
children 003b8b4b56a7
comparison
equal deleted inserted replaced
2742:1f5b02623355 2743:da59ff099b32
421 def messageEncryptionGet(self, to_jid, profile_key): 421 def messageEncryptionGet(self, to_jid, profile_key):
422 return self._callback("messageEncryptionGet", unicode(to_jid), unicode(profile_key)) 422 return self._callback("messageEncryptionGet", unicode(to_jid), unicode(profile_key))
423 423
424 @dbus.service.method(const_INT_PREFIX+const_CORE_SUFFIX, 424 @dbus.service.method(const_INT_PREFIX+const_CORE_SUFFIX,
425 in_signature='ssbs', out_signature='', 425 in_signature='ssbs', out_signature='',
426 async_callbacks=None) 426 async_callbacks=('callback', 'errback'))
427 def messageEncryptionStart(self, to_jid, namespace='', replace=False, profile_key="@NONE@"): 427 def messageEncryptionStart(self, to_jid, namespace='', replace=False, profile_key="@NONE@", callback=None, errback=None):
428 return self._callback("messageEncryptionStart", unicode(to_jid), unicode(namespace), replace, unicode(profile_key)) 428 return self._callback("messageEncryptionStart", unicode(to_jid), unicode(namespace), replace, unicode(profile_key), callback=callback, errback=errback)
429 429
430 @dbus.service.method(const_INT_PREFIX+const_CORE_SUFFIX, 430 @dbus.service.method(const_INT_PREFIX+const_CORE_SUFFIX,
431 in_signature='ss', out_signature='', 431 in_signature='ss', out_signature='',
432 async_callbacks=None) 432 async_callbacks=('callback', 'errback'))
433 def messageEncryptionStop(self, to_jid, profile_key): 433 def messageEncryptionStop(self, to_jid, profile_key, callback=None, errback=None):
434 return self._callback("messageEncryptionStop", unicode(to_jid), unicode(profile_key)) 434 return self._callback("messageEncryptionStop", unicode(to_jid), unicode(profile_key), callback=callback, errback=errback)
435 435
436 @dbus.service.method(const_INT_PREFIX+const_CORE_SUFFIX, 436 @dbus.service.method(const_INT_PREFIX+const_CORE_SUFFIX,
437 in_signature='sa{ss}a{ss}sa{ss}s', out_signature='', 437 in_signature='sa{ss}a{ss}sa{ss}s', out_signature='',
438 async_callbacks=('callback', 'errback')) 438 async_callbacks=('callback', 'errback'))
439 def messageSend(self, to_jid, message, subject={}, mess_type="auto", extra={}, profile_key="@NONE@", callback=None, errback=None): 439 def messageSend(self, to_jid, message, subject={}, mess_type="auto", extra={}, profile_key="@NONE@", callback=None, errback=None):