summaryrefslogtreecommitdiff
path: root/src/namestore
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2013-10-16 20:21:27 +0000
committerChristian Grothoff <christian@grothoff.org>2013-10-16 20:21:27 +0000
commitaccfd6bd85274da2f19e7230c8da6b273cfb2ece (patch)
tree60966194963795ff07b4da94f4efb6c46d6a23cf /src/namestore
parent3d670727232e79b7e49a1df7ba9260db4e5798a0 (diff)
downloadgnunet-accfd6bd85274da2f19e7230c8da6b273cfb2ece.tar.gz
gnunet-accfd6bd85274da2f19e7230c8da6b273cfb2ece.zip
-another renaming fest for GNUNET_NAMESTORE_ to GNUNET_GNSRECORD_ symbols that were moved
Diffstat (limited to 'src/namestore')
-rw-r--r--src/namestore/gnunet-namestore-fcfsd.c16
-rw-r--r--src/namestore/gnunet-namestore.c40
-rw-r--r--src/namestore/gnunet-service-namestore.c46
-rw-r--r--src/namestore/namestore_api.c32
-rw-r--r--src/namestore/namestore_api_monitor.c4
-rw-r--r--src/namestore/plugin_namestore_postgres.c18
-rw-r--r--src/namestore/plugin_namestore_sqlite.c20
-rw-r--r--src/namestore/test_namestore_api_cache_block.c14
-rw-r--r--src/namestore/test_namestore_api_lookup_public.c10
-rw-r--r--src/namestore/test_namestore_api_monitoring.c18
-rw-r--r--src/namestore/test_namestore_api_monitoring_existing.c18
-rw-r--r--src/namestore/test_namestore_api_put.c10
-rw-r--r--src/namestore/test_namestore_api_remove.c10
-rw-r--r--src/namestore/test_namestore_api_store.c10
-rw-r--r--src/namestore/test_namestore_api_store_update.c16
-rw-r--r--src/namestore/test_namestore_api_zone_iteration.c22
-rw-r--r--src/namestore/test_namestore_api_zone_iteration_specific_zone.c20
-rw-r--r--src/namestore/test_namestore_api_zone_iteration_stop.c22
-rw-r--r--src/namestore/test_namestore_api_zone_to_name.c4
-rw-r--r--src/namestore/test_plugin_namestore.c4
20 files changed, 177 insertions, 177 deletions
diff --git a/src/namestore/gnunet-namestore-fcfsd.c b/src/namestore/gnunet-namestore-fcfsd.c
index 701cdd558..198d0a9dc 100644
--- a/src/namestore/gnunet-namestore-fcfsd.c
+++ b/src/namestore/gnunet-namestore-fcfsd.c
@@ -246,7 +246,7 @@ iterate_cb (void *cls,
246 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, 246 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key,
247 const char *name, 247 const char *name,
248 unsigned int rd_len, 248 unsigned int rd_len,
249 const struct GNUNET_NAMESTORE_RecordData *rd) 249 const struct GNUNET_GNSRECORD_Data *rd)
250{ 250{
251 struct ZoneinfoRequest *zr = cls; 251 struct ZoneinfoRequest *zr = cls;
252 struct MHD_Response *response; 252 struct MHD_Response *response;
@@ -508,10 +508,10 @@ zone_to_name_cb (void *cls,
508 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, 508 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key,
509 const char *name, 509 const char *name,
510 unsigned int rd_count, 510 unsigned int rd_count,
511 const struct GNUNET_NAMESTORE_RecordData *rd) 511 const struct GNUNET_GNSRECORD_Data *rd)
512{ 512{
513 struct Request *request = cls; 513 struct Request *request = cls;
514 struct GNUNET_NAMESTORE_RecordData r; 514 struct GNUNET_GNSRECORD_Data r;
515 struct GNUNET_CRYPTO_EcdsaPublicKey pub; 515 struct GNUNET_CRYPTO_EcdsaPublicKey pub;
516 516
517 request->qe = NULL; 517 request->qe = NULL;
@@ -530,7 +530,7 @@ zone_to_name_cb (void *cls,
530 r.data_size = sizeof (pub); 530 r.data_size = sizeof (pub);
531 r.expiration_time = UINT64_MAX; 531 r.expiration_time = UINT64_MAX;
532 r.record_type = GNUNET_GNSRECORD_TYPE_PKEY; 532 r.record_type = GNUNET_GNSRECORD_TYPE_PKEY;
533 r.flags = GNUNET_NAMESTORE_RF_NONE; 533 r.flags = GNUNET_GNSRECORD_RF_NONE;
534 request->qe = GNUNET_NAMESTORE_records_store (ns, 534 request->qe = GNUNET_NAMESTORE_records_store (ns,
535 &fcfs_zone_pkey, 535 &fcfs_zone_pkey,
536 request->domain_name, 536 request->domain_name,
@@ -552,7 +552,7 @@ zone_to_name_cb (void *cls,
552static void 552static void
553lookup_result_processor (void *cls, 553lookup_result_processor (void *cls,
554 unsigned int rd_count, 554 unsigned int rd_count,
555 const struct GNUNET_NAMESTORE_RecordData *rd) 555 const struct GNUNET_GNSRECORD_Data *rd)
556{ 556{
557 struct Request *request = cls; 557 struct Request *request = cls;
558 struct GNUNET_CRYPTO_EcdsaPublicKey pub; 558 struct GNUNET_CRYPTO_EcdsaPublicKey pub;
@@ -594,7 +594,7 @@ lookup_result_processor (void *cls,
594 */ 594 */
595static void 595static void
596lookup_block_processor (void *cls, 596lookup_block_processor (void *cls,
597 const struct GNUNET_NAMESTORE_Block *block) 597 const struct GNUNET_GNSRECORD_Block *block)
598{ 598{
599 struct Request *request = cls; 599 struct Request *request = cls;
600 struct GNUNET_CRYPTO_EcdsaPublicKey pub; 600 struct GNUNET_CRYPTO_EcdsaPublicKey pub;
@@ -608,7 +608,7 @@ lookup_block_processor (void *cls,
608 GNUNET_CRYPTO_ecdsa_key_get_public (&fcfs_zone_pkey, 608 GNUNET_CRYPTO_ecdsa_key_get_public (&fcfs_zone_pkey,
609 &pub); 609 &pub);
610 if (GNUNET_OK != 610 if (GNUNET_OK !=
611 GNUNET_NAMESTORE_block_decrypt (block, 611 GNUNET_GNSRECORD_block_decrypt (block,
612 &pub, 612 &pub,
613 request->domain_name, 613 request->domain_name,
614 &lookup_result_processor, 614 &lookup_result_processor,
@@ -738,7 +738,7 @@ create_response (void *cls,
738 request->phase = RP_LOOKUP; 738 request->phase = RP_LOOKUP;
739 GNUNET_CRYPTO_ecdsa_key_get_public (&fcfs_zone_pkey, 739 GNUNET_CRYPTO_ecdsa_key_get_public (&fcfs_zone_pkey,
740 &pub); 740 &pub);
741 GNUNET_NAMESTORE_query_from_public_key (&pub, 741 GNUNET_GNSRECORD_query_from_public_key (&pub,
742 request->domain_name, 742 request->domain_name,
743 &query); 743 &query);
744 request->qe = GNUNET_NAMESTORE_lookup_block (ns, 744 request->qe = GNUNET_NAMESTORE_lookup_block (ns,
diff --git a/src/namestore/gnunet-namestore.c b/src/namestore/gnunet-namestore.c
index 1ed203f1d..45e721b89 100644
--- a/src/namestore/gnunet-namestore.c
+++ b/src/namestore/gnunet-namestore.c
@@ -100,12 +100,12 @@ static struct GNUNET_NAMESTORE_ZoneIterator *list_it;
100static int del; 100static int del;
101 101
102/** 102/**
103 * Is record public (opposite of #GNUNET_NAMESTORE_RF_PRIVATE) 103 * Is record public (opposite of #GNUNET_GNSRECORD_RF_PRIVATE)
104 */ 104 */
105static int public; 105static int public;
106 106
107/** 107/**
108 * Is record a shadow record (#GNUNET_NAMESTORE_RF_SHADOW_RECORD) 108 * Is record a shadow record (#GNUNET_GNSRECORD_RF_SHADOW_RECORD)
109 */ 109 */
110static int shadow; 110static int shadow;
111 111
@@ -338,7 +338,7 @@ display_record (void *cls,
338 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, 338 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key,
339 const char *name, 339 const char *name,
340 unsigned int rd_len, 340 unsigned int rd_len,
341 const struct GNUNET_NAMESTORE_RecordData *rd) 341 const struct GNUNET_GNSRECORD_Data *rd)
342{ 342{
343 const char *typestring; 343 const char *typestring;
344 char *s; 344 char *s;
@@ -368,7 +368,7 @@ display_record (void *cls,
368 (unsigned int) rd[i].record_type); 368 (unsigned int) rd[i].record_type);
369 continue; 369 continue;
370 } 370 }
371 if (0 != (rd[i].flags & GNUNET_NAMESTORE_RF_RELATIVE_EXPIRATION)) 371 if (0 != (rd[i].flags & GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION))
372 { 372 {
373 rt.rel_value_us = rd[i].expiration_time; 373 rt.rel_value_us = rd[i].expiration_time;
374 ets = GNUNET_STRINGS_relative_time_to_string (rt, GNUNET_YES); 374 ets = GNUNET_STRINGS_relative_time_to_string (rt, GNUNET_YES);
@@ -417,10 +417,10 @@ get_existing_record (void *cls,
417 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, 417 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key,
418 const char *rec_name, 418 const char *rec_name,
419 unsigned int rd_count, 419 unsigned int rd_count,
420 const struct GNUNET_NAMESTORE_RecordData *rd) 420 const struct GNUNET_GNSRECORD_Data *rd)
421{ 421{
422 struct GNUNET_NAMESTORE_RecordData rdn[rd_count + 1]; 422 struct GNUNET_GNSRECORD_Data rdn[rd_count + 1];
423 struct GNUNET_NAMESTORE_RecordData *rde; 423 struct GNUNET_GNSRECORD_Data *rde;
424 424
425 if ( (NULL != zone_key) && 425 if ( (NULL != zone_key) &&
426 (0 != strcmp (rec_name, name)) ) 426 (0 != strcmp (rec_name, name)) )
@@ -428,8 +428,8 @@ get_existing_record (void *cls,
428 GNUNET_NAMESTORE_zone_iterator_next (add_zit); 428 GNUNET_NAMESTORE_zone_iterator_next (add_zit);
429 return; 429 return;
430 } 430 }
431 memset (rdn, 0, sizeof (struct GNUNET_NAMESTORE_RecordData)); 431 memset (rdn, 0, sizeof (struct GNUNET_GNSRECORD_Data));
432 memcpy (&rdn[1], rd, rd_count * sizeof (struct GNUNET_NAMESTORE_RecordData)); 432 memcpy (&rdn[1], rd, rd_count * sizeof (struct GNUNET_GNSRECORD_Data));
433 /* FIXME: should add some logic to overwrite records if there 433 /* FIXME: should add some logic to overwrite records if there
434 can only be one record of a particular type, and to check 434 can only be one record of a particular type, and to check
435 if the combination of records is valid to begin with... */ 435 if the combination of records is valid to begin with... */
@@ -438,13 +438,13 @@ get_existing_record (void *cls,
438 rde->data_size = data_size; 438 rde->data_size = data_size;
439 rde->record_type = type; 439 rde->record_type = type;
440 if (1 != shadow) 440 if (1 != shadow)
441 rde->flags |= GNUNET_NAMESTORE_RF_SHADOW_RECORD; 441 rde->flags |= GNUNET_GNSRECORD_RF_SHADOW_RECORD;
442 if (1 != public) 442 if (1 != public)
443 rde->flags |= GNUNET_NAMESTORE_RF_PRIVATE; 443 rde->flags |= GNUNET_GNSRECORD_RF_PRIVATE;
444 if (GNUNET_YES == etime_is_rel) 444 if (GNUNET_YES == etime_is_rel)
445 { 445 {
446 rde->expiration_time = etime_rel.rel_value_us; 446 rde->expiration_time = etime_rel.rel_value_us;
447 rde->flags |= GNUNET_NAMESTORE_RF_RELATIVE_EXPIRATION; 447 rde->flags |= GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION;
448 } 448 }
449 else if (GNUNET_NO == etime_is_rel) 449 else if (GNUNET_NO == etime_is_rel)
450 rde->expiration_time = etime_abs.abs_value_us; 450 rde->expiration_time = etime_abs.abs_value_us;
@@ -477,7 +477,7 @@ get_existing_record (void *cls,
477static void 477static void
478display_records_from_block (void *cls, 478display_records_from_block (void *cls,
479 unsigned int rd_len, 479 unsigned int rd_len,
480 const struct GNUNET_NAMESTORE_RecordData *rd) 480 const struct GNUNET_GNSRECORD_Data *rd)
481{ 481{
482 const char *typestring; 482 const char *typestring;
483 char *s; 483 char *s;
@@ -523,7 +523,7 @@ display_records_from_block (void *cls,
523 */ 523 */
524static void 524static void
525handle_block (void *cls, 525handle_block (void *cls,
526 const struct GNUNET_NAMESTORE_Block *block) 526 const struct GNUNET_GNSRECORD_Block *block)
527{ 527{
528 struct GNUNET_CRYPTO_EcdsaPublicKey zone_pubkey; 528 struct GNUNET_CRYPTO_EcdsaPublicKey zone_pubkey;
529 529
@@ -536,7 +536,7 @@ handle_block (void *cls,
536 "No matching block found\n"); 536 "No matching block found\n");
537 } 537 }
538 else if (GNUNET_OK != 538 else if (GNUNET_OK !=
539 GNUNET_NAMESTORE_block_decrypt (block, 539 GNUNET_GNSRECORD_block_decrypt (block,
540 &zone_pubkey, 540 &zone_pubkey,
541 name, 541 name,
542 &display_records_from_block, 542 &display_records_from_block,
@@ -564,7 +564,7 @@ handle_reverse_lookup (void *cls,
564 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, 564 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone,
565 const char *label, 565 const char *label,
566 unsigned int rd_count, 566 unsigned int rd_count,
567 const struct GNUNET_NAMESTORE_RecordData *rd) 567 const struct GNUNET_GNSRECORD_Data *rd)
568{ 568{
569 reverse_qe = NULL; 569 reverse_qe = NULL;
570 if (NULL == label) 570 if (NULL == label)
@@ -593,7 +593,7 @@ testservice_task (void *cls,
593{ 593{
594 const struct GNUNET_CONFIGURATION_Handle *cfg = cls; 594 const struct GNUNET_CONFIGURATION_Handle *cfg = cls;
595 struct GNUNET_CRYPTO_EcdsaPublicKey pub; 595 struct GNUNET_CRYPTO_EcdsaPublicKey pub;
596 struct GNUNET_NAMESTORE_RecordData rd; 596 struct GNUNET_GNSRECORD_Data rd;
597 597
598 if (GNUNET_YES != result) 598 if (GNUNET_YES != result)
599 { 599 {
@@ -743,7 +743,7 @@ testservice_task (void *cls,
743 743
744 GNUNET_CRYPTO_ecdsa_key_get_public (&zone_pkey, 744 GNUNET_CRYPTO_ecdsa_key_get_public (&zone_pkey,
745 &zone_pubkey); 745 &zone_pubkey);
746 GNUNET_NAMESTORE_query_from_public_key (&zone_pubkey, 746 GNUNET_GNSRECORD_query_from_public_key (&zone_pubkey,
747 name, 747 name,
748 &query); 748 &query);
749 list_qe = GNUNET_NAMESTORE_lookup_block (ns, 749 list_qe = GNUNET_NAMESTORE_lookup_block (ns,
@@ -799,14 +799,14 @@ testservice_task (void *cls,
799 if (GNUNET_YES == etime_is_rel) 799 if (GNUNET_YES == etime_is_rel)
800 { 800 {
801 rd.expiration_time = etime_rel.rel_value_us; 801 rd.expiration_time = etime_rel.rel_value_us;
802 rd.flags |= GNUNET_NAMESTORE_RF_RELATIVE_EXPIRATION; 802 rd.flags |= GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION;
803 } 803 }
804 else if (GNUNET_NO == etime_is_rel) 804 else if (GNUNET_NO == etime_is_rel)
805 rd.expiration_time = etime_abs.abs_value_us; 805 rd.expiration_time = etime_abs.abs_value_us;
806 else 806 else
807 rd.expiration_time = GNUNET_TIME_UNIT_FOREVER_ABS.abs_value_us; 807 rd.expiration_time = GNUNET_TIME_UNIT_FOREVER_ABS.abs_value_us;
808 if (1 != shadow) 808 if (1 != shadow)
809 rd.flags |= GNUNET_NAMESTORE_RF_SHADOW_RECORD; 809 rd.flags |= GNUNET_GNSRECORD_RF_SHADOW_RECORD;
810 add_qe_uri = GNUNET_NAMESTORE_records_store (ns, 810 add_qe_uri = GNUNET_NAMESTORE_records_store (ns,
811 &zone_pkey, 811 &zone_pkey,
812 sname, 812 sname,
diff --git a/src/namestore/gnunet-service-namestore.c b/src/namestore/gnunet-service-namestore.c
index 2cce92635..869be75d5 100644
--- a/src/namestore/gnunet-service-namestore.c
+++ b/src/namestore/gnunet-service-namestore.c
@@ -347,14 +347,14 @@ struct LookupBlockContext
347 347
348 348
349/** 349/**
350 * A #GNUNET_NAMESTORE_BlockCallback for name lookups in #handle_lookup_block 350 * A #GNUNET_GNSRECORD_BlockCallback for name lookups in #handle_lookup_block
351 * 351 *
352 * @param cls a `struct LookupNameContext *` with information about the request 352 * @param cls a `struct LookupNameContext *` with information about the request
353 * @param block the block 353 * @param block the block
354 */ 354 */
355static void 355static void
356handle_lookup_block_it (void *cls, 356handle_lookup_block_it (void *cls,
357 const struct GNUNET_NAMESTORE_Block *block) 357 const struct GNUNET_GNSRECORD_Block *block)
358{ 358{
359 struct LookupBlockContext *lnc = cls; 359 struct LookupBlockContext *lnc = cls;
360 struct LookupBlockResponseMessage *r; 360 struct LookupBlockResponseMessage *r;
@@ -455,7 +455,7 @@ handle_block_cache (void *cls,
455 struct NamestoreClient *nc; 455 struct NamestoreClient *nc;
456 const struct BlockCacheMessage *rp_msg; 456 const struct BlockCacheMessage *rp_msg;
457 struct BlockCacheResponseMessage rpr_msg; 457 struct BlockCacheResponseMessage rpr_msg;
458 struct GNUNET_NAMESTORE_Block *block; 458 struct GNUNET_GNSRECORD_Block *block;
459 size_t esize; 459 size_t esize;
460 int res; 460 int res;
461 461
@@ -468,7 +468,7 @@ handle_block_cache (void *cls,
468 } 468 }
469 rp_msg = (const struct BlockCacheMessage *) message; 469 rp_msg = (const struct BlockCacheMessage *) message;
470 esize = ntohs (rp_msg->gns_header.header.size) - sizeof (struct BlockCacheMessage); 470 esize = ntohs (rp_msg->gns_header.header.size) - sizeof (struct BlockCacheMessage);
471 block = GNUNET_malloc (sizeof (struct GNUNET_NAMESTORE_Block) + esize); 471 block = GNUNET_malloc (sizeof (struct GNUNET_GNSRECORD_Block) + esize);
472 block->signature = rp_msg->signature; 472 block->signature = rp_msg->signature;
473 block->derived_key = rp_msg->derived_key; 473 block->derived_key = rp_msg->derived_key;
474 block->purpose.size = htonl (sizeof (struct GNUNET_CRYPTO_EccSignaturePurpose) + 474 block->purpose.size = htonl (sizeof (struct GNUNET_CRYPTO_EccSignaturePurpose) +
@@ -515,7 +515,7 @@ send_lookup_response (struct GNUNET_SERVER_NotificationContext *nc,
515 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, 515 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key,
516 const char *name, 516 const char *name,
517 unsigned int rd_count, 517 unsigned int rd_count,
518 const struct GNUNET_NAMESTORE_RecordData *rd) 518 const struct GNUNET_GNSRECORD_Data *rd)
519{ 519{
520 struct RecordResultMessage *zir_msg; 520 struct RecordResultMessage *zir_msg;
521 size_t name_len; 521 size_t name_len;
@@ -525,7 +525,7 @@ send_lookup_response (struct GNUNET_SERVER_NotificationContext *nc,
525 char *rd_ser; 525 char *rd_ser;
526 526
527 name_len = strlen (name) + 1; 527 name_len = strlen (name) + 1;
528 rd_ser_len = GNUNET_NAMESTORE_records_get_size (rd_count, rd); 528 rd_ser_len = GNUNET_GNSRECORD_records_get_size (rd_count, rd);
529 msg_size = sizeof (struct RecordResultMessage) + name_len + rd_ser_len; 529 msg_size = sizeof (struct RecordResultMessage) + name_len + rd_ser_len;
530 530
531 zir_msg = GNUNET_malloc (msg_size); 531 zir_msg = GNUNET_malloc (msg_size);
@@ -539,7 +539,7 @@ send_lookup_response (struct GNUNET_SERVER_NotificationContext *nc,
539 name_tmp = (char *) &zir_msg[1]; 539 name_tmp = (char *) &zir_msg[1];
540 memcpy (name_tmp, name, name_len); 540 memcpy (name_tmp, name, name_len);
541 rd_ser = &name_tmp[name_len]; 541 rd_ser = &name_tmp[name_len];
542 GNUNET_NAMESTORE_records_serialize (rd_count, rd, rd_ser_len, rd_ser); 542 GNUNET_GNSRECORD_records_serialize (rd_count, rd, rd_ser_len, rd_ser);
543 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 543 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
544 "Sending `%s' message with %u records and size %u\n", 544 "Sending `%s' message with %u records and size %u\n",
545 "RECORD_RESULT", 545 "RECORD_RESULT",
@@ -566,18 +566,18 @@ static void
566refresh_block (const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, 566refresh_block (const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key,
567 const char *name, 567 const char *name,
568 unsigned int rd_count, 568 unsigned int rd_count,
569 const struct GNUNET_NAMESTORE_RecordData *rd) 569 const struct GNUNET_GNSRECORD_Data *rd)
570{ 570{
571 struct GNUNET_NAMESTORE_Block *block; 571 struct GNUNET_GNSRECORD_Block *block;
572 572
573 if (0 == rd_count) 573 if (0 == rd_count)
574 block = GNUNET_NAMESTORE_block_create (zone_key, 574 block = GNUNET_GNSRECORD_block_create (zone_key,
575 GNUNET_TIME_UNIT_ZERO_ABS, 575 GNUNET_TIME_UNIT_ZERO_ABS,
576 name, 576 name,
577 rd, rd_count); 577 rd, rd_count);
578 else 578 else
579 block = GNUNET_NAMESTORE_block_create (zone_key, 579 block = GNUNET_GNSRECORD_block_create (zone_key,
580 GNUNET_NAMESTORE_record_get_expiration_time (rd_count, 580 GNUNET_GNSRECORD_record_get_expiration_time (rd_count,
581 rd), 581 rd),
582 name, 582 name,
583 rd, rd_count); 583 rd, rd_count);
@@ -659,10 +659,10 @@ handle_record_store (void *cls,
659 return; 659 return;
660 } 660 }
661 { 661 {
662 struct GNUNET_NAMESTORE_RecordData rd[rd_count]; 662 struct GNUNET_GNSRECORD_Data rd[rd_count];
663 663
664 if (GNUNET_OK != 664 if (GNUNET_OK !=
665 GNUNET_NAMESTORE_records_deserialize (rd_ser_len, rd_ser, rd_count, rd)) 665 GNUNET_GNSRECORD_records_deserialize (rd_ser_len, rd_ser, rd_count, rd))
666 { 666 {
667 GNUNET_break (0); 667 GNUNET_break (0);
668 GNUNET_SERVER_receive_done (client, GNUNET_SYSERR); 668 GNUNET_SERVER_receive_done (client, GNUNET_SYSERR);
@@ -672,7 +672,7 @@ handle_record_store (void *cls,
672 /* Extracting and converting private key */ 672 /* Extracting and converting private key */
673 GNUNET_CRYPTO_ecdsa_key_get_public (&rp_msg->private_key, 673 GNUNET_CRYPTO_ecdsa_key_get_public (&rp_msg->private_key,
674 &pubkey); 674 &pubkey);
675 conv_name = GNUNET_NAMESTORE_normalize_string (name_tmp); 675 conv_name = GNUNET_GNSRECORD_string_to_lowercase (name_tmp);
676 if (NULL == conv_name) 676 if (NULL == conv_name)
677 { 677 {
678 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, 678 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
@@ -684,7 +684,7 @@ handle_record_store (void *cls,
684 "Creating %u records for name `%s' in zone `%s'\n", 684 "Creating %u records for name `%s' in zone `%s'\n",
685 (unsigned int) rd_count, 685 (unsigned int) rd_count,
686 conv_name, 686 conv_name,
687 GNUNET_NAMESTORE_z2s (&pubkey)); 687 GNUNET_GNSRECORD_z2s (&pubkey));
688 688
689 if ( (0 == rd_count) && 689 if ( (0 == rd_count) &&
690 (GNUNET_NO == 690 (GNUNET_NO ==
@@ -777,7 +777,7 @@ handle_zone_to_name_it (void *cls,
777 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, 777 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key,
778 const char *name, 778 const char *name,
779 unsigned int rd_count, 779 unsigned int rd_count,
780 const struct GNUNET_NAMESTORE_RecordData *rd) 780 const struct GNUNET_GNSRECORD_Data *rd)
781{ 781{
782 struct ZoneToNameCtx *ztn_ctx = cls; 782 struct ZoneToNameCtx *ztn_ctx = cls;
783 struct ZoneToNameResponseMessage *ztnr_msg; 783 struct ZoneToNameResponseMessage *ztnr_msg;
@@ -793,7 +793,7 @@ handle_zone_to_name_it (void *cls,
793 name); 793 name);
794 res = GNUNET_YES; 794 res = GNUNET_YES;
795 name_len = (NULL == name) ? 0 : strlen (name) + 1; 795 name_len = (NULL == name) ? 0 : strlen (name) + 1;
796 rd_ser_len = GNUNET_NAMESTORE_records_get_size (rd_count, rd); 796 rd_ser_len = GNUNET_GNSRECORD_records_get_size (rd_count, rd);
797 msg_size = sizeof (struct ZoneToNameResponseMessage) + name_len + rd_ser_len; 797 msg_size = sizeof (struct ZoneToNameResponseMessage) + name_len + rd_ser_len;
798 if (msg_size >= GNUNET_SERVER_MAX_MESSAGE_SIZE) 798 if (msg_size >= GNUNET_SERVER_MAX_MESSAGE_SIZE)
799 { 799 {
@@ -814,7 +814,7 @@ handle_zone_to_name_it (void *cls,
814 if (NULL != name) 814 if (NULL != name)
815 memcpy (name_tmp, name, name_len); 815 memcpy (name_tmp, name, name_len);
816 rd_tmp = &name_tmp[name_len]; 816 rd_tmp = &name_tmp[name_len];
817 GNUNET_NAMESTORE_records_serialize (rd_count, rd, rd_ser_len, rd_tmp); 817 GNUNET_GNSRECORD_records_serialize (rd_count, rd, rd_ser_len, rd_tmp);
818 ztn_ctx->success = GNUNET_OK; 818 ztn_ctx->success = GNUNET_OK;
819 GNUNET_SERVER_notification_context_unicast (snc, ztn_ctx->nc->client, 819 GNUNET_SERVER_notification_context_unicast (snc, ztn_ctx->nc->client,
820 &ztnr_msg->gns_header.header, 820 &ztnr_msg->gns_header.header,
@@ -939,7 +939,7 @@ zone_iteraterate_proc (void *cls,
939 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, 939 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key,
940 const char *name, 940 const char *name,
941 unsigned int rd_count, 941 unsigned int rd_count,
942 const struct GNUNET_NAMESTORE_RecordData *rd) 942 const struct GNUNET_GNSRECORD_Data *rd)
943{ 943{
944 struct ZoneIterationProcResult *proc = cls; 944 struct ZoneIterationProcResult *proc = cls;
945 unsigned int i; 945 unsigned int i;
@@ -969,8 +969,8 @@ zone_iteraterate_proc (void *cls,
969 rd); 969 rd);
970 do_refresh_block = GNUNET_NO; 970 do_refresh_block = GNUNET_NO;
971 for (i=0;i<rd_count;i++) 971 for (i=0;i<rd_count;i++)
972 if( (0 != (rd[i].flags & GNUNET_NAMESTORE_RF_RELATIVE_EXPIRATION)) && 972 if( (0 != (rd[i].flags & GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION)) &&
973 (0 == (rd[i].flags & GNUNET_NAMESTORE_RF_PENDING)) ) 973 (0 == (rd[i].flags & GNUNET_GNSRECORD_RF_PENDING)) )
974 { 974 {
975 do_refresh_block = GNUNET_YES; 975 do_refresh_block = GNUNET_YES;
976 break; 976 break;
@@ -1201,7 +1201,7 @@ monitor_iterate_cb (void *cls,
1201 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, 1201 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key,
1202 const char *name, 1202 const char *name,
1203 unsigned int rd_count, 1203 unsigned int rd_count,
1204 const struct GNUNET_NAMESTORE_RecordData *rd) 1204 const struct GNUNET_GNSRECORD_Data *rd)
1205{ 1205{
1206 struct ZoneMonitor *zm = cls; 1206 struct ZoneMonitor *zm = cls;
1207 1207
diff --git a/src/namestore/namestore_api.c b/src/namestore/namestore_api.c
index c4282ec71..03e40ca17 100644
--- a/src/namestore/namestore_api.c
+++ b/src/namestore/namestore_api.c
@@ -85,7 +85,7 @@ struct GNUNET_NAMESTORE_QueueEntry
85 /** 85 /**
86 * Function to call with the blocks we get back; or NULL. 86 * Function to call with the blocks we get back; or NULL.
87 */ 87 */
88 GNUNET_NAMESTORE_BlockProcessor block_proc; 88 GNUNET_GNSRECORD_BlockProcessor block_proc;
89 89
90 /** 90 /**
91 * Closure for @e block_proc. 91 * Closure for @e block_proc.
@@ -271,8 +271,8 @@ handle_lookup_block_response (struct GNUNET_NAMESTORE_QueueEntry *qe,
271 const struct LookupBlockResponseMessage *msg, 271 const struct LookupBlockResponseMessage *msg,
272 size_t size) 272 size_t size)
273{ 273{
274 struct GNUNET_NAMESTORE_Block *block; 274 struct GNUNET_GNSRECORD_Block *block;
275 char buf[size + sizeof (struct GNUNET_NAMESTORE_Block) 275 char buf[size + sizeof (struct GNUNET_GNSRECORD_Block)
276 - sizeof (struct LookupBlockResponseMessage)]; 276 - sizeof (struct LookupBlockResponseMessage)];
277 277
278 LOG (GNUNET_ERROR_TYPE_DEBUG, 278 LOG (GNUNET_ERROR_TYPE_DEBUG,
@@ -286,7 +286,7 @@ handle_lookup_block_response (struct GNUNET_NAMESTORE_QueueEntry *qe,
286 return GNUNET_OK; 286 return GNUNET_OK;
287 } 287 }
288 288
289 block = (struct GNUNET_NAMESTORE_Block *) buf; 289 block = (struct GNUNET_GNSRECORD_Block *) buf;
290 block->signature = msg->signature; 290 block->signature = msg->signature;
291 block->derived_key = msg->derived_key; 291 block->derived_key = msg->derived_key;
292 block->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_GNS_RECORD_SIGN); 292 block->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_GNS_RECORD_SIGN);
@@ -298,7 +298,7 @@ handle_lookup_block_response (struct GNUNET_NAMESTORE_QueueEntry *qe,
298 &msg[1], 298 &msg[1],
299 size - sizeof (struct LookupBlockResponseMessage)); 299 size - sizeof (struct LookupBlockResponseMessage));
300 if (GNUNET_OK != 300 if (GNUNET_OK !=
301 GNUNET_NAMESTORE_block_verify (block)) 301 GNUNET_GNSRECORD_block_verify (block))
302 { 302 {
303 GNUNET_break (0); 303 GNUNET_break (0);
304 return GNUNET_SYSERR; 304 return GNUNET_SYSERR;
@@ -419,9 +419,9 @@ handle_record_result (struct GNUNET_NAMESTORE_QueueEntry *qe,
419 } 419 }
420 rd_tmp = &name[name_len]; 420 rd_tmp = &name[name_len];
421 { 421 {
422 struct GNUNET_NAMESTORE_RecordData rd[rd_count]; 422 struct GNUNET_GNSRECORD_Data rd[rd_count];
423 423
424 if (GNUNET_OK != GNUNET_NAMESTORE_records_deserialize(rd_len, rd_tmp, rd_count, rd)) 424 if (GNUNET_OK != GNUNET_GNSRECORD_records_deserialize(rd_len, rd_tmp, rd_count, rd))
425 { 425 {
426 GNUNET_break (0); 426 GNUNET_break (0);
427 return GNUNET_SYSERR; 427 return GNUNET_SYSERR;
@@ -490,9 +490,9 @@ handle_zone_to_name_response (struct GNUNET_NAMESTORE_QueueEntry *qe,
490 } 490 }
491 rd_tmp = &name_tmp[name_len]; 491 rd_tmp = &name_tmp[name_len];
492 { 492 {
493 struct GNUNET_NAMESTORE_RecordData rd[rd_count]; 493 struct GNUNET_GNSRECORD_Data rd[rd_count];
494 494
495 if (GNUNET_OK != GNUNET_NAMESTORE_records_deserialize(rd_ser_len, rd_tmp, rd_count, rd)) 495 if (GNUNET_OK != GNUNET_GNSRECORD_records_deserialize(rd_ser_len, rd_tmp, rd_count, rd))
496 { 496 {
497 GNUNET_break (0); 497 GNUNET_break (0);
498 return GNUNET_SYSERR; 498 return GNUNET_SYSERR;
@@ -633,9 +633,9 @@ handle_zone_iteration_response (struct GNUNET_NAMESTORE_ZoneIterator *ze,
633 } 633 }
634 rd_ser_tmp = (const char *) &name_tmp[name_len]; 634 rd_ser_tmp = (const char *) &name_tmp[name_len];
635 { 635 {
636 struct GNUNET_NAMESTORE_RecordData rd[rd_count]; 636 struct GNUNET_GNSRECORD_Data rd[rd_count];
637 637
638 if (GNUNET_OK != GNUNET_NAMESTORE_records_deserialize (rd_len, 638 if (GNUNET_OK != GNUNET_GNSRECORD_records_deserialize (rd_len,
639 rd_ser_tmp, 639 rd_ser_tmp,
640 rd_count, 640 rd_count,
641 rd)) 641 rd))
@@ -1020,7 +1020,7 @@ GNUNET_NAMESTORE_disconnect (struct GNUNET_NAMESTORE_Handle *h)
1020 */ 1020 */
1021struct GNUNET_NAMESTORE_QueueEntry * 1021struct GNUNET_NAMESTORE_QueueEntry *
1022GNUNET_NAMESTORE_block_cache (struct GNUNET_NAMESTORE_Handle *h, 1022GNUNET_NAMESTORE_block_cache (struct GNUNET_NAMESTORE_Handle *h,
1023 const struct GNUNET_NAMESTORE_Block *block, 1023 const struct GNUNET_GNSRECORD_Block *block,
1024 GNUNET_NAMESTORE_ContinuationWithStatus cont, 1024 GNUNET_NAMESTORE_ContinuationWithStatus cont,
1025 void *cont_cls) 1025 void *cont_cls)
1026{ 1026{
@@ -1085,7 +1085,7 @@ GNUNET_NAMESTORE_records_store (struct GNUNET_NAMESTORE_Handle *h,
1085 const struct GNUNET_CRYPTO_EcdsaPrivateKey *pkey, 1085 const struct GNUNET_CRYPTO_EcdsaPrivateKey *pkey,
1086 const char *label, 1086 const char *label,
1087 unsigned int rd_count, 1087 unsigned int rd_count,
1088 const struct GNUNET_NAMESTORE_RecordData *rd, 1088 const struct GNUNET_GNSRECORD_Data *rd,
1089 GNUNET_NAMESTORE_ContinuationWithStatus cont, 1089 GNUNET_NAMESTORE_ContinuationWithStatus cont,
1090 void *cont_cls) 1090 void *cont_cls)
1091{ 1091{
@@ -1117,7 +1117,7 @@ GNUNET_NAMESTORE_records_store (struct GNUNET_NAMESTORE_Handle *h,
1117 GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, qe); 1117 GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, qe);
1118 1118
1119 /* setup msg */ 1119 /* setup msg */
1120 rd_ser_len = GNUNET_NAMESTORE_records_get_size (rd_count, rd); 1120 rd_ser_len = GNUNET_GNSRECORD_records_get_size (rd_count, rd);
1121 msg_size = sizeof (struct RecordStoreMessage) + name_len + rd_ser_len; 1121 msg_size = sizeof (struct RecordStoreMessage) + name_len + rd_ser_len;
1122 pe = GNUNET_malloc (sizeof (struct PendingMessage) + msg_size); 1122 pe = GNUNET_malloc (sizeof (struct PendingMessage) + msg_size);
1123 pe->size = msg_size; 1123 pe->size = msg_size;
@@ -1135,7 +1135,7 @@ GNUNET_NAMESTORE_records_store (struct GNUNET_NAMESTORE_Handle *h,
1135 memcpy (name_tmp, label, name_len); 1135 memcpy (name_tmp, label, name_len);
1136 rd_ser = &name_tmp[name_len]; 1136 rd_ser = &name_tmp[name_len];
1137 GNUNET_break (rd_ser_len == 1137 GNUNET_break (rd_ser_len ==
1138 GNUNET_NAMESTORE_records_serialize (rd_count, rd, 1138 GNUNET_GNSRECORD_records_serialize (rd_count, rd,
1139 rd_ser_len, 1139 rd_ser_len,
1140 rd_ser)); 1140 rd_ser));
1141 LOG (GNUNET_ERROR_TYPE_DEBUG, 1141 LOG (GNUNET_ERROR_TYPE_DEBUG,
@@ -1162,7 +1162,7 @@ GNUNET_NAMESTORE_records_store (struct GNUNET_NAMESTORE_Handle *h,
1162struct GNUNET_NAMESTORE_QueueEntry * 1162struct GNUNET_NAMESTORE_QueueEntry *
1163GNUNET_NAMESTORE_lookup_block (struct GNUNET_NAMESTORE_Handle *h, 1163GNUNET_NAMESTORE_lookup_block (struct GNUNET_NAMESTORE_Handle *h,
1164 const struct GNUNET_HashCode *derived_hash, 1164 const struct GNUNET_HashCode *derived_hash,
1165 GNUNET_NAMESTORE_BlockProcessor proc, void *proc_cls) 1165 GNUNET_GNSRECORD_BlockProcessor proc, void *proc_cls)
1166{ 1166{
1167 struct GNUNET_NAMESTORE_QueueEntry *qe; 1167 struct GNUNET_NAMESTORE_QueueEntry *qe;
1168 struct PendingMessage *pe; 1168 struct PendingMessage *pe;
diff --git a/src/namestore/namestore_api_monitor.c b/src/namestore/namestore_api_monitor.c
index c9834e46c..076add1eb 100644
--- a/src/namestore/namestore_api_monitor.c
+++ b/src/namestore/namestore_api_monitor.c
@@ -186,9 +186,9 @@ handle_updates (void *cls,
186 } 186 }
187 rd_ser_tmp = (const char *) &name_tmp[name_len]; 187 rd_ser_tmp = (const char *) &name_tmp[name_len];
188 { 188 {
189 struct GNUNET_NAMESTORE_RecordData rd[rd_count]; 189 struct GNUNET_GNSRECORD_Data rd[rd_count];
190 190
191 if (GNUNET_OK != GNUNET_NAMESTORE_records_deserialize (rd_len, rd_ser_tmp, rd_count, rd)) 191 if (GNUNET_OK != GNUNET_GNSRECORD_records_deserialize (rd_len, rd_ser_tmp, rd_count, rd))
192 { 192 {
193 GNUNET_break (0); 193 GNUNET_break (0);
194 reconnect (zm); 194 reconnect (zm);
diff --git a/src/namestore/plugin_namestore_postgres.c b/src/namestore/plugin_namestore_postgres.c
index 0a8f0fbe8..e5cb75eb4 100644
--- a/src/namestore/plugin_namestore_postgres.c
+++ b/src/namestore/plugin_namestore_postgres.c
@@ -333,7 +333,7 @@ delete_old_block (struct Plugin *plugin,
333 */ 333 */
334static int 334static int
335namestore_postgres_cache_block (void *cls, 335namestore_postgres_cache_block (void *cls,
336 const struct GNUNET_NAMESTORE_Block *block) 336 const struct GNUNET_GNSRECORD_Block *block)
337{ 337{
338 struct Plugin *plugin = cls; 338 struct Plugin *plugin = cls;
339 struct GNUNET_HashCode query; 339 struct GNUNET_HashCode query;
@@ -392,7 +392,7 @@ namestore_postgres_cache_block (void *cls,
392static int 392static int
393namestore_postgres_lookup_block (void *cls, 393namestore_postgres_lookup_block (void *cls,
394 const struct GNUNET_HashCode *query, 394 const struct GNUNET_HashCode *query,
395 GNUNET_NAMESTORE_BlockCallback iter, void *iter_cls) 395 GNUNET_GNSRECORD_BlockCallback iter, void *iter_cls)
396{ 396{
397 struct Plugin *plugin = cls; 397 struct Plugin *plugin = cls;
398 const char *paramValues[] = { 398 const char *paramValues[] = {
@@ -405,7 +405,7 @@ namestore_postgres_lookup_block (void *cls,
405 PGresult *res; 405 PGresult *res;
406 unsigned int cnt; 406 unsigned int cnt;
407 size_t bsize; 407 size_t bsize;
408 const struct GNUNET_NAMESTORE_Block *block; 408 const struct GNUNET_GNSRECORD_Block *block;
409 409
410 res = PQexecPrepared (plugin->dbh, 410 res = PQexecPrepared (plugin->dbh,
411 "lookup_block", 1, 411 "lookup_block", 1,
@@ -431,7 +431,7 @@ namestore_postgres_lookup_block (void *cls,
431 GNUNET_assert (1 == cnt); 431 GNUNET_assert (1 == cnt);
432 GNUNET_assert (1 != PQnfields (res)); 432 GNUNET_assert (1 != PQnfields (res));
433 bsize = PQgetlength (res, 0, 0); 433 bsize = PQgetlength (res, 0, 0);
434 block = (const struct GNUNET_NAMESTORE_Block *) PQgetvalue (res, 0, 0); 434 block = (const struct GNUNET_GNSRECORD_Block *) PQgetvalue (res, 0, 0);
435 if ( (bsize < sizeof (*block)) || 435 if ( (bsize < sizeof (*block)) ||
436 (bsize != ntohl (block->purpose.size) + 436 (bsize != ntohl (block->purpose.size) +
437 sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey) + 437 sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey) +
@@ -465,7 +465,7 @@ namestore_postgres_store_records (void *cls,
465 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, 465 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key,
466 const char *label, 466 const char *label,
467 unsigned int rd_count, 467 unsigned int rd_count,
468 const struct GNUNET_NAMESTORE_RecordData *rd) 468 const struct GNUNET_GNSRECORD_Data *rd)
469{ 469{
470 struct Plugin *plugin = cls; 470 struct Plugin *plugin = cls;
471 struct GNUNET_CRYPTO_EcdsaPublicKey pkey; 471 struct GNUNET_CRYPTO_EcdsaPublicKey pkey;
@@ -485,7 +485,7 @@ namestore_postgres_store_records (void *cls,
485 break; 485 break;
486 } 486 }
487 rvalue = GNUNET_CRYPTO_random_u64 (GNUNET_CRYPTO_QUALITY_WEAK, UINT64_MAX); 487 rvalue = GNUNET_CRYPTO_random_u64 (GNUNET_CRYPTO_QUALITY_WEAK, UINT64_MAX);
488 data_size = GNUNET_NAMESTORE_records_get_size (rd_count, rd); 488 data_size = GNUNET_GNSRECORD_records_get_size (rd_count, rd);
489 if (data_size > 64 * 65536) 489 if (data_size > 64 * 65536)
490 { 490 {
491 GNUNET_break (0); 491 GNUNET_break (0);
@@ -512,7 +512,7 @@ namestore_postgres_store_records (void *cls,
512 const int paramFormats[] = { 1, 1, 1, 1, 1, 1 }; 512 const int paramFormats[] = { 1, 1, 1, 1, 1, 1 };
513 PGresult *res; 513 PGresult *res;
514 514
515 if (data_size != GNUNET_NAMESTORE_records_serialize (rd_count, rd, 515 if (data_size != GNUNET_GNSRECORD_records_serialize (rd_count, rd,
516 data_size, data)) 516 data_size, data))
517 { 517 {
518 GNUNET_break (0); 518 GNUNET_break (0);
@@ -610,13 +610,13 @@ get_record_and_call_iterator (struct Plugin *plugin,
610 return GNUNET_SYSERR; 610 return GNUNET_SYSERR;
611 } 611 }
612 { 612 {
613 struct GNUNET_NAMESTORE_RecordData rd[record_count]; 613 struct GNUNET_GNSRECORD_Data rd[record_count];
614 char buf[label_len + 1]; 614 char buf[label_len + 1];
615 615
616 memcpy (buf, label, label_len); 616 memcpy (buf, label, label_len);
617 buf[label_len] = '\0'; 617 buf[label_len] = '\0';
618 if (GNUNET_OK != 618 if (GNUNET_OK !=
619 GNUNET_NAMESTORE_records_deserialize (data_size, data, 619 GNUNET_GNSRECORD_records_deserialize (data_size, data,
620 record_count, rd)) 620 record_count, rd))
621 { 621 {
622 GNUNET_break (0); 622 GNUNET_break (0);
diff --git a/src/namestore/plugin_namestore_sqlite.c b/src/namestore/plugin_namestore_sqlite.c
index 06c2a7639..ce7be2a20 100644
--- a/src/namestore/plugin_namestore_sqlite.c
+++ b/src/namestore/plugin_namestore_sqlite.c
@@ -457,7 +457,7 @@ namestore_sqlite_expire_blocks (struct Plugin *plugin)
457 */ 457 */
458static int 458static int
459namestore_sqlite_cache_block (void *cls, 459namestore_sqlite_cache_block (void *cls,
460 const struct GNUNET_NAMESTORE_Block *block) 460 const struct GNUNET_GNSRECORD_Block *block)
461{ 461{
462 struct Plugin *plugin = cls; 462 struct Plugin *plugin = cls;
463 struct GNUNET_HashCode query; 463 struct GNUNET_HashCode query;
@@ -580,13 +580,13 @@ namestore_sqlite_cache_block (void *cls,
580static int 580static int
581namestore_sqlite_lookup_block (void *cls, 581namestore_sqlite_lookup_block (void *cls,
582 const struct GNUNET_HashCode *query, 582 const struct GNUNET_HashCode *query,
583 GNUNET_NAMESTORE_BlockCallback iter, void *iter_cls) 583 GNUNET_GNSRECORD_BlockCallback iter, void *iter_cls)
584{ 584{
585 struct Plugin *plugin = cls; 585 struct Plugin *plugin = cls;
586 int ret; 586 int ret;
587 int sret; 587 int sret;
588 size_t block_size; 588 size_t block_size;
589 const struct GNUNET_NAMESTORE_Block *block; 589 const struct GNUNET_GNSRECORD_Block *block;
590 590
591 if (SQLITE_OK != sqlite3_bind_blob (plugin->lookup_block, 1, 591 if (SQLITE_OK != sqlite3_bind_blob (plugin->lookup_block, 1,
592 query, sizeof (struct GNUNET_HashCode), 592 query, sizeof (struct GNUNET_HashCode),
@@ -605,7 +605,7 @@ namestore_sqlite_lookup_block (void *cls,
605 { 605 {
606 block = sqlite3_column_blob (plugin->lookup_block, 0); 606 block = sqlite3_column_blob (plugin->lookup_block, 0);
607 block_size = sqlite3_column_bytes (plugin->lookup_block, 0); 607 block_size = sqlite3_column_bytes (plugin->lookup_block, 0);
608 if ( (block_size < sizeof (struct GNUNET_NAMESTORE_Block)) || 608 if ( (block_size < sizeof (struct GNUNET_GNSRECORD_Block)) ||
609 (ntohl (block->purpose.size) + 609 (ntohl (block->purpose.size) +
610 sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey) + 610 sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey) +
611 sizeof (struct GNUNET_CRYPTO_EcdsaSignature) != block_size) ) 611 sizeof (struct GNUNET_CRYPTO_EcdsaSignature) != block_size) )
@@ -660,7 +660,7 @@ namestore_sqlite_store_records (void *cls,
660 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, 660 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key,
661 const char *label, 661 const char *label,
662 unsigned int rd_count, 662 unsigned int rd_count,
663 const struct GNUNET_NAMESTORE_RecordData *rd) 663 const struct GNUNET_GNSRECORD_Data *rd)
664{ 664{
665 struct Plugin *plugin = cls; 665 struct Plugin *plugin = cls;
666 int n; 666 int n;
@@ -680,7 +680,7 @@ namestore_sqlite_store_records (void *cls,
680 break; 680 break;
681 } 681 }
682 rvalue = GNUNET_CRYPTO_random_u64 (GNUNET_CRYPTO_QUALITY_WEAK, UINT64_MAX); 682 rvalue = GNUNET_CRYPTO_random_u64 (GNUNET_CRYPTO_QUALITY_WEAK, UINT64_MAX);
683 data_size = GNUNET_NAMESTORE_records_get_size (rd_count, rd); 683 data_size = GNUNET_GNSRECORD_records_get_size (rd_count, rd);
684 if (data_size > 64 * 65536) 684 if (data_size > 64 * 65536)
685 { 685 {
686 GNUNET_break (0); 686 GNUNET_break (0);
@@ -689,7 +689,7 @@ namestore_sqlite_store_records (void *cls,
689 { 689 {
690 char data[data_size]; 690 char data[data_size];
691 691
692 if (data_size != GNUNET_NAMESTORE_records_serialize (rd_count, rd, 692 if (data_size != GNUNET_GNSRECORD_records_serialize (rd_count, rd,
693 data_size, data)) 693 data_size, data))
694 { 694 {
695 GNUNET_break (0); 695 GNUNET_break (0);
@@ -817,10 +817,10 @@ get_record_and_call_iterator (struct Plugin *plugin,
817 } 817 }
818 else 818 else
819 { 819 {
820 struct GNUNET_NAMESTORE_RecordData rd[record_count]; 820 struct GNUNET_GNSRECORD_Data rd[record_count];
821 821
822 if (GNUNET_OK != 822 if (GNUNET_OK !=
823 GNUNET_NAMESTORE_records_deserialize (data_size, data, 823 GNUNET_GNSRECORD_records_deserialize (data_size, data,
824 record_count, rd)) 824 record_count, rd))
825 { 825 {
826 GNUNET_break (0); 826 GNUNET_break (0);
@@ -935,7 +935,7 @@ namestore_sqlite_zone_to_name (void *cls,
935 } 935 }
936 LOG (GNUNET_ERROR_TYPE_DEBUG, 936 LOG (GNUNET_ERROR_TYPE_DEBUG,
937 "Performing reverse lookup for `%s'\n", 937 "Performing reverse lookup for `%s'\n",
938 GNUNET_NAMESTORE_z2s (value_zone)); 938 GNUNET_GNSRECORD_z2s (value_zone));
939 939
940 return get_record_and_call_iterator (plugin, stmt, zone, iter, iter_cls); 940 return get_record_and_call_iterator (plugin, stmt, zone, iter, iter_cls);
941} 941}
diff --git a/src/namestore/test_namestore_api_cache_block.c b/src/namestore/test_namestore_api_cache_block.c
index e13077f81..de0ae75ee 100644
--- a/src/namestore/test_namestore_api_cache_block.c
+++ b/src/namestore/test_namestore_api_cache_block.c
@@ -94,7 +94,7 @@ end (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
94static void 94static void
95rd_decrypt_cb (void *cls, 95rd_decrypt_cb (void *cls,
96 unsigned int rd_count, 96 unsigned int rd_count,
97 const struct GNUNET_NAMESTORE_RecordData *rd) 97 const struct GNUNET_GNSRECORD_Data *rd)
98{ 98{
99 char rd_cmp_data[TEST_RECORD_DATALEN]; 99 char rd_cmp_data[TEST_RECORD_DATALEN];
100 100
@@ -115,7 +115,7 @@ rd_decrypt_cb (void *cls,
115 115
116static void 116static void
117name_lookup_proc (void *cls, 117name_lookup_proc (void *cls,
118 const struct GNUNET_NAMESTORE_Block *block) 118 const struct GNUNET_GNSRECORD_Block *block)
119{ 119{
120 const char *name = cls; 120 const char *name = cls;
121 nsqe = NULL; 121 nsqe = NULL;
@@ -140,7 +140,7 @@ name_lookup_proc (void *cls,
140 140
141 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 141 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
142 "Namestore returned block, decrypting \n"); 142 "Namestore returned block, decrypting \n");
143 GNUNET_assert (GNUNET_OK == GNUNET_NAMESTORE_block_decrypt(block, 143 GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_block_decrypt(block,
144 &pubkey, name, &rd_decrypt_cb, (void *) name)); 144 &pubkey, name, &rd_decrypt_cb, (void *) name));
145} 145}
146 146
@@ -158,7 +158,7 @@ cache_cont (void *cls, int32_t success, const char *emsg)
158 (success == GNUNET_OK) ? "SUCCESS" : "FAIL"); 158 (success == GNUNET_OK) ? "SUCCESS" : "FAIL");
159 159
160 /* Create derived hash */ 160 /* Create derived hash */
161 GNUNET_NAMESTORE_query_from_public_key (&pubkey, name, &derived_hash); 161 GNUNET_GNSRECORD_query_from_public_key (&pubkey, name, &derived_hash);
162 162
163 nsqe = GNUNET_NAMESTORE_lookup_block (nsh, &derived_hash, 163 nsqe = GNUNET_NAMESTORE_lookup_block (nsh, &derived_hash,
164 &name_lookup_proc, (void *) name); 164 &name_lookup_proc, (void *) name);
@@ -170,8 +170,8 @@ run (void *cls,
170 const struct GNUNET_CONFIGURATION_Handle *cfg, 170 const struct GNUNET_CONFIGURATION_Handle *cfg,
171 struct GNUNET_TESTING_Peer *peer) 171 struct GNUNET_TESTING_Peer *peer)
172{ 172{
173 struct GNUNET_NAMESTORE_RecordData rd; 173 struct GNUNET_GNSRECORD_Data rd;
174 struct GNUNET_NAMESTORE_Block *block; 174 struct GNUNET_GNSRECORD_Block *block;
175 char *hostkey_file; 175 char *hostkey_file;
176 const char * name = "dummy.dummy.gnunet"; 176 const char * name = "dummy.dummy.gnunet";
177 177
@@ -193,7 +193,7 @@ run (void *cls,
193 rd.data_size = TEST_RECORD_DATALEN; 193 rd.data_size = TEST_RECORD_DATALEN;
194 rd.data = GNUNET_malloc (TEST_RECORD_DATALEN); 194 rd.data = GNUNET_malloc (TEST_RECORD_DATALEN);
195 memset ((char *) rd.data, 'a', TEST_RECORD_DATALEN); 195 memset ((char *) rd.data, 'a', TEST_RECORD_DATALEN);
196 block = GNUNET_NAMESTORE_block_create (privkey, 196 block = GNUNET_GNSRECORD_block_create (privkey,
197 GNUNET_TIME_UNIT_FOREVER_ABS, name, &rd, 1 ); 197 GNUNET_TIME_UNIT_FOREVER_ABS, name, &rd, 1 );
198 if (NULL == block) 198 if (NULL == block)
199 { 199 {
diff --git a/src/namestore/test_namestore_api_lookup_public.c b/src/namestore/test_namestore_api_lookup_public.c
index 6c6ee55ec..97de58a6c 100644
--- a/src/namestore/test_namestore_api_lookup_public.c
+++ b/src/namestore/test_namestore_api_lookup_public.c
@@ -94,7 +94,7 @@ end (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
94static void 94static void
95rd_decrypt_cb (void *cls, 95rd_decrypt_cb (void *cls,
96 unsigned int rd_count, 96 unsigned int rd_count,
97 const struct GNUNET_NAMESTORE_RecordData *rd) 97 const struct GNUNET_GNSRECORD_Data *rd)
98{ 98{
99 char rd_cmp_data[TEST_RECORD_DATALEN]; 99 char rd_cmp_data[TEST_RECORD_DATALEN];
100 100
@@ -115,7 +115,7 @@ rd_decrypt_cb (void *cls,
115 115
116static void 116static void
117name_lookup_proc (void *cls, 117name_lookup_proc (void *cls,
118 const struct GNUNET_NAMESTORE_Block *block) 118 const struct GNUNET_GNSRECORD_Block *block)
119{ 119{
120 const char *name = cls; 120 const char *name = cls;
121 nsqe = NULL; 121 nsqe = NULL;
@@ -140,7 +140,7 @@ name_lookup_proc (void *cls,
140 140
141 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 141 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
142 "Namestore returned block, decrypting \n"); 142 "Namestore returned block, decrypting \n");
143 GNUNET_assert (GNUNET_OK == GNUNET_NAMESTORE_block_decrypt(block, 143 GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_block_decrypt(block,
144 &pubkey, name, &rd_decrypt_cb, (void *) name)); 144 &pubkey, name, &rd_decrypt_cb, (void *) name));
145} 145}
146 146
@@ -160,7 +160,7 @@ put_cont (void *cls, int32_t success, const char *emsg)
160 160
161 /* Create derived hash */ 161 /* Create derived hash */
162 GNUNET_CRYPTO_ecdsa_key_get_public (privkey, &pubkey); 162 GNUNET_CRYPTO_ecdsa_key_get_public (privkey, &pubkey);
163 GNUNET_NAMESTORE_query_from_public_key (&pubkey, name, &derived_hash); 163 GNUNET_GNSRECORD_query_from_public_key (&pubkey, name, &derived_hash);
164 164
165 nsqe = GNUNET_NAMESTORE_lookup_block (nsh, &derived_hash, 165 nsqe = GNUNET_NAMESTORE_lookup_block (nsh, &derived_hash,
166 &name_lookup_proc, (void *) name); 166 &name_lookup_proc, (void *) name);
@@ -172,7 +172,7 @@ run (void *cls,
172 const struct GNUNET_CONFIGURATION_Handle *cfg, 172 const struct GNUNET_CONFIGURATION_Handle *cfg,
173 struct GNUNET_TESTING_Peer *peer) 173 struct GNUNET_TESTING_Peer *peer)
174{ 174{
175 struct GNUNET_NAMESTORE_RecordData rd; 175 struct GNUNET_GNSRECORD_Data rd;
176 char *hostkey_file; 176 char *hostkey_file;
177 const char * name = "dummy.dummy.gnunet"; 177 const char * name = "dummy.dummy.gnunet";
178 178
diff --git a/src/namestore/test_namestore_api_monitoring.c b/src/namestore/test_namestore_api_monitoring.c
index 2d5888a5e..4ccb425a2 100644
--- a/src/namestore/test_namestore_api_monitoring.c
+++ b/src/namestore/test_namestore_api_monitoring.c
@@ -44,15 +44,15 @@ static int res;
44 44
45static char * s_name_1; 45static char * s_name_1;
46 46
47static struct GNUNET_NAMESTORE_RecordData *s_rd_1; 47static struct GNUNET_GNSRECORD_Data *s_rd_1;
48 48
49static char * s_name_2; 49static char * s_name_2;
50 50
51static struct GNUNET_NAMESTORE_RecordData *s_rd_2; 51static struct GNUNET_GNSRECORD_Data *s_rd_2;
52 52
53static char * s_name_3; 53static char * s_name_3;
54 54
55static struct GNUNET_NAMESTORE_RecordData *s_rd_3; 55static struct GNUNET_GNSRECORD_Data *s_rd_3;
56 56
57struct GNUNET_NAMESTORE_QueueEntry * ns_ops[3]; 57struct GNUNET_NAMESTORE_QueueEntry * ns_ops[3];
58 58
@@ -148,7 +148,7 @@ zone_proc (void *cls,
148 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, 148 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key,
149 const char *name, 149 const char *name,
150 unsigned int rd_count, 150 unsigned int rd_count,
151 const struct GNUNET_NAMESTORE_RecordData *rd) 151 const struct GNUNET_GNSRECORD_Data *rd)
152{ 152{
153 static int returned_records; 153 static int returned_records;
154 static int fail = GNUNET_NO; 154 static int fail = GNUNET_NO;
@@ -168,7 +168,7 @@ zone_proc (void *cls,
168 168
169 if (0 == strcmp (name, s_name_1)) 169 if (0 == strcmp (name, s_name_1))
170 { 170 {
171 if (GNUNET_YES != GNUNET_NAMESTORE_records_cmp(rd, s_rd_1)) 171 if (GNUNET_YES != GNUNET_GNSRECORD_records_cmp(rd, s_rd_1))
172 { 172 {
173 GNUNET_break (0); 173 GNUNET_break (0);
174 fail = GNUNET_YES; 174 fail = GNUNET_YES;
@@ -176,7 +176,7 @@ zone_proc (void *cls,
176 } 176 }
177 else if (0 == strcmp (name, s_name_2)) 177 else if (0 == strcmp (name, s_name_2))
178 { 178 {
179 if (GNUNET_YES != GNUNET_NAMESTORE_records_cmp(rd, s_rd_2)) 179 if (GNUNET_YES != GNUNET_GNSRECORD_records_cmp(rd, s_rd_2))
180 { 180 {
181 GNUNET_break (0); 181 GNUNET_break (0);
182 fail = GNUNET_YES; 182 fail = GNUNET_YES;
@@ -234,13 +234,13 @@ put_cont (void *cls, int32_t success, const char *emsg)
234} 234}
235 235
236 236
237static struct GNUNET_NAMESTORE_RecordData * 237static struct GNUNET_GNSRECORD_Data *
238create_record (unsigned int count) 238create_record (unsigned int count)
239{ 239{
240 unsigned int c; 240 unsigned int c;
241 struct GNUNET_NAMESTORE_RecordData * rd; 241 struct GNUNET_GNSRECORD_Data * rd;
242 242
243 rd = GNUNET_malloc (count * sizeof (struct GNUNET_NAMESTORE_RecordData)); 243 rd = GNUNET_malloc (count * sizeof (struct GNUNET_GNSRECORD_Data));
244 for (c = 0; c < count; c++) 244 for (c = 0; c < count; c++)
245 { 245 {
246 rd[c].expiration_time = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_UNIT_HOURS).abs_value_us; 246 rd[c].expiration_time = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_UNIT_HOURS).abs_value_us;
diff --git a/src/namestore/test_namestore_api_monitoring_existing.c b/src/namestore/test_namestore_api_monitoring_existing.c
index 3b2ca6092..b8ac7a729 100644
--- a/src/namestore/test_namestore_api_monitoring_existing.c
+++ b/src/namestore/test_namestore_api_monitoring_existing.c
@@ -45,15 +45,15 @@ static int res;
45 45
46static char * s_name_1; 46static char * s_name_1;
47 47
48static struct GNUNET_NAMESTORE_RecordData *s_rd_1; 48static struct GNUNET_GNSRECORD_Data *s_rd_1;
49 49
50static char * s_name_2; 50static char * s_name_2;
51 51
52static struct GNUNET_NAMESTORE_RecordData *s_rd_2; 52static struct GNUNET_GNSRECORD_Data *s_rd_2;
53 53
54static char * s_name_3; 54static char * s_name_3;
55 55
56static struct GNUNET_NAMESTORE_RecordData *s_rd_3; 56static struct GNUNET_GNSRECORD_Data *s_rd_3;
57 57
58struct GNUNET_NAMESTORE_QueueEntry * ns_ops[3]; 58struct GNUNET_NAMESTORE_QueueEntry * ns_ops[3];
59 59
@@ -149,7 +149,7 @@ zone_proc (void *cls,
149 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, 149 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key,
150 const char *name, 150 const char *name,
151 unsigned int rd_count, 151 unsigned int rd_count,
152 const struct GNUNET_NAMESTORE_RecordData *rd) 152 const struct GNUNET_GNSRECORD_Data *rd)
153{ 153{
154 static int returned_records; 154 static int returned_records;
155 static int fail = GNUNET_NO; 155 static int fail = GNUNET_NO;
@@ -169,7 +169,7 @@ zone_proc (void *cls,
169 169
170 if (0 == strcmp (name, s_name_1)) 170 if (0 == strcmp (name, s_name_1))
171 { 171 {
172 if (GNUNET_YES != GNUNET_NAMESTORE_records_cmp(rd, s_rd_1)) 172 if (GNUNET_YES != GNUNET_GNSRECORD_records_cmp(rd, s_rd_1))
173 { 173 {
174 GNUNET_break (0); 174 GNUNET_break (0);
175 fail = GNUNET_YES; 175 fail = GNUNET_YES;
@@ -177,7 +177,7 @@ zone_proc (void *cls,
177 } 177 }
178 else if (0 == strcmp (name, s_name_2)) 178 else if (0 == strcmp (name, s_name_2))
179 { 179 {
180 if (GNUNET_YES != GNUNET_NAMESTORE_records_cmp(rd, s_rd_2)) 180 if (GNUNET_YES != GNUNET_GNSRECORD_records_cmp(rd, s_rd_2))
181 { 181 {
182 GNUNET_break (0); 182 GNUNET_break (0);
183 fail = GNUNET_YES; 183 fail = GNUNET_YES;
@@ -252,13 +252,13 @@ put_cont (void *cls, int32_t success, const char *emsg)
252} 252}
253 253
254 254
255static struct GNUNET_NAMESTORE_RecordData * 255static struct GNUNET_GNSRECORD_Data *
256create_record (unsigned int count) 256create_record (unsigned int count)
257{ 257{
258 unsigned int c; 258 unsigned int c;
259 struct GNUNET_NAMESTORE_RecordData * rd; 259 struct GNUNET_GNSRECORD_Data * rd;
260 260
261 rd = GNUNET_malloc (count * sizeof (struct GNUNET_NAMESTORE_RecordData)); 261 rd = GNUNET_malloc (count * sizeof (struct GNUNET_GNSRECORD_Data));
262 for (c = 0; c < count; c++) 262 for (c = 0; c < count; c++)
263 { 263 {
264 rd[c].expiration_time = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_UNIT_HOURS).abs_value_us; 264 rd[c].expiration_time = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_UNIT_HOURS).abs_value_us;
diff --git a/src/namestore/test_namestore_api_put.c b/src/namestore/test_namestore_api_put.c
index 983ea6804..c0e04e98e 100644
--- a/src/namestore/test_namestore_api_put.c
+++ b/src/namestore/test_namestore_api_put.c
@@ -45,7 +45,7 @@ static struct GNUNET_CRYPTO_EcdsaPrivateKey * privkey;
45 45
46static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; 46static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey;
47 47
48static struct GNUNET_NAMESTORE_RecordData *s_rd; 48static struct GNUNET_GNSRECORD_Data *s_rd;
49 49
50static int res; 50static int res;
51 51
@@ -111,13 +111,13 @@ put_cont (void *cls, int32_t success, const char *emsg)
111} 111}
112 112
113 113
114static struct GNUNET_NAMESTORE_RecordData * 114static struct GNUNET_GNSRECORD_Data *
115create_record (unsigned int count) 115create_record (unsigned int count)
116{ 116{
117 unsigned int c; 117 unsigned int c;
118 struct GNUNET_NAMESTORE_RecordData * rd; 118 struct GNUNET_GNSRECORD_Data * rd;
119 119
120 rd = GNUNET_malloc (count * sizeof (struct GNUNET_NAMESTORE_RecordData)); 120 rd = GNUNET_malloc (count * sizeof (struct GNUNET_GNSRECORD_Data));
121 for (c = 0; c < count; c++) 121 for (c = 0; c < count; c++)
122 { 122 {
123 rd[c].expiration_time = GNUNET_TIME_absolute_get().abs_value_us; 123 rd[c].expiration_time = GNUNET_TIME_absolute_get().abs_value_us;
@@ -154,7 +154,7 @@ run (void *cls,
154 nsh = GNUNET_NAMESTORE_connect (cfg); 154 nsh = GNUNET_NAMESTORE_connect (cfg);
155 GNUNET_break (NULL != nsh); 155 GNUNET_break (NULL != nsh);
156 /* create record */ 156 /* create record */
157 s_name = GNUNET_NAMESTORE_normalize_string ("DUMMY.dummy.gnunet"); 157 s_name = GNUNET_GNSRECORD_string_to_lowercase ("DUMMY.dummy.gnunet");
158 s_rd = create_record (RECORDS); 158 s_rd = create_record (RECORDS);
159 et.abs_value_us = s_rd[0].expiration_time; 159 et.abs_value_us = s_rd[0].expiration_time;
160 signature = GNUNET_NAMESTORE_create_signature(privkey, et, s_name, s_rd, RECORDS); 160 signature = GNUNET_NAMESTORE_create_signature(privkey, et, s_name, s_rd, RECORDS);
diff --git a/src/namestore/test_namestore_api_remove.c b/src/namestore/test_namestore_api_remove.c
index f43bafecc..8605a3a00 100644
--- a/src/namestore/test_namestore_api_remove.c
+++ b/src/namestore/test_namestore_api_remove.c
@@ -121,7 +121,7 @@ remove_cont (void *cls,
121static void 121static void
122rd_decrypt_cb (void *cls, 122rd_decrypt_cb (void *cls,
123 unsigned int rd_count, 123 unsigned int rd_count,
124 const struct GNUNET_NAMESTORE_RecordData *rd) 124 const struct GNUNET_GNSRECORD_Data *rd)
125{ 125{
126 const char *name = cls; 126 const char *name = cls;
127 char rd_cmp_data[TEST_RECORD_DATALEN]; 127 char rd_cmp_data[TEST_RECORD_DATALEN];
@@ -145,7 +145,7 @@ rd_decrypt_cb (void *cls,
145 145
146static void 146static void
147name_lookup_proc (void *cls, 147name_lookup_proc (void *cls,
148 const struct GNUNET_NAMESTORE_Block *block) 148 const struct GNUNET_GNSRECORD_Block *block)
149{ 149{
150 const char *name = cls; 150 const char *name = cls;
151 nsqe = NULL; 151 nsqe = NULL;
@@ -179,7 +179,7 @@ name_lookup_proc (void *cls,
179 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 179 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
180 "Namestore returned block, decrypting \n"); 180 "Namestore returned block, decrypting \n");
181 GNUNET_assert (GNUNET_OK == 181 GNUNET_assert (GNUNET_OK ==
182 GNUNET_NAMESTORE_block_decrypt (block, 182 GNUNET_GNSRECORD_block_decrypt (block,
183 &pubkey, name, &rd_decrypt_cb, (void *) name)); 183 &pubkey, name, &rd_decrypt_cb, (void *) name));
184} 184}
185 185
@@ -209,7 +209,7 @@ put_cont (void *cls, int32_t success,
209 (success == GNUNET_OK) ? "SUCCESS" : "FAIL"); 209 (success == GNUNET_OK) ? "SUCCESS" : "FAIL");
210 210
211 /* Create derived hash */ 211 /* Create derived hash */
212 GNUNET_NAMESTORE_query_from_private_key (privkey, 212 GNUNET_GNSRECORD_query_from_private_key (privkey,
213 name, 213 name,
214 &derived_hash); 214 &derived_hash);
215 215
@@ -233,7 +233,7 @@ run (void *cls,
233 const struct GNUNET_CONFIGURATION_Handle *cfg, 233 const struct GNUNET_CONFIGURATION_Handle *cfg,
234 struct GNUNET_TESTING_Peer *peer) 234 struct GNUNET_TESTING_Peer *peer)
235{ 235{
236 struct GNUNET_NAMESTORE_RecordData rd; 236 struct GNUNET_GNSRECORD_Data rd;
237 char *hostkey_file; 237 char *hostkey_file;
238 const char * name = "dummy.dummy.gnunet"; 238 const char * name = "dummy.dummy.gnunet";
239 239
diff --git a/src/namestore/test_namestore_api_store.c b/src/namestore/test_namestore_api_store.c
index 133bf567f..99d245d00 100644
--- a/src/namestore/test_namestore_api_store.c
+++ b/src/namestore/test_namestore_api_store.c
@@ -94,7 +94,7 @@ end (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
94static void 94static void
95rd_decrypt_cb (void *cls, 95rd_decrypt_cb (void *cls,
96 unsigned int rd_count, 96 unsigned int rd_count,
97 const struct GNUNET_NAMESTORE_RecordData *rd) 97 const struct GNUNET_GNSRECORD_Data *rd)
98{ 98{
99 char rd_cmp_data[TEST_RECORD_DATALEN]; 99 char rd_cmp_data[TEST_RECORD_DATALEN];
100 100
@@ -115,7 +115,7 @@ rd_decrypt_cb (void *cls,
115 115
116static void 116static void
117name_lookup_proc (void *cls, 117name_lookup_proc (void *cls,
118 const struct GNUNET_NAMESTORE_Block *block) 118 const struct GNUNET_GNSRECORD_Block *block)
119{ 119{
120 const char *name = cls; 120 const char *name = cls;
121 nsqe = NULL; 121 nsqe = NULL;
@@ -140,7 +140,7 @@ name_lookup_proc (void *cls,
140 140
141 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 141 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
142 "Namestore returned block, decrypting \n"); 142 "Namestore returned block, decrypting \n");
143 GNUNET_assert (GNUNET_OK == GNUNET_NAMESTORE_block_decrypt(block, 143 GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_block_decrypt(block,
144 &pubkey, name, &rd_decrypt_cb, (void *) name)); 144 &pubkey, name, &rd_decrypt_cb, (void *) name));
145} 145}
146 146
@@ -158,7 +158,7 @@ put_cont (void *cls, int32_t success, const char *emsg)
158 (success == GNUNET_OK) ? "SUCCESS" : "FAIL"); 158 (success == GNUNET_OK) ? "SUCCESS" : "FAIL");
159 159
160 /* Create derived hash */ 160 /* Create derived hash */
161 GNUNET_NAMESTORE_query_from_private_key (privkey, name, &derived_hash); 161 GNUNET_GNSRECORD_query_from_private_key (privkey, name, &derived_hash);
162 162
163 nsqe = GNUNET_NAMESTORE_lookup_block (nsh, &derived_hash, 163 nsqe = GNUNET_NAMESTORE_lookup_block (nsh, &derived_hash,
164 &name_lookup_proc, (void *) name); 164 &name_lookup_proc, (void *) name);
@@ -170,7 +170,7 @@ run (void *cls,
170 const struct GNUNET_CONFIGURATION_Handle *cfg, 170 const struct GNUNET_CONFIGURATION_Handle *cfg,
171 struct GNUNET_TESTING_Peer *peer) 171 struct GNUNET_TESTING_Peer *peer)
172{ 172{
173 struct GNUNET_NAMESTORE_RecordData rd; 173 struct GNUNET_GNSRECORD_Data rd;
174 char *hostkey_file; 174 char *hostkey_file;
175 const char * name = "dummy.dummy.gnunet"; 175 const char * name = "dummy.dummy.gnunet";
176 176
diff --git a/src/namestore/test_namestore_api_store_update.c b/src/namestore/test_namestore_api_store_update.c
index 4aa058a91..4a0a36bb8 100644
--- a/src/namestore/test_namestore_api_store_update.c
+++ b/src/namestore/test_namestore_api_store_update.c
@@ -112,9 +112,9 @@ put_cont (void *cls, int32_t success, const char *emsg);
112static void 112static void
113rd_decrypt_cb (void *cls, 113rd_decrypt_cb (void *cls,
114 unsigned int rd_count, 114 unsigned int rd_count,
115 const struct GNUNET_NAMESTORE_RecordData *rd) 115 const struct GNUNET_GNSRECORD_Data *rd)
116{ 116{
117 struct GNUNET_NAMESTORE_RecordData rd_new; 117 struct GNUNET_GNSRECORD_Data rd_new;
118 118
119 GNUNET_assert (1 == rd_count); 119 GNUNET_assert (1 == rd_count);
120 GNUNET_assert (NULL != rd); 120 GNUNET_assert (NULL != rd);
@@ -131,7 +131,7 @@ rd_decrypt_cb (void *cls,
131 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 131 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
132 "Block was decrypted successfully, updating record \n"); 132 "Block was decrypted successfully, updating record \n");
133 133
134 rd_new.flags = GNUNET_NAMESTORE_RF_NONE; 134 rd_new.flags = GNUNET_GNSRECORD_RF_NONE;
135 rd_new.expiration_time = GNUNET_TIME_absolute_get().abs_value_us; 135 rd_new.expiration_time = GNUNET_TIME_absolute_get().abs_value_us;
136 rd_new.record_type = TEST_RECORD_TYPE2; 136 rd_new.record_type = TEST_RECORD_TYPE2;
137 rd_new.data_size = TEST_RECORD_DATALEN2; 137 rd_new.data_size = TEST_RECORD_DATALEN2;
@@ -158,7 +158,7 @@ rd_decrypt_cb (void *cls,
158 158
159static void 159static void
160name_lookup_proc (void *cls, 160name_lookup_proc (void *cls,
161 const struct GNUNET_NAMESTORE_Block *block) 161 const struct GNUNET_GNSRECORD_Block *block)
162{ 162{
163 const char *name = cls; 163 const char *name = cls;
164 nsqe = NULL; 164 nsqe = NULL;
@@ -183,7 +183,7 @@ name_lookup_proc (void *cls,
183 183
184 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 184 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
185 "Namestore returned block, decrypting \n"); 185 "Namestore returned block, decrypting \n");
186 GNUNET_assert (GNUNET_OK == GNUNET_NAMESTORE_block_decrypt(block, 186 GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_block_decrypt(block,
187 &pubkey, name, &rd_decrypt_cb, (void *) name)); 187 &pubkey, name, &rd_decrypt_cb, (void *) name));
188} 188}
189 189
@@ -202,7 +202,7 @@ put_cont (void *cls, int32_t success, const char *emsg)
202 (success == GNUNET_OK) ? "SUCCESS" : "FAIL"); 202 (success == GNUNET_OK) ? "SUCCESS" : "FAIL");
203 203
204 /* Create derived hash */ 204 /* Create derived hash */
205 GNUNET_NAMESTORE_query_from_private_key (privkey, name, &derived_hash); 205 GNUNET_GNSRECORD_query_from_private_key (privkey, name, &derived_hash);
206 206
207 nsqe = GNUNET_NAMESTORE_lookup_block (nsh, &derived_hash, 207 nsqe = GNUNET_NAMESTORE_lookup_block (nsh, &derived_hash,
208 &name_lookup_proc, (void *) name); 208 &name_lookup_proc, (void *) name);
@@ -214,7 +214,7 @@ run (void *cls,
214 const struct GNUNET_CONFIGURATION_Handle *cfg, 214 const struct GNUNET_CONFIGURATION_Handle *cfg,
215 struct GNUNET_TESTING_Peer *peer) 215 struct GNUNET_TESTING_Peer *peer)
216{ 216{
217 struct GNUNET_NAMESTORE_RecordData rd; 217 struct GNUNET_GNSRECORD_Data rd;
218 char *hostkey_file; 218 char *hostkey_file;
219 219
220 update_performed = GNUNET_NO; 220 update_performed = GNUNET_NO;
@@ -230,7 +230,7 @@ run (void *cls,
230 GNUNET_assert (privkey != NULL); 230 GNUNET_assert (privkey != NULL);
231 GNUNET_CRYPTO_ecdsa_key_get_public (privkey, &pubkey); 231 GNUNET_CRYPTO_ecdsa_key_get_public (privkey, &pubkey);
232 232
233 rd.flags = GNUNET_NAMESTORE_RF_NONE; 233 rd.flags = GNUNET_GNSRECORD_RF_NONE;
234 rd.expiration_time = GNUNET_TIME_absolute_get().abs_value_us; 234 rd.expiration_time = GNUNET_TIME_absolute_get().abs_value_us;
235 rd.record_type = TEST_RECORD_TYPE; 235 rd.record_type = TEST_RECORD_TYPE;
236 rd.data_size = TEST_RECORD_DATALEN; 236 rd.data_size = TEST_RECORD_DATALEN;
diff --git a/src/namestore/test_namestore_api_zone_iteration.c b/src/namestore/test_namestore_api_zone_iteration.c
index d1992309d..92fb43a28 100644
--- a/src/namestore/test_namestore_api_zone_iteration.c
+++ b/src/namestore/test_namestore_api_zone_iteration.c
@@ -46,15 +46,15 @@ static int returned_records;
46 46
47static char * s_name_1; 47static char * s_name_1;
48 48
49static struct GNUNET_NAMESTORE_RecordData *s_rd_1; 49static struct GNUNET_GNSRECORD_Data *s_rd_1;
50 50
51static char * s_name_2; 51static char * s_name_2;
52 52
53static struct GNUNET_NAMESTORE_RecordData *s_rd_2; 53static struct GNUNET_GNSRECORD_Data *s_rd_2;
54 54
55static char * s_name_3; 55static char * s_name_3;
56 56
57static struct GNUNET_NAMESTORE_RecordData *s_rd_3; 57static struct GNUNET_GNSRECORD_Data *s_rd_3;
58 58
59 59
60/** 60/**
@@ -159,7 +159,7 @@ zone_proc (void *cls,
159 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, 159 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone,
160 const char *label, 160 const char *label,
161 unsigned int rd_count, 161 unsigned int rd_count,
162 const struct GNUNET_NAMESTORE_RecordData *rd) 162 const struct GNUNET_GNSRECORD_Data *rd)
163{ 163{
164 int failed = GNUNET_NO; 164 int failed = GNUNET_NO;
165 if ((zone == NULL) && (label == NULL)) 165 if ((zone == NULL) && (label == NULL))
@@ -187,7 +187,7 @@ zone_proc (void *cls,
187 { 187 {
188 if (rd_count == 1) 188 if (rd_count == 1)
189 { 189 {
190 if (GNUNET_YES != GNUNET_NAMESTORE_records_cmp(rd, s_rd_1)) 190 if (GNUNET_YES != GNUNET_GNSRECORD_records_cmp(rd, s_rd_1))
191 { 191 {
192 failed = GNUNET_YES; 192 failed = GNUNET_YES;
193 GNUNET_break (0); 193 GNUNET_break (0);
@@ -203,7 +203,7 @@ zone_proc (void *cls,
203 { 203 {
204 if (rd_count == 1) 204 if (rd_count == 1)
205 { 205 {
206 if (GNUNET_YES != GNUNET_NAMESTORE_records_cmp(rd, s_rd_2)) 206 if (GNUNET_YES != GNUNET_GNSRECORD_records_cmp(rd, s_rd_2))
207 { 207 {
208 failed = GNUNET_YES; 208 failed = GNUNET_YES;
209 GNUNET_break (0); 209 GNUNET_break (0);
@@ -231,7 +231,7 @@ zone_proc (void *cls,
231 { 231 {
232 if (rd_count == 1) 232 if (rd_count == 1)
233 { 233 {
234 if (GNUNET_YES != GNUNET_NAMESTORE_records_cmp(rd, s_rd_3)) 234 if (GNUNET_YES != GNUNET_GNSRECORD_records_cmp(rd, s_rd_3))
235 { 235 {
236 failed = GNUNET_YES; 236 failed = GNUNET_YES;
237 GNUNET_break (0); 237 GNUNET_break (0);
@@ -319,13 +319,13 @@ put_cont (void *cls, int32_t success, const char *emsg)
319} 319}
320 320
321 321
322static struct GNUNET_NAMESTORE_RecordData * 322static struct GNUNET_GNSRECORD_Data *
323create_record (unsigned int count) 323create_record (unsigned int count)
324{ 324{
325 unsigned int c; 325 unsigned int c;
326 struct GNUNET_NAMESTORE_RecordData * rd; 326 struct GNUNET_GNSRECORD_Data * rd;
327 327
328 rd = GNUNET_malloc (count * sizeof (struct GNUNET_NAMESTORE_RecordData)); 328 rd = GNUNET_malloc (count * sizeof (struct GNUNET_GNSRECORD_Data));
329 for (c = 0; c < count; c++) 329 for (c = 0; c < count; c++)
330 { 330 {
331 rd[c].expiration_time = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_UNIT_HOURS).abs_value_us; 331 rd[c].expiration_time = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_UNIT_HOURS).abs_value_us;
@@ -348,7 +348,7 @@ empty_zone_proc (void *cls,
348 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, 348 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone,
349 const char *label, 349 const char *label,
350 unsigned int rd_count, 350 unsigned int rd_count,
351 const struct GNUNET_NAMESTORE_RecordData *rd) 351 const struct GNUNET_GNSRECORD_Data *rd)
352{ 352{
353 char *hostkey_file; 353 char *hostkey_file;
354 354
diff --git a/src/namestore/test_namestore_api_zone_iteration_specific_zone.c b/src/namestore/test_namestore_api_zone_iteration_specific_zone.c
index 858b724a5..1554d5673 100644
--- a/src/namestore/test_namestore_api_zone_iteration_specific_zone.c
+++ b/src/namestore/test_namestore_api_zone_iteration_specific_zone.c
@@ -46,15 +46,15 @@ static int returned_records;
46 46
47static char * s_name_1; 47static char * s_name_1;
48 48
49static struct GNUNET_NAMESTORE_RecordData *s_rd_1; 49static struct GNUNET_GNSRECORD_Data *s_rd_1;
50 50
51static char * s_name_2; 51static char * s_name_2;
52 52
53static struct GNUNET_NAMESTORE_RecordData *s_rd_2; 53static struct GNUNET_GNSRECORD_Data *s_rd_2;
54 54
55static char * s_name_3; 55static char * s_name_3;
56 56
57static struct GNUNET_NAMESTORE_RecordData *s_rd_3; 57static struct GNUNET_GNSRECORD_Data *s_rd_3;
58 58
59 59
60/** 60/**
@@ -159,7 +159,7 @@ zone_proc (void *cls,
159 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, 159 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone,
160 const char *label, 160 const char *label,
161 unsigned int rd_count, 161 unsigned int rd_count,
162 const struct GNUNET_NAMESTORE_RecordData *rd) 162 const struct GNUNET_GNSRECORD_Data *rd)
163{ 163{
164 int failed = GNUNET_NO; 164 int failed = GNUNET_NO;
165 if ((zone == NULL) && (label == NULL)) 165 if ((zone == NULL) && (label == NULL))
@@ -187,7 +187,7 @@ zone_proc (void *cls,
187 { 187 {
188 if (rd_count == 1) 188 if (rd_count == 1)
189 { 189 {
190 if (GNUNET_YES != GNUNET_NAMESTORE_records_cmp(rd, s_rd_1)) 190 if (GNUNET_YES != GNUNET_GNSRECORD_records_cmp(rd, s_rd_1))
191 { 191 {
192 failed = GNUNET_YES; 192 failed = GNUNET_YES;
193 GNUNET_break (0); 193 GNUNET_break (0);
@@ -203,7 +203,7 @@ zone_proc (void *cls,
203 { 203 {
204 if (rd_count == 1) 204 if (rd_count == 1)
205 { 205 {
206 if (GNUNET_YES != GNUNET_NAMESTORE_records_cmp(rd, s_rd_2)) 206 if (GNUNET_YES != GNUNET_GNSRECORD_records_cmp(rd, s_rd_2))
207 { 207 {
208 failed = GNUNET_YES; 208 failed = GNUNET_YES;
209 GNUNET_break (0); 209 GNUNET_break (0);
@@ -297,13 +297,13 @@ put_cont (void *cls, int32_t success, const char *emsg)
297} 297}
298 298
299 299
300static struct GNUNET_NAMESTORE_RecordData * 300static struct GNUNET_GNSRECORD_Data *
301create_record (unsigned int count) 301create_record (unsigned int count)
302{ 302{
303 unsigned int c; 303 unsigned int c;
304 struct GNUNET_NAMESTORE_RecordData * rd; 304 struct GNUNET_GNSRECORD_Data * rd;
305 305
306 rd = GNUNET_malloc (count * sizeof (struct GNUNET_NAMESTORE_RecordData)); 306 rd = GNUNET_malloc (count * sizeof (struct GNUNET_GNSRECORD_Data));
307 for (c = 0; c < count; c++) 307 for (c = 0; c < count; c++)
308 { 308 {
309 rd[c].expiration_time = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_UNIT_HOURS).abs_value_us; 309 rd[c].expiration_time = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_UNIT_HOURS).abs_value_us;
@@ -326,7 +326,7 @@ empty_zone_proc (void *cls,
326 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, 326 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone,
327 const char *label, 327 const char *label,
328 unsigned int rd_count, 328 unsigned int rd_count,
329 const struct GNUNET_NAMESTORE_RecordData *rd) 329 const struct GNUNET_GNSRECORD_Data *rd)
330{ 330{
331 char *hostkey_file; 331 char *hostkey_file;
332 332
diff --git a/src/namestore/test_namestore_api_zone_iteration_stop.c b/src/namestore/test_namestore_api_zone_iteration_stop.c
index 7b6824727..f7fd4203d 100644
--- a/src/namestore/test_namestore_api_zone_iteration_stop.c
+++ b/src/namestore/test_namestore_api_zone_iteration_stop.c
@@ -46,15 +46,15 @@ static int returned_records;
46 46
47static char * s_name_1; 47static char * s_name_1;
48 48
49static struct GNUNET_NAMESTORE_RecordData *s_rd_1; 49static struct GNUNET_GNSRECORD_Data *s_rd_1;
50 50
51static char * s_name_2; 51static char * s_name_2;
52 52
53static struct GNUNET_NAMESTORE_RecordData *s_rd_2; 53static struct GNUNET_GNSRECORD_Data *s_rd_2;
54 54
55static char * s_name_3; 55static char * s_name_3;
56 56
57static struct GNUNET_NAMESTORE_RecordData *s_rd_3; 57static struct GNUNET_GNSRECORD_Data *s_rd_3;
58 58
59 59
60/** 60/**
@@ -159,7 +159,7 @@ zone_proc (void *cls,
159 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, 159 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone,
160 const char *label, 160 const char *label,
161 unsigned int rd_count, 161 unsigned int rd_count,
162 const struct GNUNET_NAMESTORE_RecordData *rd) 162 const struct GNUNET_GNSRECORD_Data *rd)
163{ 163{
164 int failed = GNUNET_NO; 164 int failed = GNUNET_NO;
165 if ((zone == NULL) && (label == NULL)) 165 if ((zone == NULL) && (label == NULL))
@@ -184,7 +184,7 @@ zone_proc (void *cls,
184 { 184 {
185 if (rd_count == 1) 185 if (rd_count == 1)
186 { 186 {
187 if (GNUNET_YES != GNUNET_NAMESTORE_records_cmp(rd, s_rd_1)) 187 if (GNUNET_YES != GNUNET_GNSRECORD_records_cmp(rd, s_rd_1))
188 { 188 {
189 failed = GNUNET_YES; 189 failed = GNUNET_YES;
190 GNUNET_break (0); 190 GNUNET_break (0);
@@ -200,7 +200,7 @@ zone_proc (void *cls,
200 { 200 {
201 if (rd_count == 1) 201 if (rd_count == 1)
202 { 202 {
203 if (GNUNET_YES != GNUNET_NAMESTORE_records_cmp(rd, s_rd_2)) 203 if (GNUNET_YES != GNUNET_GNSRECORD_records_cmp(rd, s_rd_2))
204 { 204 {
205 failed = GNUNET_YES; 205 failed = GNUNET_YES;
206 GNUNET_break (0); 206 GNUNET_break (0);
@@ -228,7 +228,7 @@ zone_proc (void *cls,
228 { 228 {
229 if (rd_count == 1) 229 if (rd_count == 1)
230 { 230 {
231 if (GNUNET_YES != GNUNET_NAMESTORE_records_cmp(rd, s_rd_3)) 231 if (GNUNET_YES != GNUNET_GNSRECORD_records_cmp(rd, s_rd_3))
232 { 232 {
233 failed = GNUNET_YES; 233 failed = GNUNET_YES;
234 GNUNET_break (0); 234 GNUNET_break (0);
@@ -331,13 +331,13 @@ put_cont (void *cls, int32_t success, const char *emsg)
331} 331}
332 332
333 333
334static struct GNUNET_NAMESTORE_RecordData * 334static struct GNUNET_GNSRECORD_Data *
335create_record (unsigned int count) 335create_record (unsigned int count)
336{ 336{
337 unsigned int c; 337 unsigned int c;
338 struct GNUNET_NAMESTORE_RecordData * rd; 338 struct GNUNET_GNSRECORD_Data * rd;
339 339
340 rd = GNUNET_malloc (count * sizeof (struct GNUNET_NAMESTORE_RecordData)); 340 rd = GNUNET_malloc (count * sizeof (struct GNUNET_GNSRECORD_Data));
341 for (c = 0; c < count; c++) 341 for (c = 0; c < count; c++)
342 { 342 {
343 rd[c].expiration_time = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_UNIT_HOURS).abs_value_us; 343 rd[c].expiration_time = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_UNIT_HOURS).abs_value_us;
@@ -360,7 +360,7 @@ empty_zone_proc (void *cls,
360 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, 360 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone,
361 const char *label, 361 const char *label,
362 unsigned int rd_count, 362 unsigned int rd_count,
363 const struct GNUNET_NAMESTORE_RecordData *rd) 363 const struct GNUNET_GNSRECORD_Data *rd)
364{ 364{
365 char *hostkey_file; 365 char *hostkey_file;
366 366
diff --git a/src/namestore/test_namestore_api_zone_to_name.c b/src/namestore/test_namestore_api_zone_to_name.c
index 177c6479b..83e7de458 100644
--- a/src/namestore/test_namestore_api_zone_to_name.c
+++ b/src/namestore/test_namestore_api_zone_to_name.c
@@ -100,7 +100,7 @@ zone_to_name_proc (void *cls,
100 struct GNUNET_TIME_Absolute expire, 100 struct GNUNET_TIME_Absolute expire,
101 const char *n, 101 const char *n,
102 unsigned int rd_count, 102 unsigned int rd_count,
103 const struct GNUNET_NAMESTORE_RecordData *rd, 103 const struct GNUNET_GNSRECORD_Data *rd,
104 const struct GNUNET_CRYPTO_EcdsaSignature *signature) 104 const struct GNUNET_CRYPTO_EcdsaSignature *signature)
105{ 105{
106 int fail = GNUNET_NO; 106 int fail = GNUNET_NO;
@@ -184,7 +184,7 @@ run (void *cls,
184 GNUNET_CRYPTO_short_hash (s_name, strlen (s_name) + 1, &s_zone_value); 184 GNUNET_CRYPTO_short_hash (s_name, strlen (s_name) + 1, &s_zone_value);
185 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Using PKEY `%s' \n", GNUNET_NAMESTORE_short_h2s (&s_zone_value)); 185 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Using PKEY `%s' \n", GNUNET_NAMESTORE_short_h2s (&s_zone_value));
186 186
187 struct GNUNET_NAMESTORE_RecordData rd; 187 struct GNUNET_GNSRECORD_Data rd;
188 rd.expiration_time = GNUNET_TIME_absolute_get().abs_value_us; 188 rd.expiration_time = GNUNET_TIME_absolute_get().abs_value_us;
189 rd.record_type = GNUNET_GNSRECORD_TYPE_PKEY; 189 rd.record_type = GNUNET_GNSRECORD_TYPE_PKEY;
190 rd.data_size = sizeof (struct GNUNET_CRYPTO_ShortHashCode); 190 rd.data_size = sizeof (struct GNUNET_CRYPTO_ShortHashCode);
diff --git a/src/namestore/test_plugin_namestore.c b/src/namestore/test_plugin_namestore.c
index 7e77f4317..dc40120d4 100644
--- a/src/namestore/test_plugin_namestore.c
+++ b/src/namestore/test_plugin_namestore.c
@@ -84,7 +84,7 @@ test_record (void *cls,
84 const struct GNUNET_CRYPTO_EcdsaPrivateKey *private_key, 84 const struct GNUNET_CRYPTO_EcdsaPrivateKey *private_key,
85 const char *label, 85 const char *label,
86 unsigned int rd_count, 86 unsigned int rd_count,
87 const struct GNUNET_NAMESTORE_RecordData *rd) 87 const struct GNUNET_GNSRECORD_Data *rd)
88{ 88{
89 int *idp = cls; 89 int *idp = cls;
90 int id = *idp; 90 int id = *idp;
@@ -122,7 +122,7 @@ put_record (struct GNUNET_NAMESTORE_PluginFunctions *nsp, int id)
122 struct GNUNET_CRYPTO_EcdsaPrivateKey zone_private_key; 122 struct GNUNET_CRYPTO_EcdsaPrivateKey zone_private_key;
123 char label[64]; 123 char label[64];
124 unsigned int rd_count = 1 + (id % 1024); 124 unsigned int rd_count = 1 + (id % 1024);
125 struct GNUNET_NAMESTORE_RecordData rd[rd_count]; 125 struct GNUNET_GNSRECORD_Data rd[rd_count];
126 struct GNUNET_CRYPTO_EcdsaSignature signature; 126 struct GNUNET_CRYPTO_EcdsaSignature signature;
127 unsigned int i; 127 unsigned int i;
128 128