diff options
Diffstat (limited to 'src/fs/fs_publish_ublock.c')
-rw-r--r-- | src/fs/fs_publish_ublock.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/fs/fs_publish_ublock.c b/src/fs/fs_publish_ublock.c index 18f4804d1..791366073 100644 --- a/src/fs/fs_publish_ublock.c +++ b/src/fs/fs_publish_ublock.c | |||
@@ -46,7 +46,7 @@ static void | |||
46 | derive_ublock_encryption_key (struct GNUNET_CRYPTO_SymmetricSessionKey *skey, | 46 | derive_ublock_encryption_key (struct GNUNET_CRYPTO_SymmetricSessionKey *skey, |
47 | struct GNUNET_CRYPTO_SymmetricInitializationVector *iv, | 47 | struct GNUNET_CRYPTO_SymmetricInitializationVector *iv, |
48 | const char *label, | 48 | const char *label, |
49 | const struct GNUNET_CRYPTO_EccPublicSignKey *pub) | 49 | const struct GNUNET_CRYPTO_EcdsaPublicKey *pub) |
50 | { | 50 | { |
51 | struct GNUNET_HashCode key; | 51 | struct GNUNET_HashCode key; |
52 | 52 | ||
@@ -73,7 +73,7 @@ derive_ublock_encryption_key (struct GNUNET_CRYPTO_SymmetricSessionKey *skey, | |||
73 | void | 73 | void |
74 | GNUNET_FS_ublock_decrypt_ (const void *input, | 74 | GNUNET_FS_ublock_decrypt_ (const void *input, |
75 | size_t input_len, | 75 | size_t input_len, |
76 | const struct GNUNET_CRYPTO_EccPublicSignKey *ns, | 76 | const struct GNUNET_CRYPTO_EcdsaPublicKey *ns, |
77 | const char *label, | 77 | const char *label, |
78 | void *output) | 78 | void *output) |
79 | { | 79 | { |
@@ -158,7 +158,7 @@ GNUNET_FS_publish_ublock_ (struct GNUNET_FS_Handle *h, | |||
158 | struct GNUNET_DATASTORE_Handle *dsh, | 158 | struct GNUNET_DATASTORE_Handle *dsh, |
159 | const char *label, | 159 | const char *label, |
160 | const char *ulabel, | 160 | const char *ulabel, |
161 | const struct GNUNET_CRYPTO_EccPrivateKey *ns, | 161 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *ns, |
162 | const struct GNUNET_CONTAINER_MetaData *meta, | 162 | const struct GNUNET_CONTAINER_MetaData *meta, |
163 | const struct GNUNET_FS_Uri *uri, | 163 | const struct GNUNET_FS_Uri *uri, |
164 | const struct GNUNET_FS_BlockOptions *bo, | 164 | const struct GNUNET_FS_BlockOptions *bo, |
@@ -169,8 +169,8 @@ GNUNET_FS_publish_ublock_ (struct GNUNET_FS_Handle *h, | |||
169 | struct GNUNET_HashCode query; | 169 | struct GNUNET_HashCode query; |
170 | struct GNUNET_CRYPTO_SymmetricInitializationVector iv; | 170 | struct GNUNET_CRYPTO_SymmetricInitializationVector iv; |
171 | struct GNUNET_CRYPTO_SymmetricSessionKey skey; | 171 | struct GNUNET_CRYPTO_SymmetricSessionKey skey; |
172 | struct GNUNET_CRYPTO_EccPrivateKey *nsd; | 172 | struct GNUNET_CRYPTO_EcdsaPrivateKey *nsd; |
173 | struct GNUNET_CRYPTO_EccPublicSignKey pub; | 173 | struct GNUNET_CRYPTO_EcdsaPublicKey pub; |
174 | char *uris; | 174 | char *uris; |
175 | size_t size; | 175 | size_t size; |
176 | char *kbe; | 176 | char *kbe; |
@@ -225,7 +225,7 @@ GNUNET_FS_publish_ublock_ (struct GNUNET_FS_Handle *h, | |||
225 | "Publishing under identifier `%s'\n", | 225 | "Publishing under identifier `%s'\n", |
226 | label); | 226 | label); |
227 | /* get public key of the namespace */ | 227 | /* get public key of the namespace */ |
228 | GNUNET_CRYPTO_ecc_key_get_public_for_signature (ns, | 228 | GNUNET_CRYPTO_ecdsa_key_get_public (ns, |
229 | &pub); | 229 | &pub); |
230 | derive_ublock_encryption_key (&skey, &iv, | 230 | derive_ublock_encryption_key (&skey, &iv, |
231 | label, &pub); | 231 | label, &pub); |
@@ -238,15 +238,15 @@ GNUNET_FS_publish_ublock_ (struct GNUNET_FS_Handle *h, | |||
238 | &ub_enc[1]); | 238 | &ub_enc[1]); |
239 | ub_enc->purpose.size = htonl (ulen + slen + mdsize + | 239 | ub_enc->purpose.size = htonl (ulen + slen + mdsize + |
240 | sizeof (struct UBlock) | 240 | sizeof (struct UBlock) |
241 | - sizeof (struct GNUNET_CRYPTO_EccSignature)); | 241 | - sizeof (struct GNUNET_CRYPTO_EcdsaSignature)); |
242 | ub_enc->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_FS_UBLOCK); | 242 | ub_enc->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_FS_UBLOCK); |
243 | 243 | ||
244 | /* derive signing-key from 'label' and public key of the namespace */ | 244 | /* derive signing-key from 'label' and public key of the namespace */ |
245 | nsd = GNUNET_CRYPTO_ecc_key_derive (ns, label, "fs-ublock"); | 245 | nsd = GNUNET_CRYPTO_ecdsa_private_key_derive (ns, label, "fs-ublock"); |
246 | GNUNET_CRYPTO_ecc_key_get_public_for_signature (nsd, | 246 | GNUNET_CRYPTO_ecdsa_key_get_public (nsd, |
247 | &ub_enc->verification_key); | 247 | &ub_enc->verification_key); |
248 | GNUNET_assert (GNUNET_OK == | 248 | GNUNET_assert (GNUNET_OK == |
249 | GNUNET_CRYPTO_ecc_sign (nsd, | 249 | GNUNET_CRYPTO_ecdsa_sign (nsd, |
250 | &ub_enc->purpose, | 250 | &ub_enc->purpose, |
251 | &ub_enc->signature)); | 251 | &ub_enc->signature)); |
252 | GNUNET_CRYPTO_hash (&ub_enc->verification_key, | 252 | GNUNET_CRYPTO_hash (&ub_enc->verification_key, |