Struct olm_rs::outbound_group_session::OlmOutboundGroupSession [−][src]
pub struct OlmOutboundGroupSession { /* fields omitted */ }Expand description
An out-bound group session is responsible for encrypting outgoing communication in a Megolm session.
Implementations
Creates a new instance of OlmOutboundGroupSession.
C-API equivalent
olm_init_outbound_group_session
Panics
NotEnoughRandomfor creation
Serialises an OlmOutboundGroupSession to encrypted Base64.
C-API equivalent
olm_pickle_outbound_group_session
Panics
OutputBufferTooSmallfor pickled buffer- on malformed UTF-8 coding of the pickling provided by libolm
Deserialises from encrypted Base64 that was previously obtained by pickling an OlmOutboundGroupSession.
C-API equivalent
olm_unpickle_outbound_group_session
Errors
BadAccountKeyif the key doesn’t match the one the session was encrypted withInvalidBase64if decoding the suppliedpickledstring slice fails
Encrypts a plaintext message using the session.
C-API equivalent
olm_group_encrypt
Panics
OutputBufferTooSmallfor encrypted message- on malformed UTF-8 coding of the ciphertext provided by libolm
Get the current message index for this session.
Each message is sent with an increasing index; this returns the index for the next message.
C-API equivalent
olm_outbound_group_session_message_index
Get a base64-encoded identifier for this session.
C-API equivalent
olm_outbound_group_session_id
Panics
OutputBufferTooSmallfor too small ID buffer- on malformed UTF-8 coding of the session ID provided by libolm
Get the base64-encoded current ratchet key for this session.
Each message is sent with a different ratchet key. This function returns the ratchet key that will be used for the next message.
C-API equivalent
olm_outbound_group_session_key
Panics
OutputBufferTooSmallfor too small session key buffer- on malformed UTF-8 coding of the session key provided by libolm