• Home
  • Raw
  • Download

Lines Matching refs:response

244     auto response = impl_->GetHmacSharingParameters();  in getHmacSharingParameters()  local
247 params.seed.setToExternal(const_cast<uint8_t*>(response.params.seed.data), in getHmacSharingParameters()
248 response.params.seed.data_length); in getHmacSharingParameters()
249 static_assert(sizeof(response.params.nonce) == params.nonce.size(), "Nonce sizes don't match"); in getHmacSharingParameters()
250 memcpy(params.nonce.data(), response.params.nonce, params.nonce.size()); in getHmacSharingParameters()
251 _hidl_cb(legacy_enum_conversion(response.error), params); in getHmacSharingParameters()
270 auto response = impl_->ComputeSharedHmac(request); in computeSharedHmac() local
272 if (response.error == KM_ERROR_OK) sharing_check = kmBlob2hidlVec(response.sharing_check); in computeSharedHmac()
274 _hidl_cb(legacy_enum_conversion(response.error), sharing_check); in computeSharedHmac()
294 auto response = impl_->VerifyAuthorization(request); in verifyAuthorization() local
297 token.challenge = response.token.challenge; in verifyAuthorization()
298 token.timestamp = response.token.timestamp; in verifyAuthorization()
299 token.parametersVerified = kmParamSet2Hidl(response.token.parameters_verified); in verifyAuthorization()
300 token.securityLevel = legacy_enum_conversion(response.token.security_level); in verifyAuthorization()
301 token.mac = kmBlob2hidlVec(response.token.mac); in verifyAuthorization()
303 _hidl_cb(legacy_enum_conversion(response.error), token); in verifyAuthorization()
314 AddEntropyResponse response; in addRngEntropy() local
315 impl_->AddRngEntropy(request, &response); in addRngEntropy()
317 return legacy_enum_conversion(response.error); in addRngEntropy()
325 GenerateKeyResponse response; in generateKey() local
326 impl_->GenerateKey(request, &response); in generateKey()
330 if (response.error == KM_ERROR_OK) { in generateKey()
331 resultKeyBlob = kmBlob2hidlVec(response.key_blob); in generateKey()
332 resultCharacteristics.hardwareEnforced = kmParamSet2Hidl(response.enforced); in generateKey()
333 resultCharacteristics.softwareEnforced = kmParamSet2Hidl(response.unenforced); in generateKey()
335 _hidl_cb(legacy_enum_conversion(response.error), resultKeyBlob, resultCharacteristics); in generateKey()
347 GetKeyCharacteristicsResponse response; in getKeyCharacteristics() local
348 impl_->GetKeyCharacteristics(request, &response); in getKeyCharacteristics()
351 if (response.error == KM_ERROR_OK) { in getKeyCharacteristics()
352 resultCharacteristics.hardwareEnforced = kmParamSet2Hidl(response.enforced); in getKeyCharacteristics()
353 resultCharacteristics.softwareEnforced = kmParamSet2Hidl(response.unenforced); in getKeyCharacteristics()
355 _hidl_cb(legacy_enum_conversion(response.error), resultCharacteristics); in getKeyCharacteristics()
368 ImportKeyResponse response; in importKey() local
369 impl_->ImportKey(request, &response); in importKey()
373 if (response.error == KM_ERROR_OK) { in importKey()
374 resultKeyBlob = kmBlob2hidlVec(response.key_blob); in importKey()
375 resultCharacteristics.hardwareEnforced = kmParamSet2Hidl(response.enforced); in importKey()
376 resultCharacteristics.softwareEnforced = kmParamSet2Hidl(response.unenforced); in importKey()
378 _hidl_cb(legacy_enum_conversion(response.error), resultKeyBlob, resultCharacteristics); in importKey()
395 ImportWrappedKeyResponse response; in importWrappedKey() local
396 impl_->ImportWrappedKey(request, &response); in importWrappedKey()
400 if (response.error == KM_ERROR_OK) { in importWrappedKey()
401 resultKeyBlob = kmBlob2hidlVec(response.key_blob); in importWrappedKey()
402 resultCharacteristics.hardwareEnforced = kmParamSet2Hidl(response.enforced); in importWrappedKey()
403 resultCharacteristics.softwareEnforced = kmParamSet2Hidl(response.unenforced); in importWrappedKey()
405 _hidl_cb(legacy_enum_conversion(response.error), resultKeyBlob, resultCharacteristics); in importWrappedKey()
419 ExportKeyResponse response; in exportKey() local
420 impl_->ExportKey(request, &response); in exportKey()
423 if (response.error == KM_ERROR_OK) { in exportKey()
424 resultKeyBlob.setToExternal(response.key_data, response.key_data_length); in exportKey()
426 _hidl_cb(legacy_enum_conversion(response.error), resultKeyBlob); in exportKey()
437 AttestKeyResponse response; in attestKey() local
438 impl_->AttestKey(request, &response); in attestKey()
441 if (response.error == KM_ERROR_OK) { in attestKey()
442 resultCertChain = kmCertChain2Hidl(response.certificate_chain); in attestKey()
444 _hidl_cb(legacy_enum_conversion(response.error), resultCertChain); in attestKey()
457 UpgradeKeyResponse response; in upgradeKey() local
458 impl_->UpgradeKey(request, &response); in upgradeKey()
460 if (response.error == KM_ERROR_OK) { in upgradeKey()
461 _hidl_cb(ErrorCode::OK, kmBlob2hidlVec(response.upgraded_key)); in upgradeKey()
463 _hidl_cb(legacy_enum_conversion(response.error), hidl_vec<uint8_t>()); in upgradeKey()
473 DeleteKeyResponse response; in deleteKey() local
474 impl_->DeleteKey(request, &response); in deleteKey()
476 return legacy_enum_conversion(response.error); in deleteKey()
482 DeleteAllKeysResponse response; in deleteAllKeys() local
483 impl_->DeleteAllKeys(request, &response); in deleteAllKeys()
485 return legacy_enum_conversion(response.error); in deleteAllKeys()
505 BeginOperationResponse response; in begin() local
506 impl_->BeginOperation(request, &response); in begin()
509 if (response.error == KM_ERROR_OK) resultParams = kmParamSet2Hidl(response.output_params); in begin()
511 _hidl_cb(legacy_enum_conversion(response.error), resultParams, response.op_handle); in begin()
526 UpdateOperationResponse response; in update() local
527 impl_->UpdateOperation(request, &response); in update()
532 if (response.error == KM_ERROR_OK) { in update()
533 resultConsumed = response.input_consumed; in update()
534 resultParams = kmParamSet2Hidl(response.output_params); in update()
535 resultBlob = kmBuffer2hidlVec(response.output); in update()
537 _hidl_cb(legacy_enum_conversion(response.error), resultConsumed, resultParams, resultBlob); in update()
554 FinishOperationResponse response; in finish() local
555 impl_->FinishOperation(request, &response); in finish()
559 if (response.error == KM_ERROR_OK) { in finish()
560 resultParams = kmParamSet2Hidl(response.output_params); in finish()
561 resultBlob = kmBuffer2hidlVec(response.output); in finish()
563 _hidl_cb(legacy_enum_conversion(response.error), resultParams, resultBlob); in finish()
571 AbortOperationResponse response; in abort() local
572 impl_->AbortOperation(request, &response); in abort()
574 return legacy_enum_conversion(response.error); in abort()