diff options
author | Martin Schanzenbach <schanzen@gnunet.org> | 2023-07-03 01:49:24 +0200 |
---|---|---|
committer | Martin Schanzenbach <schanzen@gnunet.org> | 2023-07-03 01:49:24 +0200 |
commit | e8125d57debdc6e12df8ec5a700e9a967fc4244c (patch) | |
tree | 79a694e174a95d244d956a93688e08cda53aaa1c /src | |
parent | 60efbba7bbe1c61f371603e56497297271173f3e (diff) | |
download | gnunet-e8125d57debdc6e12df8ec5a700e9a967fc4244c.tar.gz gnunet-e8125d57debdc6e12df8ec5a700e9a967fc4244c.zip |
GNS: Revert incorrect change hashing ztype
Diffstat (limited to 'src')
-rw-r--r-- | src/gnsrecord/gnsrecord_crypto.c | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/src/gnsrecord/gnsrecord_crypto.c b/src/gnsrecord/gnsrecord_crypto.c index 886a93ad8..384336c97 100644 --- a/src/gnsrecord/gnsrecord_crypto.c +++ b/src/gnsrecord/gnsrecord_crypto.c | |||
@@ -1056,7 +1056,6 @@ GNUNET_GNSRECORD_query_from_public_key (const struct | |||
1056 | { | 1056 | { |
1057 | char *norm_label; | 1057 | char *norm_label; |
1058 | struct GNUNET_IDENTITY_PublicKey pd; | 1058 | struct GNUNET_IDENTITY_PublicKey pd; |
1059 | ssize_t pd_len; | ||
1060 | 1059 | ||
1061 | norm_label = GNUNET_GNSRECORD_string_normalize (label); | 1060 | norm_label = GNUNET_GNSRECORD_string_normalize (label); |
1062 | 1061 | ||
@@ -1068,10 +1067,8 @@ GNUNET_GNSRECORD_query_from_public_key (const struct | |||
1068 | norm_label, | 1067 | norm_label, |
1069 | "gns", | 1068 | "gns", |
1070 | &pd.ecdsa_key); | 1069 | &pd.ecdsa_key); |
1071 | pd_len = GNUNET_IDENTITY_public_key_get_length (&pd); | 1070 | GNUNET_CRYPTO_hash (&pd.ecdsa_key, |
1072 | GNUNET_assert (0 < pd_len); | 1071 | sizeof (pd.ecdsa_key), |
1073 | GNUNET_CRYPTO_hash (&pd, | ||
1074 | pd_len, | ||
1075 | query); | 1072 | query); |
1076 | break; | 1073 | break; |
1077 | case GNUNET_GNSRECORD_TYPE_EDKEY: | 1074 | case GNUNET_GNSRECORD_TYPE_EDKEY: |
@@ -1080,10 +1077,8 @@ GNUNET_GNSRECORD_query_from_public_key (const struct | |||
1080 | norm_label, | 1077 | norm_label, |
1081 | "gns", | 1078 | "gns", |
1082 | &(pd.eddsa_key)); | 1079 | &(pd.eddsa_key)); |
1083 | pd_len = GNUNET_IDENTITY_public_key_get_length (&pd); | 1080 | GNUNET_CRYPTO_hash (&pd.eddsa_key, |
1084 | GNUNET_assert (0 < pd_len); | 1081 | sizeof (pd.eddsa_key), |
1085 | GNUNET_CRYPTO_hash (&pd, | ||
1086 | pd_len, | ||
1087 | query); | 1082 | query); |
1088 | break; | 1083 | break; |
1089 | default: | 1084 | default: |