From 0de4a21320364f772e04a2bbcabae436715e61b2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Damir=20Jeli=C4=87?= Date: Tue, 1 Sep 2020 17:37:01 +0200 Subject: [PATCH] crypto: Expose some missing structs that are needed to implement a cryptostore. --- matrix_sdk_crypto/src/lib.rs | 3 ++- matrix_sdk_crypto/src/olm/account.rs | 3 ++- matrix_sdk_crypto/src/olm/mod.rs | 1 + 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/matrix_sdk_crypto/src/lib.rs b/matrix_sdk_crypto/src/lib.rs index 38630f32..451d5f4a 100644 --- a/matrix_sdk_crypto/src/lib.rs +++ b/matrix_sdk_crypto/src/lib.rs @@ -41,13 +41,14 @@ mod verification; pub use device::{Device, LocalTrust, ReadOnlyDevice, UserDevices}; pub use error::{MegolmError, OlmError}; pub use machine::OlmMachine; -use memory_stores::ReadOnlyUserDevices; +pub use memory_stores::ReadOnlyUserDevices; pub(crate) use olm::Account; pub use olm::EncryptionSettings; pub use requests::{IncomingResponse, OutgoingRequest, OutgoingRequests}; #[cfg(feature = "sqlite_cryptostore")] pub use store::sqlite::SqliteStore; pub use store::{CryptoStore, CryptoStoreError}; +pub use user_identity::{OwnUserIdentity, UserIdentities, UserIdentity}; pub use verification::Sas; use error::SignatureError; diff --git a/matrix_sdk_crypto/src/olm/account.rs b/matrix_sdk_crypto/src/olm/account.rs index 595a8ad0..74c42e08 100644 --- a/matrix_sdk_crypto/src/olm/account.rs +++ b/matrix_sdk_crypto/src/olm/account.rs @@ -26,7 +26,8 @@ use matrix_sdk_common::{ api::r0::keys::{OneTimeKey, SignedKey}, encryption::DeviceKeys, identifiers::{ - DeviceId, DeviceKeyAlgorithm, DeviceKeyId, EventEncryptionAlgorithm, RoomId, UserId, + DeviceId, DeviceIdBox, DeviceKeyAlgorithm, DeviceKeyId, EventEncryptionAlgorithm, RoomId, + UserId, }, instant::Instant, locks::Mutex, diff --git a/matrix_sdk_crypto/src/olm/mod.rs b/matrix_sdk_crypto/src/olm/mod.rs index af597d95..495a51f9 100644 --- a/matrix_sdk_crypto/src/olm/mod.rs +++ b/matrix_sdk_crypto/src/olm/mod.rs @@ -24,6 +24,7 @@ mod session; pub use account::{Account, IdentityKeys}; pub use group_sessions::{EncryptionSettings, InboundGroupSession}; pub(crate) use group_sessions::{GroupSessionKey, OutboundGroupSession}; +pub use olm_rs::PicklingMode; pub(crate) use session::OlmMessage; pub use session::Session;