Module: message
- class omemo.message.Content[source]
Bases:
ABCThe encrypted content of an OMEMO-encrypted message. Contains for example the ciphertext, but can contain other backend-specific data that is shared between all recipients.
- class omemo.message.EncryptedKeyMaterial[source]
Bases:
ABCEncrypted key material. When decrypted, the key material can in turn be used to decrypt the content. One collection of key material is included in an OMEMO-encrypted message per recipient. Defails are backend-specific.
- class omemo.message.KeyExchange[source]
Bases:
ABCKey exchange information, generated by the active part of the session building process, then transferred to and consumed by the passive part of the session building process. Details are backend-specific.
- abstractmethod builds_same_session(other)[source]
- Parameters:
other (
KeyExchange) – The other key exchange instance to compare to this instance.- Return type:
- Returns:
Whether the key exchange information stored in this instance and the key exchange information stored in the other instance would build the same session.
- class omemo.message.Message(namespace, bare_jid, device_id, content, keys)[source]
Bases:
NamedTupleSimple structure representing an OMEMO-encrypted message.
- Parameters:
namespace (str)
bare_jid (str)
device_id (int)
content (Content)
keys (FrozenSet[Tuple[EncryptedKeyMaterial, KeyExchange | None]])
- keys: FrozenSet[Tuple[EncryptedKeyMaterial, KeyExchange | None]]
Alias for field number 4