pub fn start<S: SecretKey<CS::KeGroup>>(
        server_setup: &ServerSetup<CS, S>,
        message: RegistrationRequest<CS>,
        credential_identifier: &[u8],
    ) -> Result<ServerRegistrationStartResult<CS>, ProtocolError> {
        let oprf_key = oprf_key_from_seed::<CS::OprfGroup, CS::Hash>(
            &server_setup.oprf_seed,
            credential_identifier,
        )?;

        let server = voprf::NonVerifiableServer::new_with_key(&oprf_key)?;
        let evaluate_result = server.evaluate(message.blinded_element, None)?;

        Ok(ServerRegistrationStartResult {
            message: RegistrationResponse {
                evaluation_element: evaluate_result.message,
                server_s_pk: server_setup.keypair.public().clone(),
            },
            #[cfg(test)]
            oprf_key: GenericArray::clone_from_slice(&oprf_key),
        })
    }
/// From the client's "blinded" password, returns a response to be
/// sent back to the client, as well as a ServerRegistration
From the client's "blinded" password, returns a response to be
sent back to the client, as well as a ServerRegistration
From the client ' s " blinded " password returns a response to be sent back to the client as well as a ServerRegistration
pub fn start<S: SecretKey<CS::KeGroup>>(
        server_setup: &ServerSetup<CS, S>,
        message: RegistrationRequest<CS>,
        credential_identifier: &[u8],
    ) -> Result<ServerRegistrationStartResult<CS>, ProtocolError> {
        let oprf_key = oprf_key_from_seed::<CS::OprfGroup, CS::Hash>(
            &server_setup.oprf_seed,
            credential_identifier,
        )?;
        let server = voprf::NonVerifiableServer::new_with_key(&oprf_key)?;
        let evaluate_result = server.evaluate(message.blinded_element, None)?;
        Ok(ServerRegistrationStartResult {
            message: RegistrationResponse {
                evaluation_element: evaluate_result.message,
                server_s_pk: server_setup.keypair.public().clone(),
            },
            #[cfg(test)]
            oprf_key: GenericArray::clone_from_slice(&oprf_key),
        })
    }
pub fn start < S : SecretKey < CS :: KeGroup > > ( server_setup : & ServerSetup < CS , S > , message : RegistrationRequest < CS > , credential_identifier : & [ u8 ] , ) -> Result < ServerRegistrationStartResult < CS > , ProtocolError > { let oprf_key = oprf_key_from_seed :: < CS :: OprfGroup , CS :: Hash > ( & server_setup . oprf_seed , credential_identifier , ) ? ; let server = voprf :: NonVerifiableServer :: new_with_key ( & oprf_key ) ? ; let evaluate_result = server . evaluate ( message . blinded_element , None ) ? ; Ok ( ServerRegistrationStartResult { message : RegistrationResponse { evaluation_element : evaluate_result . message , server_s_pk : server_setup . keypair . public ( ) . clone ( ) , } , # [ cfg ( test ) ] oprf_key : GenericArray :: clone_from_slice ( & oprf_key ) , } ) }
From the client's "blinded" password, returns a response to be
sent back to the client, as well as a ServerRegistration
From the client ' s " blinded " password returns a response to be sent back to the client as well as a ServerRegistration
server_setup
&ServerSetup<CS, S>
message
RegistrationRequest<CS>
credential_identifier
&[u8]
server_setup
&ServerSetup<CS, S>
message
RegistrationRequest<CS>
credential_identifier
&[u8]