aboutsummaryrefslogtreecommitdiff
path: root/src/include/gnunet_datacache_lib.h
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2022-01-09 12:22:04 +0100
committerChristian Grothoff <christian@grothoff.org>2022-01-09 12:22:04 +0100
commitec19c1e316efdd29a7af0524fc2ff33cc4b19d09 (patch)
tree184a59ff1c8408c462254e53f7e2004be829e237 /src/include/gnunet_datacache_lib.h
parentc3ecadd45b11f82e22ba81b42864c7826d0f97c6 (diff)
downloadgnunet-ec19c1e316efdd29a7af0524fc2ff33cc4b19d09.tar.gz
gnunet-ec19c1e316efdd29a7af0524fc2ff33cc4b19d09.zip
DHT: modify API and protocol messages to add path signatures, except for now the actual signatures are just placeholders (signing and signature verification are missing)
Diffstat (limited to 'src/include/gnunet_datacache_lib.h')
-rw-r--r--src/include/gnunet_datacache_lib.h23
1 files changed, 12 insertions, 11 deletions
diff --git a/src/include/gnunet_datacache_lib.h b/src/include/gnunet_datacache_lib.h
index 519c36bb4..11076e3e7 100644
--- a/src/include/gnunet_datacache_lib.h
+++ b/src/include/gnunet_datacache_lib.h
@@ -39,6 +39,7 @@
39 39
40#include "gnunet_util_lib.h" 40#include "gnunet_util_lib.h"
41#include "gnunet_block_lib.h" 41#include "gnunet_block_lib.h"
42#include "gnunet_dht_service.h"
42 43
43#ifdef __cplusplus 44#ifdef __cplusplus
44extern "C" 45extern "C"
@@ -89,15 +90,15 @@ GNUNET_DATACACHE_destroy (struct GNUNET_DATACACHE_Handle *h);
89 * @param path_info a path through the network 90 * @param path_info a path through the network
90 * @return #GNUNET_OK to continue iterating, #GNUNET_SYSERR to abort 91 * @return #GNUNET_OK to continue iterating, #GNUNET_SYSERR to abort
91 */ 92 */
92typedef int 93typedef enum GNUNET_GenericReturnValue
93(*GNUNET_DATACACHE_Iterator) (void *cls, 94(*GNUNET_DATACACHE_Iterator)(void *cls,
94 const struct GNUNET_HashCode *key, 95 const struct GNUNET_HashCode *key,
95 size_t data_size, 96 size_t data_size,
96 const char *data, 97 const char *data,
97 enum GNUNET_BLOCK_Type type, 98 enum GNUNET_BLOCK_Type type,
98 struct GNUNET_TIME_Absolute exp, 99 struct GNUNET_TIME_Absolute exp,
99 unsigned int path_info_len, 100 unsigned int path_info_len,
100 const struct GNUNET_PeerIdentity *path_info); 101 const struct GNUNET_DHT_PathElement *path_info);
101 102
102 103
103/** 104/**
@@ -114,7 +115,7 @@ typedef int
114 * @param path_info a path through the network 115 * @param path_info a path through the network
115 * @return #GNUNET_OK on success, #GNUNET_SYSERR on error, #GNUNET_NO if duplicate 116 * @return #GNUNET_OK on success, #GNUNET_SYSERR on error, #GNUNET_NO if duplicate
116 */ 117 */
117int 118enum GNUNET_GenericReturnValue
118GNUNET_DATACACHE_put (struct GNUNET_DATACACHE_Handle *h, 119GNUNET_DATACACHE_put (struct GNUNET_DATACACHE_Handle *h,
119 const struct GNUNET_HashCode *key, 120 const struct GNUNET_HashCode *key,
120 uint32_t xor_distance, 121 uint32_t xor_distance,
@@ -123,7 +124,7 @@ GNUNET_DATACACHE_put (struct GNUNET_DATACACHE_Handle *h,
123 enum GNUNET_BLOCK_Type type, 124 enum GNUNET_BLOCK_Type type,
124 struct GNUNET_TIME_Absolute discard_time, 125 struct GNUNET_TIME_Absolute discard_time,
125 unsigned int path_info_len, 126 unsigned int path_info_len,
126 const struct GNUNET_PeerIdentity *path_info); 127 const struct GNUNET_DHT_PathElement *path_info);
127 128
128 129
129/** 130/**