Page MenuHomePhabricator

[native] Broadcast device list update and send backup key stub
ClosedPublic

Authored by bartek on Mar 11 2024, 6:49 AM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Nov 29, 6:43 AM
Unknown Object (File)
Fri, Nov 29, 4:59 AM
Unknown Object (File)
Sun, Nov 17, 1:07 PM
Unknown Object (File)
Sun, Nov 10, 2:03 PM
Unknown Object (File)
Fri, Nov 8, 5:10 AM
Unknown Object (File)
Oct 27 2024, 8:20 AM
Unknown Object (File)
Oct 22 2024, 3:04 PM
Unknown Object (File)
Oct 22 2024, 3:04 PM
Subscribers

Details

Summary

Primary device should broadcast the device list update to all peers. However, we don't have peer syncing yet, so as a stub, it only broadcasts it to all devices from its device list.
Also, stubbed message containing backup data key, which will be needed for backup restore on secondary device.

Depends on D11296

Test Plan

Added a few devices to the device list - made sure that after successful QR auth flow, all devices receive the device list update. Also, secondary device displays a console log with stub backup key.

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

bartek held this revision as a draft.
bartek edited the test plan for this revision. (Show Details)
bartek published this revision for review.Mar 12 2024, 2:20 AM
native/profile/secondary-device-qr-code-scanner.react.js
62

Should we add an invariant here that deviceLists.length > 0?

native/qr-code/qr-code-screen.react.js
103

Is this console.log left over from debugging?

kamil requested changes to this revision.Mar 13 2024, 6:03 AM
kamil added inline comments.
lib/types/tunnelbroker/peer-to-peer-message-types.js
26

We should discuss whether this update should be sent encrypted via olm and create a task to add it in the future, then this also should be sent as subtype of ENCRYPTED_MESSAGE

This revision now requires changes to proceed.Mar 13 2024, 6:03 AM
lib/types/tunnelbroker/peer-to-peer-message-types.js
26

Yes, good point, I was thinking about this too.
I'm not sure if it's possible at this moment, so I created https://linear.app/comm/issue/ENG-7245/broadcast-device-list-updates-via-olm-sessions to address this

native/qr-code/qr-code-screen.react.js
103

It is replaced by actual backup restore call later in the stack

This revision is now accepted and ready to land.Mar 18 2024, 6:42 AM