• Home
  • Raw
  • Download

Lines Matching refs:buf_ptr

41 static bool deserialize_key_blob(keymaster_key_blob_t* key_blob, const uint8_t** buf_ptr,  in deserialize_key_blob()  argument
46 if (!copy_size_and_data_from_buf(buf_ptr, end, &key_blob->key_material_size, in deserialize_key_blob()
61 static bool deserialize_blob(keymaster_blob_t* blob, const uint8_t** buf_ptr, const uint8_t* end) { in deserialize_blob() argument
65 if (!copy_size_and_data_from_buf(buf_ptr, end, &blob->data_length, &deserialized_blob)) in deserialize_blob()
85 bool KeymasterResponse::Deserialize(const uint8_t** buf_ptr, const uint8_t* end) { in Deserialize() argument
86 if (!copy_uint32_from_buf(buf_ptr, end, &error)) in Deserialize()
90 return NonErrorDeserialize(buf_ptr, end); in Deserialize()
107 bool GenerateKeyResponse::NonErrorDeserialize(const uint8_t** buf_ptr, const uint8_t* end) { in NonErrorDeserialize() argument
108 return deserialize_key_blob(&key_blob, buf_ptr, end) && enforced.Deserialize(buf_ptr, end) && in NonErrorDeserialize()
109 unenforced.Deserialize(buf_ptr, end); in NonErrorDeserialize()
129 bool GetKeyCharacteristicsRequest::Deserialize(const uint8_t** buf_ptr, const uint8_t* end) { in Deserialize() argument
130 return deserialize_key_blob(&key_blob, buf_ptr, end) && in Deserialize()
131 additional_params.Deserialize(buf_ptr, end); in Deserialize()
143 bool GetKeyCharacteristicsResponse::NonErrorDeserialize(const uint8_t** buf_ptr, in NonErrorDeserialize() argument
145 return enforced.Deserialize(buf_ptr, end) && unenforced.Deserialize(buf_ptr, end); in NonErrorDeserialize()
163 bool BeginOperationRequest::Deserialize(const uint8_t** buf_ptr, const uint8_t* end) { in Deserialize() argument
164 return copy_uint32_from_buf(buf_ptr, end, &purpose) && in Deserialize()
165 deserialize_key_blob(&key_blob, buf_ptr, end) && in Deserialize()
166 additional_params.Deserialize(buf_ptr, end); in Deserialize()
183 bool BeginOperationResponse::NonErrorDeserialize(const uint8_t** buf_ptr, const uint8_t* end) { in NonErrorDeserialize() argument
184 bool retval = copy_uint64_from_buf(buf_ptr, end, &op_handle); in NonErrorDeserialize()
186 retval = output_params.Deserialize(buf_ptr, end); in NonErrorDeserialize()
205 bool UpdateOperationRequest::Deserialize(const uint8_t** buf_ptr, const uint8_t* end) { in Deserialize() argument
206 bool retval = copy_uint64_from_buf(buf_ptr, end, &op_handle) && input.Deserialize(buf_ptr, end); in Deserialize()
208 retval = additional_params.Deserialize(buf_ptr, end); in Deserialize()
242 bool UpdateOperationResponse::NonErrorDeserialize(const uint8_t** buf_ptr, const uint8_t* end) { in NonErrorDeserialize() argument
243 bool retval = output.Deserialize(buf_ptr, end); in NonErrorDeserialize()
245 retval = copy_uint32_from_buf(buf_ptr, end, &input_consumed); in NonErrorDeserialize()
247 retval = output_params.Deserialize(buf_ptr, end); in NonErrorDeserialize()
282 bool FinishOperationRequest::Deserialize(const uint8_t** buf_ptr, const uint8_t* end) { in Deserialize() argument
284 copy_uint64_from_buf(buf_ptr, end, &op_handle) && signature.Deserialize(buf_ptr, end); in Deserialize()
286 retval = additional_params.Deserialize(buf_ptr, end); in Deserialize()
288 retval = input.Deserialize(buf_ptr, end); in Deserialize()
306 bool FinishOperationResponse::NonErrorDeserialize(const uint8_t** buf_ptr, const uint8_t* end) { in NonErrorDeserialize() argument
307 bool retval = output.Deserialize(buf_ptr, end); in NonErrorDeserialize()
309 retval = output_params.Deserialize(buf_ptr, end); in NonErrorDeserialize()
321 bool AddEntropyRequest::Deserialize(const uint8_t** buf_ptr, const uint8_t* end) { in Deserialize() argument
322 return random_data.Deserialize(buf_ptr, end); in Deserialize()
342 bool ImportKeyRequest::Deserialize(const uint8_t** buf_ptr, const uint8_t* end) { in Deserialize() argument
346 if (!key_description.Deserialize(buf_ptr, end) || in Deserialize()
347 !copy_uint32_from_buf(buf_ptr, end, &key_format) || in Deserialize()
348 !copy_size_and_data_from_buf(buf_ptr, end, &key_data_length, &deserialized_key_material)) in Deserialize()
368 bool ImportKeyResponse::NonErrorDeserialize(const uint8_t** buf_ptr, const uint8_t* end) { in NonErrorDeserialize() argument
369 return deserialize_key_blob(&key_blob, buf_ptr, end) && enforced.Deserialize(buf_ptr, end) && in NonErrorDeserialize()
370 unenforced.Deserialize(buf_ptr, end); in NonErrorDeserialize()
388 bool ExportKeyRequest::Deserialize(const uint8_t** buf_ptr, const uint8_t* end) { in Deserialize() argument
389 return additional_params.Deserialize(buf_ptr, end) && in Deserialize()
390 copy_uint32_from_buf(buf_ptr, end, &key_format) && in Deserialize()
391 deserialize_key_blob(&key_blob, buf_ptr, end); in Deserialize()
408 bool ExportKeyResponse::NonErrorDeserialize(const uint8_t** buf_ptr, const uint8_t* end) { in NonErrorDeserialize() argument
412 if (!copy_size_and_data_from_buf(buf_ptr, end, &key_data_length, &deserialized_key_material)) in NonErrorDeserialize()
430 bool DeleteKeyRequest::Deserialize(const uint8_t** buf_ptr, const uint8_t* end) { in Deserialize() argument
431 return deserialize_key_blob(&key_blob, buf_ptr, end); in Deserialize()
449 bool GetVersionResponse::NonErrorDeserialize(const uint8_t** buf_ptr, const uint8_t* end) { in NonErrorDeserialize() argument
450 if (*buf_ptr + NonErrorSerializedSize() > end) in NonErrorDeserialize()
452 const uint8_t* tmp = *buf_ptr; in NonErrorDeserialize()
456 *buf_ptr = tmp; in NonErrorDeserialize()
477 bool AttestKeyRequest::Deserialize(const uint8_t** buf_ptr, const uint8_t* end) { in Deserialize() argument
478 return deserialize_key_blob(&key_blob, buf_ptr, end) && attest_params.Deserialize(buf_ptr, end); in Deserialize()
527 bool AttestKeyResponse::NonErrorDeserialize(const uint8_t** buf_ptr, const uint8_t* end) { in NonErrorDeserialize() argument
529 if (!copy_uint32_from_buf(buf_ptr, end, &entry_count) || !AllocateChain(entry_count)) in NonErrorDeserialize()
535 if (!copy_size_and_data_from_buf(buf_ptr, end, &data_length, &data)) in NonErrorDeserialize()
561 bool UpgradeKeyRequest::Deserialize(const uint8_t** buf_ptr, const uint8_t* end) { in Deserialize() argument
562 return deserialize_key_blob(&key_blob, buf_ptr, end) && in Deserialize()
563 upgrade_params.Deserialize(buf_ptr, end); in Deserialize()
578 bool UpgradeKeyResponse::NonErrorDeserialize(const uint8_t** buf_ptr, const uint8_t* end) { in NonErrorDeserialize() argument
579 return deserialize_key_blob(&upgraded_key, buf_ptr, end); in NonErrorDeserialize()
591 bool HmacSharingParameters::Deserialize(const uint8_t** buf_ptr, const uint8_t* end) { in Deserialize() argument
592 return deserialize_blob(&seed, buf_ptr, end) && in Deserialize()
593 copy_from_buf(buf_ptr, end, nonce, sizeof(nonce)); in Deserialize()
612 bool HmacSharingParametersArray::Deserialize(const uint8_t** buf_ptr, const uint8_t* end) { in Deserialize() argument
613 if (!copy_uint32_from_buf(buf_ptr, end, &num_params)) return false; in Deserialize()
617 if (!params_array[i].Deserialize(buf_ptr, end)) return false; in Deserialize()
630 bool ComputeSharedHmacResponse::NonErrorDeserialize(const uint8_t** buf_ptr, const uint8_t* end) { in NonErrorDeserialize() argument
631 return deserialize_blob(&sharing_check, buf_ptr, end); in NonErrorDeserialize()
651 bool ImportWrappedKeyRequest::Deserialize(const uint8_t** buf_ptr, const uint8_t* end) { in Deserialize() argument
652 return deserialize_key_blob(&wrapped_key, buf_ptr, end) && in Deserialize()
653 deserialize_key_blob(&wrapping_key, buf_ptr, end) && in Deserialize()
654 deserialize_key_blob(&masking_key, buf_ptr, end) && in Deserialize()
655 additional_params.Deserialize(buf_ptr, end) && in Deserialize()
656 copy_uint64_from_buf(buf_ptr, end, &password_sid) && in Deserialize()
657 copy_uint64_from_buf(buf_ptr, end, &biometric_sid); in Deserialize()
686 bool ImportWrappedKeyResponse::NonErrorDeserialize(const uint8_t** buf_ptr, const uint8_t* end) { in NonErrorDeserialize() argument
687 return deserialize_key_blob(&key_blob, buf_ptr, end) && enforced.Deserialize(buf_ptr, end) && in NonErrorDeserialize()
688 unenforced.Deserialize(buf_ptr, end); in NonErrorDeserialize()
705 bool HardwareAuthToken::Deserialize(const uint8_t** buf_ptr, const uint8_t* end) { in Deserialize() argument
706 return copy_uint64_from_buf(buf_ptr, end, &challenge) && in Deserialize()
707 copy_uint64_from_buf(buf_ptr, end, &user_id) && in Deserialize()
708 copy_uint64_from_buf(buf_ptr, end, &authenticator_id) && in Deserialize()
709 copy_uint32_from_buf(buf_ptr, end, &authenticator_type) && in Deserialize()
710 copy_uint64_from_buf(buf_ptr, end, &timestamp) && // in Deserialize()
711 deserialize_blob(&mac, buf_ptr, end); in Deserialize()
727 bool VerificationToken::Deserialize(const uint8_t** buf_ptr, const uint8_t* end) { in Deserialize() argument
728 return copy_uint64_from_buf(buf_ptr, end, &challenge) && in Deserialize()
729 copy_uint64_from_buf(buf_ptr, end, &timestamp) && in Deserialize()
730 parameters_verified.Deserialize(buf_ptr, end) && in Deserialize()
731 copy_uint32_from_buf(buf_ptr, end, &security_level) && in Deserialize()
732 deserialize_blob(&mac, buf_ptr, end); in Deserialize()