Changeset View
Changeset View
Standalone View
Standalone View
services/identity/src/service/registration.rs
Show All 31 Lines | Some(Ok(RegistrationRequest { | ||||
.await | .await | ||||
{ | { | ||||
error!("Response was dropped: {}", e); | error!("Response was dropped: {}", e); | ||||
} | } | ||||
} | } | ||||
Err(e) => return Err(handle_db_error(e)), | Err(e) => return Err(handle_db_error(e)), | ||||
_ => {} | _ => {} | ||||
}; | }; | ||||
let response_and_state = pake_registration_start( | let response_and_state = server_register_response( | ||||
&mut OsRng, | |||||
&pake_registration_request_and_user_id.pake_registration_request, | &pake_registration_request_and_user_id.pake_registration_request, | ||||
) | ) | ||||
.await?; | .await?; | ||||
if let Err(e) = tx.send(Ok(response_and_state.response)).await { | if let Err(e) = tx.send(Ok(response_and_state.response)).await { | ||||
error!("Response was dropped: {}", e); | error!("Response was dropped: {}", e); | ||||
} | } | ||||
Ok(RegistrationState { | Ok(RegistrationState { | ||||
Show All 26 Lines | Some(Ok(RegistrationRequest { | ||||
pake_registration_upload_and_credential_request, | pake_registration_upload_and_credential_request, | ||||
)), | )), | ||||
})) => { | })) => { | ||||
let response_and_state = match pake_registration_finish( | let response_and_state = match pake_registration_finish( | ||||
®istration_state.user_id, | ®istration_state.user_id, | ||||
client, | client, | ||||
&pake_registration_upload_and_credential_request | &pake_registration_upload_and_credential_request | ||||
.pake_registration_upload, | .pake_registration_upload, | ||||
Some(pake_state), | pake_state, | ||||
®istration_state.username, | ®istration_state.username, | ||||
®istration_state.signing_public_key, | ®istration_state.signing_public_key, | ||||
®istration_state.session_initialization_info, | ®istration_state.session_initialization_info, | ||||
) | ) | ||||
.await | .await | ||||
{ | { | ||||
Ok(_) => { | Ok(_) => { | ||||
pake_login_start( | pake_login_start( | ||||
▲ Show 20 Lines • Show All 61 Lines • Show Last 20 Lines |