Page MenuHomePhabricator

[DRAFT] syncing keyserver store
DraftPublic

Authored by kamil on May 20 2024, 4:59 PM.
Tags
None
Referenced Files
F2063717: D12133.id40430.diff
Fri, Jun 21, 4:58 AM
F2058375: D12133.id40425.diff
Thu, Jun 20, 5:29 PM
F2058296: D12133.diff
Thu, Jun 20, 5:26 PM
F2057919: D12133.id.diff
Thu, Jun 20, 4:56 PM
Unknown Object (File)
Wed, Jun 12, 12:51 PM
Unknown Object (File)
Tue, Jun 11, 4:21 AM
Unknown Object (File)
Sun, Jun 9, 1:46 PM
Unknown Object (File)
Sun, Jun 9, 1:45 PM
Subscribers
This is a draft revision that has not yet been submitted for review.

Details

Reviewers
tomek
bartek
Summary

Draft of Syncing KeyserverStore without keyserver goal. Implemented because it was really tough to test Broadcasting information to peers with syncing actual data. Publishing this now to share with reviewers more insight into test plans and show the general approach.

This diff is going to be sliced into smaller ones and improved.

Depends on D12132

Test Plan

Note: creating the initial peer list is now done using the testing button as Device list updates are disseminated to all peers is not done yet.

Did the following:


  1. Register new user
  2. Logged on clients C1 and C2
  3. Perform keyserver operation on C1 and:
    1. Check if a session with C2 is created
    2. Check if new keyserver info is visible on C2
  4. Perform keyserver action on C2 and check if it's visible on C1
  5. Test when C1 or C2 are offline
  6. Test sending the same messages multiple times (should be ignored and flushed from TB)
  7. Test adding new client C3
  8. Simulate issues when there are no OTKs on C3 (messages to C3 should be persisted), after C3 uploaded OTKs messages should be sent automatically whenever there are new changes to the keyserver store (all updates history)
  9. Make sure confirmation works (messages are removed from the table)
  10. Messages are sent in order

Tested both platforms:

  1. web -> web
  2. native -> web
  3. native -> native
  4. web -> native (TODO: this is not working, message is decrypted but JSON.parse fails, I think some characters are trimmed, similar to this issue - I need to test that again after rebasing on master).

Not tested:

  1. Resending messages and malformed session (tracked in (https://linear.app/comm/issue/ENG-6982/[june]-resending-messages)[Resending messages]).
  2. Try to simulate race condition (add timeout after modifying keyserver store) - only the winning device data is kept, but resending is not yet implemented.

Diff Detail

Repository
rCOMM Comm
Branch
publish-broadcasting
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

kamil held this revision as a draft.