Initialize olm sessions for notifications on web and keyserver via socket requests
Summary: This differential initialises olm session for notifications on web via server request mechanism. The keyserver checks whether the web client has the olm session. If it doesn't it requests session intialisation. The web client uses the shared logic to get necessary keys from the keyserver and web specific logic to create the session and store it in IndexedDB.
Test Plan:
- Checkout to master.
- Log-out.
- Log-in.
- Checkout to the branch with this diff stack.
Then:
- Using mariadb console ensure that new olm session was created on the keyserver.
- Using Developer Tools ensure that new entry was created in IndexedDB and that it contains pickled olm session for notifs.
- Log-out.
- Using Developer Tools ensure that entry with olm session for notifs was removed (it is not implemented in this differential but this line(https://github.com/CommE2E/comm/blob/master/web/database/worker/db-worker.js#L154) should clear entire IndexedDB on log-out).
Reviewers: michal, kamil, atul
Reviewed By: michal, atul
Subscribers: ashoat, tomek, wyilio
Differential Revision: https://phab.comm.dev/D9535