Page MenuHomePhabricator

[identity] Add verification for replacing a device
ClosedPublic

Authored by bartek on Mon, Apr 22, 6:46 AM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, May 3, 2:40 PM
Unknown Object (File)
Thu, May 2, 9:58 PM
Unknown Object (File)
Wed, May 1, 8:48 PM
Unknown Object (File)
Mon, Apr 29, 1:27 PM
Unknown Object (File)
Sun, Apr 28, 7:25 PM
Unknown Object (File)
Fri, Apr 26, 7:00 PM
Subscribers

Details

Summary

Added possibility to replace a device in device list

Depends on D11687

Test Plan
  • Added unit tests
  • Called UpdateDeviceList RPC with payload that replaced exactly one device - pass
  • Called UpdateDeviceList RPC with payload that tried to replace primary device - fail

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

bartek held this revision as a draft.
bartek published this revision for review.Tue, Apr 23, 11:59 PM
varun added inline comments.
services/identity/src/device_list.rs
106 ↗(On Diff #39343)
127 ↗(On Diff #39343)

don't we need to make sure that the previous and new device in the replacement are both keyservers?

This revision is now accepted and ready to land.Thu, Apr 25, 10:09 PM
services/identity/src/device_list.rs
127 ↗(On Diff #39343)

Yeah this comment is a bit misleading. These validation functions are device-type-agnostic. Generally the logic is going to be extended when we add support for keyserver QR login