Page MenuHomePhabricator

[crypto] unify key types and introduce type for Inbound Keys
ClosedPublic

Authored by kamil on Feb 19 2024, 7:35 AM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Dec 23, 8:22 AM
Unknown Object (File)
Nov 26 2024, 4:55 AM
Unknown Object (File)
Nov 25 2024, 10:38 PM
Unknown Object (File)
Nov 23 2024, 6:26 AM
Unknown Object (File)
Nov 22 2024, 3:15 PM
Unknown Object (File)
Nov 22 2024, 11:09 AM
Unknown Object (File)
Nov 9 2024, 4:05 AM
Unknown Object (File)
Nov 9 2024, 2:45 AM
Subscribers

Details

Summary
  1. Move some types from CommCoreModuleSchema.js -> crypto-types.js
  2. Add validator for SignedPrekeys
  3. UserDevicesOlmInboundKeys type and validator
  4. Group types in identity-service-types.js
Test Plan

FLow

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

kamil held this revision as a draft.
kamil published this revision for review.Feb 19 2024, 9:35 AM
tomek added inline comments.
lib/types/crypto-types.js
25–28 ↗(On Diff #37323)

It might appear more convenient to have two fields, one for content and one for notif, each being an object with prekey and prekeySignature

lib/types/identity-service-types.js
87–88 ↗(On Diff #37323)

Can these two be null at the same time? If not, then can we reflect that in the type?

This revision is now accepted and ready to land.Feb 21 2024, 1:48 AM
lib/types/crypto-types.js
25–28 ↗(On Diff #37323)

I am just moving this type - it will require changing C++ code which returns prekeys

lib/types/identity-service-types.js
87–88 ↗(On Diff #37323)

This is based on InboundKeyInfoResponse - but there is some ongoing work to improve it (https://phab.comm.dev/D11108#inline-67556)

This revision was landed with ongoing or failed builds.Feb 23 2024, 1:32 AM
This revision was automatically updated to reflect the committed changes.