diff options
author | Nicolas Werner <nicolas.werner@hotmail.de> | 2020-11-30 00:26:27 +0100 |
---|---|---|
committer | Nicolas Werner <nicolas.werner@hotmail.de> | 2020-11-30 01:54:53 +0100 |
commit | 2ce129e6b61d18ac4a2e79702d3c1fd1302c6631 (patch) | |
tree | 4cab52d78c428bbebc9c854c2019e7b0fc3b71d4 /src/Cache_p.h | |
parent | Remove outbound session storage (diff) | |
download | nheko-2ce129e6b61d18ac4a2e79702d3c1fd1302c6631.tar.xz |
Properly share and rotate sessions on member and device changes
Diffstat (limited to 'src/Cache_p.h')
-rw-r--r-- | src/Cache_p.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/Cache_p.h b/src/Cache_p.h index f8c4ceaf..fab2d964 100644 --- a/src/Cache_p.h +++ b/src/Cache_p.h @@ -59,6 +59,8 @@ public: // user cache stores user keys std::optional<UserKeyCache> userKeys(const std::string &user_id); + std::map<std::string, std::optional<UserKeyCache>> getMembersWithKeys( + const std::string &room_id); void updateUserKeys(const std::string &sync_token, const mtx::responses::QueryKeys &keyQuery); void markUserKeysOutOfDate(lmdb::txn &txn, @@ -232,10 +234,11 @@ public: // void saveOutboundMegolmSession(const std::string &room_id, const OutboundGroupSessionData &data, - mtx::crypto::OutboundGroupSessionPtr session); + 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, mtx::crypto::OutboundGroupSessionPtr &session); void dropOutboundMegolmSession(const std::string &room_id); |