summary refs log tree commit diff
path: root/src/Cache_p.h
diff options
context:
space:
mode:
authorDeepBlueV7.X <nicolas.werner@hotmail.de>2021-07-18 16:22:45 +0000
committerGitHub <noreply@github.com>2021-07-18 16:22:45 +0000
commit1dc20f9164a9e4b733c1b076473a0ebb01ba87b4 (patch)
treeba6c1fa565a855f746db0ffbfcd1f1331aa1950a /src/Cache_p.h
parentFix replies not reloading after fetching them (diff)
parentDisable unchecked key sharing to trusted users by default (diff)
downloadnheko-1dc20f9164a9e4b733c1b076473a0ebb01ba87b4.tar.xz
Merge pull request #646 from Nheko-Reborn/historical-key-sharing
Historical key sharing
Diffstat (limited to 'src/Cache_p.h')
-rw-r--r--src/Cache_p.h9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/Cache_p.h b/src/Cache_p.h

index c76cc717..d1f6307d 100644 --- a/src/Cache_p.h +++ b/src/Cache_p.h
@@ -238,12 +238,12 @@ public: // Outbound Megolm Sessions // void saveOutboundMegolmSession(const std::string &room_id, - const OutboundGroupSessionData &data, + const GroupSessionData &data, mtx::crypto::OutboundGroupSessionPtr &session); OutboundGroupSessionDataRef getOutboundMegolmSession(const std::string &room_id); bool outboundMegolmSessionExists(const std::string &room_id) noexcept; void updateOutboundMegolmSession(const std::string &room_id, - const OutboundGroupSessionData &data, + const GroupSessionData &data, mtx::crypto::OutboundGroupSessionPtr &session); void dropOutboundMegolmSession(const std::string &room_id); @@ -254,10 +254,12 @@ public: // Inbound Megolm Sessions // void saveInboundMegolmSession(const MegolmSessionIndex &index, - mtx::crypto::InboundGroupSessionPtr session); + mtx::crypto::InboundGroupSessionPtr session, + const GroupSessionData &data); mtx::crypto::InboundGroupSessionPtr getInboundMegolmSession( const MegolmSessionIndex &index); bool inboundMegolmSessionExists(const MegolmSessionIndex &index); + std::optional<GroupSessionData> getMegolmSessionData(const MegolmSessionIndex &index); // // Olm Sessions @@ -676,6 +678,7 @@ private: lmdb::dbi inboundMegolmSessionDb_; lmdb::dbi outboundMegolmSessionDb_; + lmdb::dbi megolmSessionDataDb_; QString localUserId_; QString cacheDirectory_;