aboutsummaryrefslogtreecommitdiff
path: root/src/namestore/test_namestore_api_lookup_public.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/namestore/test_namestore_api_lookup_public.c')
-rw-r--r--src/namestore/test_namestore_api_lookup_public.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/src/namestore/test_namestore_api_lookup_public.c b/src/namestore/test_namestore_api_lookup_public.c
index 039c7cbf6..5e3e7bbd8 100644
--- a/src/namestore/test_namestore_api_lookup_public.c
+++ b/src/namestore/test_namestore_api_lookup_public.c
@@ -42,9 +42,9 @@ static struct GNUNET_NAMECACHE_Handle *nch;
42 42
43static struct GNUNET_SCHEDULER_Task *endbadly_task; 43static struct GNUNET_SCHEDULER_Task *endbadly_task;
44 44
45static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey; 45static struct GNUNET_IDENTITY_PrivateKey privkey;
46 46
47static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; 47static struct GNUNET_IDENTITY_PublicKey pubkey;
48 48
49static int res; 49static int res;
50 50
@@ -163,7 +163,7 @@ put_cont (void *cls, int32_t success, const char *emsg)
163{ 163{
164 const char *name = cls; 164 const char *name = cls;
165 struct GNUNET_HashCode derived_hash; 165 struct GNUNET_HashCode derived_hash;
166 struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; 166 struct GNUNET_IDENTITY_PublicKey pubkey;
167 167
168 nsqe = NULL; 168 nsqe = NULL;
169 GNUNET_assert (NULL != cls); 169 GNUNET_assert (NULL != cls);
@@ -173,8 +173,8 @@ put_cont (void *cls, int32_t success, const char *emsg)
173 (success == GNUNET_OK) ? "SUCCESS" : "FAIL"); 173 (success == GNUNET_OK) ? "SUCCESS" : "FAIL");
174 174
175 /* Create derived hash */ 175 /* Create derived hash */
176 GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, 176 GNUNET_IDENTITY_key_get_public (&privkey,
177 &pubkey); 177 &pubkey);
178 GNUNET_GNSRECORD_query_from_public_key (&pubkey, name, &derived_hash); 178 GNUNET_GNSRECORD_query_from_public_key (&pubkey, name, &derived_hash);
179 179
180 ncqe = GNUNET_NAMECACHE_lookup_block (nch, &derived_hash, 180 ncqe = GNUNET_NAMECACHE_lookup_block (nch, &derived_hash,
@@ -193,9 +193,10 @@ run (void *cls,
193 endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, 193 endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT,
194 &endbadly, 194 &endbadly,
195 NULL); 195 NULL);
196 GNUNET_CRYPTO_ecdsa_key_create (&privkey); 196 privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY);
197 GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, 197 GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key);
198 &pubkey); 198 GNUNET_IDENTITY_key_get_public (&privkey,
199 &pubkey);
199 200
200 rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us + 1000000000; 201 rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us + 1000000000;
201 rd.record_type = TEST_RECORD_TYPE; 202 rd.record_type = TEST_RECORD_TYPE;