Page MenuHomePhabricator

[native] Modify `SIWEPanel` to hit `siwe_auth` endpoint once SIWE message is signed
ClosedPublic

Authored by atul on Dec 24 2022, 7:58 PM.
Tags
None
Referenced Files
F3567827: D6028.diff
Fri, Dec 27, 9:40 PM
Unknown Object (File)
Wed, Dec 18, 6:18 PM
Unknown Object (File)
Wed, Dec 18, 6:18 PM
Unknown Object (File)
Wed, Dec 18, 6:18 PM
Unknown Object (File)
Wed, Dec 18, 6:18 PM
Unknown Object (File)
Sat, Nov 30, 10:05 AM
Unknown Object (File)
Thu, Nov 28, 10:34 PM
Unknown Object (File)
Nov 8 2024, 4:18 PM
Subscribers
None

Details

Summary

Modify SIWEPanel to hit the siwe_auth endpoint instead of the create_account endpoint once SIWE message is signed.

We also modify the SIWE_AUTH_SUCCESS payload to a boolean indicating whether the signed message is valid and login/registration can continue.

NOTE: For now we will return from siweAuthResponder BEFORE login/registration... login/registration will come later at which point the payload for SIWE_AUTH_SUCCESS will look like RegisterResponse | LogInResponse or something.

Depends on D6026

Test Plan

Able to hit the endpoint and verify that the request payload is as expected:
https://blob.sh/58459b.png

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

atul requested review of this revision.Dec 24 2022, 8:12 PM
This revision is now accepted and ready to land.Dec 25 2022, 7:23 PM

rebase before addressing feedback

This revision was landed with ongoing or failed builds.Dec 27 2022, 12:40 AM
This revision was automatically updated to reflect the committed changes.