• Home
  • Raw
  • Download

Lines Matching refs:error

88         response->error = KM_ERROR_UNSUPPORTED_ALGORITHM;  in check_supported()
101 rsp->error = KM_ERROR_OK; in GetVersion()
109 response->error = KM_ERROR_OK; in SupportedAlgorithms()
118 response->error = KM_ERROR_MEMORY_ALLOCATION_FAILED; in SupportedAlgorithms()
131 response->error = KM_ERROR_UNSUPPORTED_PURPOSE; in GetSupported()
182 response->error = context_->AddRngEntropy(request.random_data.peek_read(), in AddRngEntropy()
196 response->error = KM_ERROR_UNSUPPORTED_ALGORITHM; in GenerateKey()
201 response->error = factory->GenerateKey(request.key_description, &key_blob, in GenerateKey()
203 if (response->error == KM_ERROR_OK) in GenerateKey()
214 response->error = in GetKeyCharacteristics()
217 if (response->error != KM_ERROR_OK) in GetKeyCharacteristics()
220 response->error = CheckVersionInfo(response->enforced, response->unenforced, *context_); in GetKeyCharacteristics()
226 keymaster_algorithm_t* algorithm, keymaster_error_t* error) { in GetKeyFactory() argument
227 *error = KM_ERROR_UNSUPPORTED_ALGORITHM; in GetKeyFactory()
233 *error = KM_ERROR_OK; in GetKeyFactory()
247 response->error = LoadKey(request.key_blob, request.additional_params, &hw_enforced, in BeginOperation()
249 if (response->error != KM_ERROR_OK) in BeginOperation()
252 response->error = KM_ERROR_UNKNOWN_ERROR; in BeginOperation()
257 response->error = KM_ERROR_UNSUPPORTED_PURPOSE; in BeginOperation()
263 factory->CreateOperation(*key, request.additional_params, &response->error)); in BeginOperation()
269 response->error = KM_ERROR_UNKNOWN_ERROR; in BeginOperation()
273 response->error = context_->enforcement_policy()->AuthorizeOperation( in BeginOperation()
276 if (response->error != KM_ERROR_OK) in BeginOperation()
281 response->error = operation->Begin(request.additional_params, &response->output_params); in BeginOperation()
282 if (response->error != KM_ERROR_OK) in BeginOperation()
286 response->error = operation_table_->Add(operation.release(), &response->op_handle); in BeginOperation()
294 response->error = KM_ERROR_INVALID_OPERATION_HANDLE; in UpdateOperation()
300 response->error = context_->enforcement_policy()->AuthorizeOperation( in UpdateOperation()
303 if (response->error != KM_ERROR_OK) { in UpdateOperation()
309 response->error = in UpdateOperation()
312 if (response->error != KM_ERROR_OK) { in UpdateOperation()
323 response->error = KM_ERROR_INVALID_OPERATION_HANDLE; in FinishOperation()
329 response->error = context_->enforcement_policy()->AuthorizeOperation( in FinishOperation()
332 if (response->error != KM_ERROR_OK) { in FinishOperation()
338 response->error = operation->Finish(request.additional_params, request.input, request.signature, in FinishOperation()
350 response->error = KM_ERROR_INVALID_OPERATION_HANDLE; in AbortOperation()
354 response->error = operation->Abort(); in AbortOperation()
365 response->error = in ExportKey()
368 if (response->error != KM_ERROR_OK) in ExportKey()
373 GetKeyFactory(*context_, hw_enforced, sw_enforced, &algorithm, &response->error); in ExportKey()
378 response->error = key_factory->LoadKey(key_material, request.additional_params, hw_enforced, in ExportKey()
380 if (response->error != KM_ERROR_OK) in ExportKey()
385 response->error = key->formatted_key_material(request.key_format, &out_key, &size); in ExportKey()
386 if (response->error == KM_ERROR_OK) { in ExportKey()
400 response->error = LoadKey(request.key_blob, request.attest_params, &tee_enforced, &sw_enforced, in AttestKey()
402 if (response->error != KM_ERROR_OK) in AttestKey()
405 response->error = key->GenerateAttestation(*context_, request.attest_params, tee_enforced, in AttestKey()
414 response->error = context_->UpgradeKeyBlob(KeymasterKeyBlob(request.key_blob), in UpgradeKey()
416 if (response->error != KM_ERROR_OK) in UpgradeKey()
430 response->error = KM_ERROR_UNSUPPORTED_ALGORITHM; in ImportKey()
434 response->error = factory->ImportKey(request.key_description, request.key_format, in ImportKey()
437 if (response->error == KM_ERROR_OK) in ImportKey()
445 response->error = context_->DeleteKey(KeymasterKeyBlob(request.key_blob)); in DeleteKey()
451 response->error = context_->DeleteAllKeys(); in DeleteAllKeys()
464 keymaster_error_t error = context_->ParseKeyBlob(KeymasterKeyBlob(key_blob), additional_params, in LoadKey() local
466 if (error != KM_ERROR_OK) in LoadKey()
467 return error; in LoadKey()
469 error = CheckVersionInfo(*hw_enforced, *sw_enforced, *context_); in LoadKey()
470 if (error != KM_ERROR_OK) in LoadKey()
471 return error; in LoadKey()
474 *factory = GetKeyFactory(*context_, *hw_enforced, *sw_enforced, &algorithm, &error); in LoadKey()
475 if (error != KM_ERROR_OK) in LoadKey()
476 return error; in LoadKey()