+ if (NULL != attrs)
+ {
+ json_t *attr_arr = json_array ();
+ for (ale = attrs->list_head; NULL != ale; ale = ale->next)
+ {
+ tmp_value =
+ GNUNET_RECLAIM_attribute_value_to_string (ale->attribute->type,
+ ale->attribute->data,
+ ale->attribute->data_size);
+ attr_obj = json_object ();
+ json_object_set_new (attr_obj, "value", json_string (tmp_value));
+ json_object_set_new (attr_obj, "name", json_string (
+ ale->attribute->name));
+
+ json_object_set_new (attr_obj, "flag", json_string ("1")); //FIXME
+ type = GNUNET_RECLAIM_attribute_number_to_typename (ale->attribute->type);
+ json_object_set_new (attr_obj, "type", json_string (type));
+ json_object_set_new (attr_obj, "id", json_string (""));
+ json_object_set_new (attr_obj, "attestation", json_string (""));
+ json_array_append_new (attr_arr, attr_obj);
+ GNUNET_free (tmp_value);
+ }
+ json_object_set_new (attest_obj, "attributes", attr_arr);
+ }
+ json_array_append_new (handle->resp_object, attest_obj);
+ GNUNET_RECLAIM_get_attestations_next (handle->attest_it);