diff options
Diffstat (limited to 'src/include/gnunet_dht_service.h')
-rw-r--r-- | src/include/gnunet_dht_service.h | 47 |
1 files changed, 3 insertions, 44 deletions
diff --git a/src/include/gnunet_dht_service.h b/src/include/gnunet_dht_service.h index 4e14d981d..22b659d66 100644 --- a/src/include/gnunet_dht_service.h +++ b/src/include/gnunet_dht_service.h | |||
@@ -118,10 +118,10 @@ GNUNET_NETWORK_STRUCT_BEGIN | |||
118 | /** | 118 | /** |
119 | * Message signed by a peer when doing path tracking. | 119 | * Message signed by a peer when doing path tracking. |
120 | */ | 120 | */ |
121 | struct GNUNET_DHT_PutHopSignature | 121 | struct GNUNET_DHT_HopSignature |
122 | { | 122 | { |
123 | /** | 123 | /** |
124 | * Must be #GNUNET_SIGNATURE_PURPOSE_DHT_PUT_HOP. | 124 | * Must be #GNUNET_SIGNATURE_PURPOSE_DHT_HOP. |
125 | */ | 125 | */ |
126 | struct GNUNET_CRYPTO_EccSignaturePurpose purpose; | 126 | struct GNUNET_CRYPTO_EccSignaturePurpose purpose; |
127 | 127 | ||
@@ -149,45 +149,6 @@ struct GNUNET_DHT_PutHopSignature | |||
149 | 149 | ||
150 | 150 | ||
151 | /** | 151 | /** |
152 | * Message signed by a peer when doing path tracking | ||
153 | * for RESULT (GET) hops. | ||
154 | */ | ||
155 | struct GNUNET_DHT_ResultHopSignature | ||
156 | { | ||
157 | /** | ||
158 | * Must be #GNUNET_SIGNATURE_PURPOSE_DHT_RESULT_HOP. | ||
159 | */ | ||
160 | struct GNUNET_CRYPTO_EccSignaturePurpose purpose; | ||
161 | |||
162 | /** | ||
163 | * Expiration time of the block. | ||
164 | */ | ||
165 | struct GNUNET_TIME_AbsoluteNBO expiration_time; | ||
166 | |||
167 | /** | ||
168 | * Query hash of the GET that is being answered. | ||
169 | */ | ||
170 | struct GNUNET_HashCode query_hash; | ||
171 | |||
172 | /** | ||
173 | * Hash over the payload of the block. | ||
174 | */ | ||
175 | struct GNUNET_HashCode h_data; | ||
176 | |||
177 | /** | ||
178 | * Previous hop the message was received from. All zeros | ||
179 | * if this peer was the initiator. | ||
180 | */ | ||
181 | struct GNUNET_PeerIdentity pred; | ||
182 | |||
183 | /** | ||
184 | * Next hop the message was forwarded to. | ||
185 | */ | ||
186 | struct GNUNET_PeerIdentity succ; | ||
187 | }; | ||
188 | |||
189 | |||
190 | /** | ||
191 | * A (signed) path tracking a block's flow through the DHT is represented by | 152 | * A (signed) path tracking a block's flow through the DHT is represented by |
192 | * an array of path elements, each consisting of a peer on the path and a | 153 | * an array of path elements, each consisting of a peer on the path and a |
193 | * signature by which the peer affirms its routing decision. | 154 | * signature by which the peer affirms its routing decision. |
@@ -522,7 +483,6 @@ GNUNET_DHT_pp2s (const struct GNUNET_DHT_PathElement *path, | |||
522 | * the last signature on the path is never verified as that is the slot where | 483 | * the last signature on the path is never verified as that is the slot where |
523 | * our peer (@a me) would need to sign. | 484 | * our peer (@a me) would need to sign. |
524 | * | 485 | * |
525 | * @param query_hash the query hash, not necessarily the key of the block | ||
526 | * @param data payload (the block) | 486 | * @param data payload (the block) |
527 | * @param data_size number of bytes in @a data | 487 | * @param data_size number of bytes in @a data |
528 | * @param exp_time expiration time of @a data | 488 | * @param exp_time expiration time of @a data |
@@ -536,8 +496,7 @@ GNUNET_DHT_pp2s (const struct GNUNET_DHT_PathElement *path, | |||
536 | * @a get_path_len + @a put_path_len - 1 if no signature was valid | 496 | * @a get_path_len + @a put_path_len - 1 if no signature was valid |
537 | */ | 497 | */ |
538 | unsigned int | 498 | unsigned int |
539 | GNUNET_DHT_verify_path (const struct GNUNET_HashCode *query_hash, | 499 | GNUNET_DHT_verify_path (const void *data, |
540 | const void *data, | ||
541 | size_t data_size, | 500 | size_t data_size, |
542 | struct GNUNET_TIME_Absolute exp_time, | 501 | struct GNUNET_TIME_Absolute exp_time, |
543 | const struct GNUNET_DHT_PathElement *put_path, | 502 | const struct GNUNET_DHT_PathElement *put_path, |