Lines Matching refs:wrapped_key
46 UniquePtr<KM_WRAPPED_KEY, KM_WRAPPED_KEY_Delete> wrapped_key(KM_WRAPPED_KEY_new()); in build_wrapped_key() local
47 if (!wrapped_key.get()) return KM_ERROR_MEMORY_ALLOCATION_FAILED; in build_wrapped_key()
49 if (!ASN1_OCTET_STRING_set(wrapped_key->transit_key, transit_key.key_material, in build_wrapped_key()
51 !ASN1_OCTET_STRING_set(wrapped_key->iv, iv.data, iv.data_length) || in build_wrapped_key()
52 !ASN1_OCTET_STRING_set(wrapped_key->secure_key, secure_key.key_material, in build_wrapped_key()
54 !ASN1_OCTET_STRING_set(wrapped_key->tag, tag.data, tag.data_length) || in build_wrapped_key()
55 !ASN1_INTEGER_set(wrapped_key->wrapped_key_description->key_format, key_format)) { in build_wrapped_key()
59 auto err = build_auth_list(auth_set, wrapped_key->wrapped_key_description->auth_list); in build_wrapped_key()
64 int len = i2d_KM_WRAPPED_KEY(wrapped_key.get(), nullptr); in build_wrapped_key()
73 len = i2d_KM_WRAPPED_KEY(wrapped_key.get(), &p); in build_wrapped_key()
82 keymaster_error_t parse_wrapped_key(const KeymasterKeyBlob& wrapped_key, KeymasterBlob* iv, in parse_wrapped_key() argument
92 const uint8_t* tmp = wrapped_key.key_material; in parse_wrapped_key()
94 d2i_KM_WRAPPED_KEY(nullptr, &tmp, wrapped_key.key_material_size)); in parse_wrapped_key()