Lines Matching refs:attr
70 CK_ATTRIBUTE_PTR attr = NULL; in serialize_indirect_attribute() local
81 attr = (CK_ATTRIBUTE_PTR)attribute->pValue; in serialize_indirect_attribute()
88 rv = serialize_ck_attributes(&obj2, attr, count); in serialize_indirect_attribute()
117 CK_ATTRIBUTE_PTR attr = NULL; in deserialize_indirect_attribute() local
125 attr = (CK_ATTRIBUTE_PTR)attribute->pValue; in deserialize_indirect_attribute()
131 return deserialize_ck_attributes(obj->data, attr, count); in deserialize_indirect_attribute()
153 static CK_RV serialize_ck_attribute(struct serializer *obj, CK_ATTRIBUTE *attr) in serialize_ck_attribute() argument
164 if (attr->type == PKCS11_UNDEFINED_ID) in serialize_ck_attribute()
167 switch (attr->type) { in serialize_ck_attribute()
171 return serialize_indirect_attribute(obj, attr); in serialize_ck_attribute()
173 n = attr->ulValueLen / sizeof(CK_ULONG); in serialize_ck_attribute()
179 type = attr->pValue; in serialize_ck_attribute()
191 pkcs11_pdata = attr->pValue; in serialize_ck_attribute()
192 if (!attr->pValue) { in serialize_ck_attribute()
194 } else if (ck_attr_is_ulong(attr->type)) { in serialize_ck_attribute()
197 if (attr->ulValueLen < sizeof(CK_ULONG)) in serialize_ck_attribute()
200 memcpy(&ck_ulong, attr->pValue, sizeof(ck_ulong)); in serialize_ck_attribute()
205 pkcs11_size = attr->ulValueLen; in serialize_ck_attribute()
210 rv = serialize_32b(obj, attr->type); in serialize_ck_attribute()