Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3404621
D5209.id17042.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D5209.id17042.diff
View Options
diff --git a/services/identity/src/service.rs b/services/identity/src/service.rs
--- a/services/identity/src/service.rs
+++ b/services/identity/src/service.rs
@@ -461,26 +461,34 @@
error!("Too many messages received in stream, aborting");
return Err(Status::aborted("please retry"));
}
- match parse_and_verify_siwe_message(
+ parse_and_verify_siwe_message(
&wallet_login_request.user_id,
&wallet_login_request.device_id,
&wallet_login_request.siwe_message,
wallet_login_request.siwe_signature,
- ) {
- Ok(()) => Ok(LoginResponse {
- data: Some(WalletLoginResponse(WalletLoginResponseStruct {
- access_token: put_token_helper(
- client,
- AuthType::Wallet,
- &wallet_login_request.user_id,
- &wallet_login_request.device_id,
- rng,
- )
- .await?,
- })),
- }),
- Err(e) => Err(e),
- }
+ )?;
+ client
+ .update_users_table(
+ wallet_login_request.user_id.clone(),
+ wallet_login_request.device_id.clone(),
+ None,
+ None,
+ Some(wallet_login_request.user_public_key),
+ )
+ .await
+ .map_err(handle_db_error)?;
+ Ok(LoginResponse {
+ data: Some(WalletLoginResponse(WalletLoginResponseStruct {
+ access_token: put_token_helper(
+ client,
+ AuthType::Wallet,
+ &wallet_login_request.user_id,
+ &wallet_login_request.device_id,
+ rng,
+ )
+ .await?,
+ })),
+ })
}
async fn pake_login_start(
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Dec 4, 12:03 PM (6 m, 44 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2612514
Default Alt Text
D5209.id17042.diff (1 KB)
Attached To
Mode
D5209: [services][identity] update user's public keys in ddb during wallet login
Attached
Detach File
Event Timeline
Log In to Comment