diff options
Diffstat (limited to 'src/fs')
-rw-r--r-- | src/fs/fs_api.h | 2 | ||||
-rw-r--r-- | src/fs/fs_pseudonym.c | 130 | ||||
-rw-r--r-- | src/fs/fs_publish_ksk.c | 21 | ||||
-rw-r--r-- | src/fs/fs_uri.c | 14 | ||||
-rw-r--r-- | src/fs/test_fs_defaults.conf | 4 |
5 files changed, 121 insertions, 50 deletions
diff --git a/src/fs/fs_api.h b/src/fs/fs_api.h index f3daeb85a..2fe38f604 100644 --- a/src/fs/fs_api.h +++ b/src/fs/fs_api.h | |||
@@ -125,7 +125,7 @@ struct Location | |||
125 | /** | 125 | /** |
126 | * Identity of the peer sharing the file. | 126 | * Identity of the peer sharing the file. |
127 | */ | 127 | */ |
128 | struct GNUNET_CRYPTO_EccPublicKeyBinaryEncoded peer; | 128 | struct GNUNET_CRYPTO_EccPublicKey peer; |
129 | 129 | ||
130 | /** | 130 | /** |
131 | * Time when this location URI expires. | 131 | * Time when this location URI expires. |
diff --git a/src/fs/fs_pseudonym.c b/src/fs/fs_pseudonym.c index 49a084199..36eaab6fa 100644 --- a/src/fs/fs_pseudonym.c +++ b/src/fs/fs_pseudonym.c | |||
@@ -104,9 +104,8 @@ static struct GNUNET_FS_pseudonym_DiscoveryHandle *disco_head; | |||
104 | static struct GNUNET_FS_pseudonym_DiscoveryHandle *disco_tail; | 104 | static struct GNUNET_FS_pseudonym_DiscoveryHandle *disco_tail; |
105 | 105 | ||
106 | /** | 106 | /** |
107 | * Pointer to indiate 'anonymous' pseudonym (global static, all | 107 | * Pointer to indiate 'anonymous' pseudonym (global static, |
108 | * zeros). We actually use pointer comparisson to detect the | 108 | * d=1, public key = G (generator). |
109 | * "anonymous" pseudonym handle. | ||
110 | */ | 109 | */ |
111 | static struct GNUNET_FS_PseudonymHandle anonymous; | 110 | static struct GNUNET_FS_PseudonymHandle anonymous; |
112 | 111 | ||
@@ -1019,6 +1018,68 @@ GNUNET_FS_pseudonym_create_from_existing_file (const char *filename) | |||
1019 | struct GNUNET_FS_PseudonymHandle * | 1018 | struct GNUNET_FS_PseudonymHandle * |
1020 | GNUNET_FS_pseudonym_get_anonymous_pseudonym_handle () | 1019 | GNUNET_FS_pseudonym_get_anonymous_pseudonym_handle () |
1021 | { | 1020 | { |
1021 | static int once; | ||
1022 | gcry_mpi_t d; | ||
1023 | size_t size; | ||
1024 | gcry_ctx_t ctx; | ||
1025 | int rc; | ||
1026 | gcry_mpi_t g_x; | ||
1027 | gcry_mpi_t g_y; | ||
1028 | gcry_mpi_point_t g; | ||
1029 | |||
1030 | if (once) | ||
1031 | return &anonymous; | ||
1032 | d = gcry_mpi_new (1); | ||
1033 | gcry_mpi_set_ui (d, 1); | ||
1034 | size = sizeof (anonymous.d); | ||
1035 | GNUNET_assert (0 == | ||
1036 | gcry_mpi_print (GCRYMPI_FMT_USG, anonymous.d, size, &size, | ||
1037 | d)); | ||
1038 | gcry_mpi_release (d); | ||
1039 | adjust (anonymous.d, size, sizeof (anonymous.d)); | ||
1040 | |||
1041 | /* create basic ECC context */ | ||
1042 | if (0 != (rc = gcry_mpi_ec_new (&ctx, NULL, "NIST P-256"))) | ||
1043 | { | ||
1044 | LOG_GCRY (GNUNET_ERROR_TYPE_ERROR, | ||
1045 | "gcry_mpi_ec_new", rc); | ||
1046 | return NULL; | ||
1047 | } | ||
1048 | |||
1049 | g = gcry_mpi_ec_get_point ("g", ctx, 0); | ||
1050 | g_x = gcry_mpi_new (256); | ||
1051 | g_y = gcry_mpi_new (256); | ||
1052 | gcry_mpi_ec_get_affine (g_x, g_y, g, ctx); | ||
1053 | gcry_mpi_point_release (g); | ||
1054 | gcry_ctx_release (ctx); | ||
1055 | |||
1056 | /* store g_x/g_y in public key */ | ||
1057 | size = sizeof (anonymous.public_key.q_x); | ||
1058 | if (0 != | ||
1059 | gcry_mpi_print (GCRYMPI_FMT_USG, anonymous.public_key.q_x, size, &size, | ||
1060 | g_x)) | ||
1061 | { | ||
1062 | LOG_GCRY (GNUNET_ERROR_TYPE_ERROR, "gcry_mpi_print", rc); | ||
1063 | gcry_mpi_release (g_x); | ||
1064 | gcry_mpi_release (g_y); | ||
1065 | return NULL; | ||
1066 | } | ||
1067 | adjust (anonymous.public_key.q_x, size, sizeof (anonymous.public_key.q_x)); | ||
1068 | gcry_mpi_release (g_x); | ||
1069 | |||
1070 | size = sizeof (anonymous.public_key.q_y); | ||
1071 | if (0 != | ||
1072 | gcry_mpi_print (GCRYMPI_FMT_USG, anonymous.public_key.q_y, size, &size, | ||
1073 | g_y)) | ||
1074 | { | ||
1075 | LOG_GCRY (GNUNET_ERROR_TYPE_ERROR, "gcry_mpi_print", rc); | ||
1076 | gcry_mpi_release (g_y); | ||
1077 | return NULL; | ||
1078 | } | ||
1079 | adjust (anonymous.public_key.q_y, size, sizeof (anonymous.public_key.q_y)); | ||
1080 | gcry_mpi_release (g_y); | ||
1081 | |||
1082 | once = 1; | ||
1022 | return &anonymous; | 1083 | return &anonymous; |
1023 | } | 1084 | } |
1024 | 1085 | ||
@@ -1122,21 +1183,13 @@ GNUNET_FS_pseudonym_sign (struct GNUNET_FS_PseudonymHandle *ph, | |||
1122 | int rc; | 1183 | int rc; |
1123 | 1184 | ||
1124 | /* get private key 'd' from pseudonym */ | 1185 | /* get private key 'd' from pseudonym */ |
1125 | if (&anonymous == ph) | 1186 | size = sizeof (ph->d); |
1126 | { | 1187 | if (0 != (rc = gcry_mpi_scan (&d, GCRYMPI_FMT_USG, |
1127 | d = gcry_mpi_new (0); | 1188 | &ph->d, |
1128 | gcry_mpi_set_ui (d, 0); | 1189 | size, &size))) |
1129 | } | ||
1130 | else | ||
1131 | { | 1190 | { |
1132 | size = sizeof (ph->d); | 1191 | LOG_GCRY (GNUNET_ERROR_TYPE_ERROR, "gcry_mpi_scan", rc); |
1133 | if (0 != (rc = gcry_mpi_scan (&d, GCRYMPI_FMT_USG, | 1192 | return GNUNET_SYSERR; |
1134 | &ph->d, | ||
1135 | size, &size))) | ||
1136 | { | ||
1137 | LOG_GCRY (GNUNET_ERROR_TYPE_ERROR, "gcry_mpi_scan", rc); | ||
1138 | return GNUNET_SYSERR; | ||
1139 | } | ||
1140 | } | 1193 | } |
1141 | /* get 'x' value from signing key */ | 1194 | /* get 'x' value from signing key */ |
1142 | size = sizeof (struct GNUNET_HashCode); | 1195 | size = sizeof (struct GNUNET_HashCode); |
@@ -1159,9 +1212,9 @@ GNUNET_FS_pseudonym_sign (struct GNUNET_FS_PseudonymHandle *ph, | |||
1159 | return GNUNET_SYSERR; | 1212 | return GNUNET_SYSERR; |
1160 | } | 1213 | } |
1161 | 1214 | ||
1162 | /* calculate dx = d + h mod n */ | 1215 | /* calculate dh = d * h mod n */ |
1163 | dh = gcry_mpi_new (256); | 1216 | dh = gcry_mpi_new (256); |
1164 | gcry_mpi_addm (dh, d, h, n); | 1217 | gcry_mpi_mulm (dh, d, h, n); |
1165 | gcry_mpi_release (d); | 1218 | gcry_mpi_release (d); |
1166 | gcry_mpi_release (h); | 1219 | gcry_mpi_release (h); |
1167 | gcry_mpi_release (n); | 1220 | gcry_mpi_release (n); |
@@ -1297,7 +1350,7 @@ get_context_from_pseudonym (struct GNUNET_FS_PseudonymIdentifier *pseudonym) | |||
1297 | LOG_GCRY (GNUNET_ERROR_TYPE_ERROR, "gcry_mpi_ec_new", rc); /* erroff gives more info */ | 1350 | LOG_GCRY (GNUNET_ERROR_TYPE_ERROR, "gcry_mpi_ec_new", rc); /* erroff gives more info */ |
1298 | return NULL; | 1351 | return NULL; |
1299 | } | 1352 | } |
1300 | /* initialize 'ctx' with 'q' = 0 */ | 1353 | /* FIXME: initialize 'ctx' with 'q' = G */ |
1301 | zero = gcry_mpi_new (0); | 1354 | zero = gcry_mpi_new (0); |
1302 | gcry_mpi_set_ui (zero, 0); | 1355 | gcry_mpi_set_ui (zero, 0); |
1303 | q = gcry_mpi_point_new (0); | 1356 | q = gcry_mpi_point_new (0); |
@@ -1346,7 +1399,7 @@ get_context_from_pseudonym (struct GNUNET_FS_PseudonymIdentifier *pseudonym) | |||
1346 | * @param pseudonym the public key (dQ in ECDSA) | 1399 | * @param pseudonym the public key (dQ in ECDSA) |
1347 | * @param signing_key input to derive 'h' (see section 2.4 of #2564) | 1400 | * @param signing_key input to derive 'h' (see section 2.4 of #2564) |
1348 | * @param verification_key resulting public key to verify the signature | 1401 | * @param verification_key resulting public key to verify the signature |
1349 | * created from the '(d+h)' of 'pseudonym' and the 'signing_key'; | 1402 | * created from the '(d*h)' of 'pseudonym' and the 'signing_key'; |
1350 | * the value stored here can then be given to GNUNET_FS_pseudonym_verify. | 1403 | * the value stored here can then be given to GNUNET_FS_pseudonym_verify. |
1351 | * @return GNUNET_OK on success, GNUNET_SYSERR on error | 1404 | * @return GNUNET_OK on success, GNUNET_SYSERR on error |
1352 | */ | 1405 | */ |
@@ -1359,12 +1412,12 @@ GNUNET_FS_pseudonym_derive_verification_key (struct GNUNET_FS_PseudonymIdentifie | |||
1359 | size_t size; | 1412 | size_t size; |
1360 | int rc; | 1413 | int rc; |
1361 | gcry_ctx_t ctx; | 1414 | gcry_ctx_t ctx; |
1362 | gcry_mpi_point_t g; | ||
1363 | gcry_mpi_point_t q; | 1415 | gcry_mpi_point_t q; |
1364 | gcry_mpi_point_t hg; | ||
1365 | gcry_mpi_point_t v; | 1416 | gcry_mpi_point_t v; |
1366 | gcry_mpi_t v_x; | 1417 | gcry_mpi_t v_x; |
1367 | gcry_mpi_t v_y; | 1418 | gcry_mpi_t v_y; |
1419 | gcry_mpi_t h_mod_n; | ||
1420 | gcry_mpi_t n; /* n from P-256 */ | ||
1368 | 1421 | ||
1369 | /* get 'h' value from signing key */ | 1422 | /* get 'h' value from signing key */ |
1370 | size = sizeof (struct GNUNET_HashCode); | 1423 | size = sizeof (struct GNUNET_HashCode); |
@@ -1381,22 +1434,26 @@ GNUNET_FS_pseudonym_derive_verification_key (struct GNUNET_FS_PseudonymIdentifie | |||
1381 | gcry_mpi_release (h); | 1434 | gcry_mpi_release (h); |
1382 | return GNUNET_SYSERR; | 1435 | return GNUNET_SYSERR; |
1383 | } | 1436 | } |
1384 | /* get G */ | 1437 | /* initialize 'n' from P-256; hex copied from libgcrypt code */ |
1385 | g = gcry_mpi_ec_get_point ("g", ctx, 0); | 1438 | if (0 != (rc = gcry_mpi_scan (&n, GCRYMPI_FMT_HEX, |
1386 | 1439 | "0xffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551", 0, NULL))) | |
1387 | /* then call the 'multiply' function, to compute the product hG */ | 1440 | { |
1388 | hg = gcry_mpi_point_new (0); | 1441 | LOG_GCRY (GNUNET_ERROR_TYPE_ERROR, "gcry_mpi_scan", rc); |
1389 | gcry_mpi_ec_mul (hg, h, g, ctx); | 1442 | gcry_mpi_release (h); |
1390 | gcry_mpi_point_release (g); | 1443 | return GNUNET_SYSERR; |
1444 | } | ||
1445 | h_mod_n = gcry_mpi_new (0); | ||
1446 | gcry_mpi_mod (h_mod_n, h, n); | ||
1391 | gcry_mpi_release (h); | 1447 | gcry_mpi_release (h); |
1392 | 1448 | ||
1393 | /* get Q = dG from 'pseudonym' */ | 1449 | /* get Q = dG from 'pseudonym' */ |
1394 | q = gcry_mpi_ec_get_point ("q", ctx, 0); | 1450 | q = gcry_mpi_ec_get_point ("q", ctx, 0); |
1395 | /* calculate V = Q + hG = dG + hG = (d + h)G*/ | 1451 | /* calculate V = hQ = hdG */ |
1396 | v = gcry_mpi_point_new (0); | 1452 | v = gcry_mpi_point_new (0); |
1397 | gcry_mpi_ec_add (v, q, hg, ctx); | ||
1398 | gcry_mpi_point_release (hg); | ||
1399 | 1453 | ||
1454 | gcry_mpi_ec_mul (v, h_mod_n, q, ctx); | ||
1455 | gcry_mpi_release (h_mod_n); | ||
1456 | |||
1400 | /* store 'v' point in "verification_key" */ | 1457 | /* store 'v' point in "verification_key" */ |
1401 | v_x = gcry_mpi_new (256); | 1458 | v_x = gcry_mpi_new (256); |
1402 | v_y = gcry_mpi_new (256); | 1459 | v_y = gcry_mpi_new (256); |
@@ -1566,11 +1623,8 @@ void | |||
1566 | GNUNET_FS_pseudonym_get_identifier (struct GNUNET_FS_PseudonymHandle *ph, | 1623 | GNUNET_FS_pseudonym_get_identifier (struct GNUNET_FS_PseudonymHandle *ph, |
1567 | struct GNUNET_FS_PseudonymIdentifier *pseudonym) | 1624 | struct GNUNET_FS_PseudonymIdentifier *pseudonym) |
1568 | { | 1625 | { |
1569 | if (&anonymous == ph) | 1626 | memcpy (pseudonym, &ph->public_key, |
1570 | memset (pseudonym, 0, sizeof (struct GNUNET_FS_PseudonymIdentifier)); | 1627 | sizeof (struct GNUNET_FS_PseudonymIdentifier)); |
1571 | else | ||
1572 | memcpy (pseudonym, &ph->public_key, | ||
1573 | sizeof (struct GNUNET_FS_PseudonymIdentifier)); | ||
1574 | } | 1628 | } |
1575 | 1629 | ||
1576 | 1630 | ||
diff --git a/src/fs/fs_publish_ksk.c b/src/fs/fs_publish_ksk.c index 3b0f1d4fb..10512af5f 100644 --- a/src/fs/fs_publish_ksk.c +++ b/src/fs/fs_publish_ksk.c | |||
@@ -177,23 +177,35 @@ publish_ksk_cont (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
177 | struct UBlock *ub_dst; | 177 | struct UBlock *ub_dst; |
178 | 178 | ||
179 | pkc->ksk_task = GNUNET_SCHEDULER_NO_TASK; | 179 | pkc->ksk_task = GNUNET_SCHEDULER_NO_TASK; |
180 | if ((pkc->i == pkc->ksk_uri->data.ksk.keywordCount) || (NULL == pkc->dsh)) | 180 | if ( (pkc->i == pkc->ksk_uri->data.ksk.keywordCount) || |
181 | (NULL == pkc->dsh) ) | ||
181 | { | 182 | { |
182 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "KSK PUT operation complete\n"); | 183 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "KSK PUT operation complete\n"); |
183 | pkc->cont (pkc->cont_cls, pkc->ksk_uri, NULL); | 184 | pkc->cont (pkc->cont_cls, pkc->ksk_uri, NULL); |
184 | GNUNET_FS_publish_ksk_cancel (pkc); | 185 | GNUNET_FS_publish_ksk_cancel (pkc); |
185 | return; | 186 | return; |
186 | } | 187 | } |
188 | keyword = pkc->ksk_uri->data.ksk.keywords[pkc->i++]; | ||
189 | pkc->sks_task = GNUNET_FS_publish_sks (pkc->h, | ||
190 | anonymous, | ||
191 | keyword, NULL, | ||
192 | pkc->meta, | ||
193 | pkc->uri, | ||
194 | &pkc->bo, | ||
195 | pkc->options, | ||
196 | &publish_ksk_cont, pkc); | ||
197 | |||
198 | |||
187 | /* derive signing seed from plaintext */ | 199 | /* derive signing seed from plaintext */ |
188 | GNUNET_CRYPTO_hash (&pkc->ub[1], | 200 | GNUNET_CRYPTO_hash (&pkc->ub[1], |
189 | 1 + pkc->slen + pkc->mdsize, | 201 | 1 + pkc->slen + pkc->mdsize, |
190 | &seed); | 202 | &seed); |
191 | keyword = pkc->ksk_uri->data.ksk.keywords[pkc->i++]; | ||
192 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Publishing under keyword `%s'\n", | 203 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Publishing under keyword `%s'\n", |
193 | &keyword[1]); | 204 | &keyword[1]); |
194 | /* first character of keyword indicates if it is | 205 | /* first character of keyword indicates if it is |
195 | * mandatory or not -- ignore for hashing */ | 206 | * mandatory or not -- ignore for hashing */ |
196 | GNUNET_CRYPTO_hash (&keyword[1], strlen (&keyword[1]), &key); | 207 | GNUNET_CRYPTO_hash (&keyword[1], strlen (&keyword[1]), &key); |
208 | |||
197 | GNUNET_CRYPTO_hash_to_aes_key (&key, &skey, &iv); | 209 | GNUNET_CRYPTO_hash_to_aes_key (&key, &skey, &iv); |
198 | ub_dst = pkc->cpy; | 210 | ub_dst = pkc->cpy; |
199 | GNUNET_CRYPTO_aes_encrypt (&pkc->ub[1], | 211 | GNUNET_CRYPTO_aes_encrypt (&pkc->ub[1], |
@@ -202,8 +214,9 @@ publish_ksk_cont (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
202 | &ub_dst[1]); | 214 | &ub_dst[1]); |
203 | ph = GNUNET_FS_pseudonym_get_anonymous_pseudonym_handle (); | 215 | ph = GNUNET_FS_pseudonym_get_anonymous_pseudonym_handle (); |
204 | GNUNET_CRYPTO_hash (&key, sizeof (key), &signing_key); | 216 | GNUNET_CRYPTO_hash (&key, sizeof (key), &signing_key); |
205 | ub_dst->purpose.size = htonl (1 + pkc->slen + pkc->mdsize + sizeof (struct UBlock) | 217 | ub_dst->purpose.size = htonl (1 + pkc->slen + pkc->mdsize + |
206 | - sizeof (struct GNUNET_FS_PseudonymSignature)); | 218 | sizeof (struct UBlock) |
219 | - sizeof (struct GNUNET_FS_PseudonymSignature)); | ||
207 | ub_dst->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_FS_UBLOCK); | 220 | ub_dst->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_FS_UBLOCK); |
208 | 221 | ||
209 | GNUNET_FS_pseudonym_get_identifier (ph, &pseudonym); | 222 | GNUNET_FS_pseudonym_get_identifier (ph, &pseudonym); |
diff --git a/src/fs/fs_uri.c b/src/fs/fs_uri.c index 48c347a52..78b5459fd 100644 --- a/src/fs/fs_uri.c +++ b/src/fs/fs_uri.c | |||
@@ -117,7 +117,7 @@ GNUNET_FS_uri_to_key (const struct GNUNET_FS_Uri *uri, struct GNUNET_HashCode * | |||
117 | case GNUNET_FS_URI_LOC: | 117 | case GNUNET_FS_URI_LOC: |
118 | GNUNET_CRYPTO_hash (&uri->data.loc.fi, | 118 | GNUNET_CRYPTO_hash (&uri->data.loc.fi, |
119 | sizeof (struct FileIdentifier) + | 119 | sizeof (struct FileIdentifier) + |
120 | sizeof (struct GNUNET_CRYPTO_EccPublicKeyBinaryEncoded), | 120 | sizeof (struct GNUNET_CRYPTO_EccPublicKey), |
121 | key); | 121 | key); |
122 | break; | 122 | break; |
123 | default: | 123 | default: |
@@ -520,7 +520,7 @@ struct LocUriAssembly | |||
520 | 520 | ||
521 | struct FileIdentifier fi; | 521 | struct FileIdentifier fi; |
522 | 522 | ||
523 | struct GNUNET_CRYPTO_EccPublicKeyBinaryEncoded peer; | 523 | struct GNUNET_CRYPTO_EccPublicKey peer; |
524 | 524 | ||
525 | }; | 525 | }; |
526 | 526 | ||
@@ -591,7 +591,7 @@ uri_loc_parse (const char *s, char **emsg) | |||
591 | npos++; | 591 | npos++; |
592 | ret = | 592 | ret = |
593 | enc2bin (&s[npos], &ass.peer, | 593 | enc2bin (&s[npos], &ass.peer, |
594 | sizeof (struct GNUNET_CRYPTO_EccPublicKeyBinaryEncoded)); | 594 | sizeof (struct GNUNET_CRYPTO_EccPublicKey)); |
595 | if (ret == -1) | 595 | if (ret == -1) |
596 | { | 596 | { |
597 | *emsg = | 597 | *emsg = |
@@ -828,7 +828,7 @@ GNUNET_FS_uri_loc_get_peer_identity (const struct GNUNET_FS_Uri *uri, | |||
828 | if (uri->type != GNUNET_FS_URI_LOC) | 828 | if (uri->type != GNUNET_FS_URI_LOC) |
829 | return GNUNET_SYSERR; | 829 | return GNUNET_SYSERR; |
830 | GNUNET_CRYPTO_hash (&uri->data.loc.peer, | 830 | GNUNET_CRYPTO_hash (&uri->data.loc.peer, |
831 | sizeof (struct GNUNET_CRYPTO_EccPublicKeyBinaryEncoded), | 831 | sizeof (struct GNUNET_CRYPTO_EccPublicKey), |
832 | &peer->hashPubKey); | 832 | &peer->hashPubKey); |
833 | return GNUNET_OK; | 833 | return GNUNET_OK; |
834 | } | 834 | } |
@@ -884,7 +884,7 @@ GNUNET_FS_uri_loc_create (const struct GNUNET_FS_Uri *baseUri, | |||
884 | { | 884 | { |
885 | struct GNUNET_FS_Uri *uri; | 885 | struct GNUNET_FS_Uri *uri; |
886 | struct GNUNET_CRYPTO_EccPrivateKey *my_private_key; | 886 | struct GNUNET_CRYPTO_EccPrivateKey *my_private_key; |
887 | struct GNUNET_CRYPTO_EccPublicKeyBinaryEncoded my_public_key; | 887 | struct GNUNET_CRYPTO_EccPublicKey my_public_key; |
888 | char *keyfile; | 888 | char *keyfile; |
889 | struct LocUriAssembly ass; | 889 | struct LocUriAssembly ass; |
890 | 890 | ||
@@ -1307,7 +1307,7 @@ GNUNET_FS_uri_test_equal (const struct GNUNET_FS_Uri *u1, | |||
1307 | if (memcmp | 1307 | if (memcmp |
1308 | (&u1->data.loc, &u2->data.loc, | 1308 | (&u1->data.loc, &u2->data.loc, |
1309 | sizeof (struct FileIdentifier) + | 1309 | sizeof (struct FileIdentifier) + |
1310 | sizeof (struct GNUNET_CRYPTO_EccPublicKeyBinaryEncoded) + | 1310 | sizeof (struct GNUNET_CRYPTO_EccPublicKey) + |
1311 | sizeof (struct GNUNET_TIME_Absolute) + sizeof (unsigned short) + | 1311 | sizeof (struct GNUNET_TIME_Absolute) + sizeof (unsigned short) + |
1312 | sizeof (unsigned short)) != 0) | 1312 | sizeof (unsigned short)) != 0) |
1313 | return GNUNET_NO; | 1313 | return GNUNET_NO; |
@@ -2049,7 +2049,7 @@ uri_loc_to_string (const struct GNUNET_FS_Uri *uri) | |||
2049 | GNUNET_CRYPTO_hash_to_enc (&uri->data.loc.fi.chk.query, &queryhash); | 2049 | GNUNET_CRYPTO_hash_to_enc (&uri->data.loc.fi.chk.query, &queryhash); |
2050 | peerId = | 2050 | peerId = |
2051 | bin2enc (&uri->data.loc.peer, | 2051 | bin2enc (&uri->data.loc.peer, |
2052 | sizeof (struct GNUNET_CRYPTO_EccPublicKeyBinaryEncoded)); | 2052 | sizeof (struct GNUNET_CRYPTO_EccPublicKey)); |
2053 | peerSig = | 2053 | peerSig = |
2054 | bin2enc (&uri->data.loc.contentSignature, | 2054 | bin2enc (&uri->data.loc.contentSignature, |
2055 | sizeof (struct GNUNET_CRYPTO_EccSignature)); | 2055 | sizeof (struct GNUNET_CRYPTO_EccSignature)); |
diff --git a/src/fs/test_fs_defaults.conf b/src/fs/test_fs_defaults.conf index 7d87c0e2f..dd0d729e2 100644 --- a/src/fs/test_fs_defaults.conf +++ b/src/fs/test_fs_defaults.conf | |||
@@ -92,3 +92,7 @@ AUTOSTART = NO | |||
92 | 92 | ||
93 | [consensus] | 93 | [consensus] |
94 | AUTOSTART = NO | 94 | AUTOSTART = NO |
95 | |||
96 | [mesh] | ||
97 | REFRESH_PATH_TIME = 30 min | ||
98 | |||