diff options
Diffstat (limited to 'src/gns/gnunet-service-gns_resolver.c')
-rw-r--r-- | src/gns/gnunet-service-gns_resolver.c | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/src/gns/gnunet-service-gns_resolver.c b/src/gns/gnunet-service-gns_resolver.c index 43d50aed5..4b26803ff 100644 --- a/src/gns/gnunet-service-gns_resolver.c +++ b/src/gns/gnunet-service-gns_resolver.c | |||
@@ -112,7 +112,7 @@ struct AuthorityChain | |||
112 | /** | 112 | /** |
113 | * The zone of the GNS authority | 113 | * The zone of the GNS authority |
114 | */ | 114 | */ |
115 | struct GNUNET_CRYPTO_EccPublicSignKey gns_authority; | 115 | struct GNUNET_CRYPTO_EcdsaPublicKey gns_authority; |
116 | 116 | ||
117 | struct | 117 | struct |
118 | { | 118 | { |
@@ -230,7 +230,7 @@ struct GNS_ResolverHandle | |||
230 | /** | 230 | /** |
231 | * The top-level GNS authoritative zone to query | 231 | * The top-level GNS authoritative zone to query |
232 | */ | 232 | */ |
233 | struct GNUNET_CRYPTO_EccPublicSignKey authority_zone; | 233 | struct GNUNET_CRYPTO_EcdsaPublicKey authority_zone; |
234 | 234 | ||
235 | /** | 235 | /** |
236 | * called when resolution phase finishes | 236 | * called when resolution phase finishes |
@@ -286,7 +286,7 @@ struct GNS_ResolverHandle | |||
286 | /** | 286 | /** |
287 | * Private key of the shorten zone, NULL to not shorten. | 287 | * Private key of the shorten zone, NULL to not shorten. |
288 | */ | 288 | */ |
289 | struct GNUNET_CRYPTO_EccPrivateKey *shorten_key; | 289 | struct GNUNET_CRYPTO_EcdsaPrivateKey *shorten_key; |
290 | 290 | ||
291 | /** | 291 | /** |
292 | * ID of a task associated with the resolution process. | 292 | * ID of a task associated with the resolution process. |
@@ -1421,9 +1421,9 @@ handle_gns_resolution_result (void *cls, | |||
1421 | /* tigger shortening */ | 1421 | /* tigger shortening */ |
1422 | if (NULL != rh->shorten_key) | 1422 | if (NULL != rh->shorten_key) |
1423 | { | 1423 | { |
1424 | struct GNUNET_CRYPTO_EccPublicSignKey pub; | 1424 | struct GNUNET_CRYPTO_EcdsaPublicKey pub; |
1425 | 1425 | ||
1426 | if (rd[i].data_size != sizeof (struct GNUNET_CRYPTO_EccPublicSignKey)) | 1426 | if (rd[i].data_size != sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey)) |
1427 | { | 1427 | { |
1428 | GNUNET_break_op (0); | 1428 | GNUNET_break_op (0); |
1429 | break; | 1429 | break; |
@@ -1454,7 +1454,7 @@ handle_gns_resolution_result (void *cls, | |||
1454 | { | 1454 | { |
1455 | case GNUNET_NAMESTORE_TYPE_PKEY: | 1455 | case GNUNET_NAMESTORE_TYPE_PKEY: |
1456 | /* delegation to another zone */ | 1456 | /* delegation to another zone */ |
1457 | if (sizeof (struct GNUNET_CRYPTO_EccPublicSignKey) != | 1457 | if (sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey) != |
1458 | rd[i].data_size) | 1458 | rd[i].data_size) |
1459 | { | 1459 | { |
1460 | GNUNET_break_op (0); | 1460 | GNUNET_break_op (0); |
@@ -1468,7 +1468,7 @@ handle_gns_resolution_result (void *cls, | |||
1468 | ac->gns_authority = GNUNET_YES; | 1468 | ac->gns_authority = GNUNET_YES; |
1469 | memcpy (&ac->authority_info.gns_authority, | 1469 | memcpy (&ac->authority_info.gns_authority, |
1470 | rd[i].data, | 1470 | rd[i].data, |
1471 | sizeof (struct GNUNET_CRYPTO_EccPublicSignKey)); | 1471 | sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey)); |
1472 | ac->label = resolver_lookup_get_next_label (rh); | 1472 | ac->label = resolver_lookup_get_next_label (rh); |
1473 | /* tigger shortening */ | 1473 | /* tigger shortening */ |
1474 | if (NULL != rh->shorten_key) | 1474 | if (NULL != rh->shorten_key) |
@@ -1719,8 +1719,8 @@ handle_dht_response (void *cls, | |||
1719 | block = data; | 1719 | block = data; |
1720 | if (size != | 1720 | if (size != |
1721 | ntohl (block->purpose.size) + | 1721 | ntohl (block->purpose.size) + |
1722 | sizeof (struct GNUNET_CRYPTO_EccPublicSignKey) + | 1722 | sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey) + |
1723 | sizeof (struct GNUNET_CRYPTO_EccSignature)) | 1723 | sizeof (struct GNUNET_CRYPTO_EcdsaSignature)) |
1724 | { | 1724 | { |
1725 | /* how did this pass DHT block validation!? */ | 1725 | /* how did this pass DHT block validation!? */ |
1726 | GNUNET_break (0); | 1726 | GNUNET_break (0); |
@@ -1768,7 +1768,7 @@ handle_namestore_block_response (void *cls, | |||
1768 | struct GNS_ResolverHandle *rx; | 1768 | struct GNS_ResolverHandle *rx; |
1769 | struct AuthorityChain *ac = rh->ac_tail; | 1769 | struct AuthorityChain *ac = rh->ac_tail; |
1770 | const char *label = ac->label; | 1770 | const char *label = ac->label; |
1771 | const struct GNUNET_CRYPTO_EccPublicSignKey *auth = &ac->authority_info.gns_authority; | 1771 | const struct GNUNET_CRYPTO_EcdsaPublicKey *auth = &ac->authority_info.gns_authority; |
1772 | struct GNUNET_HashCode query; | 1772 | struct GNUNET_HashCode query; |
1773 | 1773 | ||
1774 | GNUNET_NAMESTORE_query_from_public_key (auth, | 1774 | GNUNET_NAMESTORE_query_from_public_key (auth, |
@@ -1947,7 +1947,7 @@ start_resolver_lookup (struct GNS_ResolverHandle *rh) | |||
1947 | if ( (NULL == x) || | 1947 | if ( (NULL == x) || |
1948 | (NULL == y) || | 1948 | (NULL == y) || |
1949 | (GNUNET_OK != | 1949 | (GNUNET_OK != |
1950 | GNUNET_CRYPTO_ecc_public_sign_key_from_string (pkey, | 1950 | GNUNET_CRYPTO_ecdsa_public_key_from_string (pkey, |
1951 | strlen (pkey), | 1951 | strlen (pkey), |
1952 | &rh->authority_zone)) ) | 1952 | &rh->authority_zone)) ) |
1953 | { | 1953 | { |
@@ -1995,10 +1995,10 @@ start_resolver_lookup (struct GNS_ResolverHandle *rh) | |||
1995 | * @return handle to cancel operation | 1995 | * @return handle to cancel operation |
1996 | */ | 1996 | */ |
1997 | struct GNS_ResolverHandle * | 1997 | struct GNS_ResolverHandle * |
1998 | GNS_resolver_lookup (const struct GNUNET_CRYPTO_EccPublicSignKey *zone, | 1998 | GNS_resolver_lookup (const struct GNUNET_CRYPTO_EcdsaPublicKey *zone, |
1999 | uint32_t record_type, | 1999 | uint32_t record_type, |
2000 | const char *name, | 2000 | const char *name, |
2001 | const struct GNUNET_CRYPTO_EccPrivateKey *shorten_key, | 2001 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *shorten_key, |
2002 | int only_cached, | 2002 | int only_cached, |
2003 | GNS_ResultProcessor proc, void *proc_cls) | 2003 | GNS_ResultProcessor proc, void *proc_cls) |
2004 | { | 2004 | { |
@@ -2022,7 +2022,7 @@ GNS_resolver_lookup (const struct GNUNET_CRYPTO_EccPublicSignKey *zone, | |||
2022 | rh->name_resolution_pos = strlen (name); | 2022 | rh->name_resolution_pos = strlen (name); |
2023 | if (NULL != shorten_key) | 2023 | if (NULL != shorten_key) |
2024 | { | 2024 | { |
2025 | rh->shorten_key = GNUNET_new (struct GNUNET_CRYPTO_EccPrivateKey); | 2025 | rh->shorten_key = GNUNET_new (struct GNUNET_CRYPTO_EcdsaPrivateKey); |
2026 | *rh->shorten_key = *shorten_key; | 2026 | *rh->shorten_key = *shorten_key; |
2027 | } | 2027 | } |
2028 | start_resolver_lookup (rh); | 2028 | start_resolver_lookup (rh); |