Page MenuHomePhabricator

[keyserver] accountOwnershipResponder
ClosedPublic

Authored by varun on Jun 30 2023, 10:09 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, May 13, 12:15 PM
Unknown Object (File)
Mon, May 13, 3:39 AM
Unknown Object (File)
Sat, May 4, 11:51 AM
Unknown Object (File)
Sat, May 4, 11:51 AM
Unknown Object (File)
Sat, May 4, 11:51 AM
Unknown Object (File)
Sat, Apr 27, 1:30 AM
Unknown Object (File)
Apr 17 2024, 7:34 AM
Unknown Object (File)
Apr 17 2024, 7:34 AM
Subscribers

Details

Summary

new responder that checks viewer's username and provides a signed message
attesting that the user owns that particular username. this message can then be
presented to the identity service to allow registration of a reserved username.

Test Plan

called the responder from web and verified that the signature returned with my local keyserver's ed25519 public content key

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

varun held this revision as a draft.

improve readability a little

varun published this revision for review.Sep 12 2023, 9:08 AM
varun added a reviewer: ashoat.
varun edited the test plan for this revision. (Show Details)
ashoat requested changes to this revision.Sep 12 2023, 9:59 AM

Nice!! Some nonstandard stuff in this diff; requesting changes in the hopes that we can use the more standard mechanisms

lib/actions/user-actions.js
66 ↗(On Diff #30973)

I noticed you're missing action types here. If that's because you're not planning on using the standard dispatchActionPromise mechanism, I'd like to have some more context on that decision

73 ↗(On Diff #30973)

Instead of this Promise.race, you can specify a custom timeout by passing a third parameter to callServerEndpoint like this

82 ↗(On Diff #30973)

Why are you swallowing the error? I can't tell where you're going to use this, but the typical pattern is to pass the Promise to dispatchActionPromise, which will gracefully handle a promise rejection (exception) by dispatching a failed action

This revision now requires changes to proceed.Sep 12 2023, 9:59 AM
This revision is now accepted and ready to land.Sep 14 2023, 11:26 AM
This revision was automatically updated to reflect the committed changes.