diff options
author | Martin Schanzenbach <mschanzenbach@posteo.de> | 2020-10-14 19:47:32 +0200 |
---|---|---|
committer | Martin Schanzenbach <mschanzenbach@posteo.de> | 2020-10-15 12:11:18 +0200 |
commit | 96c802b46be51e5c45f34e2de823f787d26c2929 (patch) | |
tree | 457ccfd8f9a61563af86318739c4a8f964a57025 /src/namestore/test_namestore_api_zone_to_name.c | |
parent | c14e3a2769ff0f15fdbb32797e37e43ce2344fa3 (diff) | |
download | gnunet-96c802b46be51e5c45f34e2de823f787d26c2929.tar.gz gnunet-96c802b46be51e5c45f34e2de823f787d26c2929.zip |
- towards crypto agility; wip
Diffstat (limited to 'src/namestore/test_namestore_api_zone_to_name.c')
-rw-r--r-- | src/namestore/test_namestore_api_zone_to_name.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/src/namestore/test_namestore_api_zone_to_name.c b/src/namestore/test_namestore_api_zone_to_name.c index 94cc5c285..e5ede6bcd 100644 --- a/src/namestore/test_namestore_api_zone_to_name.c +++ b/src/namestore/test_namestore_api_zone_to_name.c | |||
@@ -42,11 +42,11 @@ static struct GNUNET_NAMESTORE_Handle *nsh; | |||
42 | 42 | ||
43 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 43 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
44 | 44 | ||
45 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey; | 45 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
46 | 46 | ||
47 | static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 47 | static struct GNUNET_IDENTITY_PublicKey pubkey; |
48 | 48 | ||
49 | static struct GNUNET_CRYPTO_EcdsaPublicKey s_zone_value; | 49 | static struct GNUNET_IDENTITY_PublicKey s_zone_value; |
50 | 50 | ||
51 | static char *s_name; | 51 | static char *s_name; |
52 | 52 | ||
@@ -92,7 +92,7 @@ end (void *cls) | |||
92 | 92 | ||
93 | static void | 93 | static void |
94 | zone_to_name_proc (void *cls, | 94 | zone_to_name_proc (void *cls, |
95 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 95 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, |
96 | const char *n, | 96 | const char *n, |
97 | unsigned int rd_count, | 97 | unsigned int rd_count, |
98 | const struct GNUNET_GNSRECORD_Data *rd) | 98 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -203,10 +203,11 @@ run (void *cls, | |||
203 | GNUNET_SCHEDULER_add_shutdown (&end, | 203 | GNUNET_SCHEDULER_add_shutdown (&end, |
204 | NULL); | 204 | NULL); |
205 | GNUNET_asprintf (&s_name, "dummy"); | 205 | GNUNET_asprintf (&s_name, "dummy"); |
206 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 206 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
207 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | ||
207 | /* get public key */ | 208 | /* get public key */ |
208 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, | 209 | GNUNET_IDENTITY_key_get_public (&privkey, |
209 | &pubkey); | 210 | &pubkey); |
210 | 211 | ||
211 | GNUNET_CRYPTO_random_block (GNUNET_CRYPTO_QUALITY_WEAK, | 212 | GNUNET_CRYPTO_random_block (GNUNET_CRYPTO_QUALITY_WEAK, |
212 | &s_zone_value, | 213 | &s_zone_value, |