aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMartin Schanzenbach <mschanzenbach@posteo.de>2012-03-22 11:22:37 +0000
committerMartin Schanzenbach <mschanzenbach@posteo.de>2012-03-22 11:22:37 +0000
commite4ec722c9fa516adaf7e655c21fa1f338b240131 (patch)
treec91da7b95a7da509fb77f414528f3579d614d468 /src
parenta2f68ea8b627e2d009ac5624837b958694f335ff (diff)
downloadgnunet-e4ec722c9fa516adaf7e655c21fa1f338b240131.tar.gz
gnunet-e4ec722c9fa516adaf7e655c21fa1f338b240131.zip
-doc, new config options
Diffstat (limited to 'src')
-rw-r--r--src/gns/gns.conf.in2
-rw-r--r--src/gns/gnunet-service-gns_resolver.h22
2 files changed, 23 insertions, 1 deletions
diff --git a/src/gns/gns.conf.in b/src/gns/gns.conf.in
index b625a1441..9d522b8fe 100644
--- a/src/gns/gns.conf.in
+++ b/src/gns/gns.conf.in
@@ -8,6 +8,8 @@ UNIXPATH = /tmp/gnunet-service-gns.sock
8ZONEKEY = $SERVICEHOME/gns/zonekey.zkey 8ZONEKEY = $SERVICEHOME/gns/zonekey.zkey
9HIJACK_DNS = NO 9HIJACK_DNS = NO
10AUTO_IMPORT_PKEY = YES 10AUTO_IMPORT_PKEY = YES
11MAX_PARALLEL_BACKGROUND_QUERIES = 25
12DEFAULT_LOOKUP_TIMEOUT = 10
11 13
12[fcfsd] 14[fcfsd]
13HTTPPORT = 18080 15HTTPPORT = 18080
diff --git a/src/gns/gnunet-service-gns_resolver.h b/src/gns/gnunet-service-gns_resolver.h
index 18d32698a..e973b0c52 100644
--- a/src/gns/gnunet-service-gns_resolver.h
+++ b/src/gns/gnunet-service-gns_resolver.h
@@ -144,9 +144,16 @@ struct ResolverHandle
144 /* status of the resolution result */ 144 /* status of the resolution result */
145 enum ResolutionStatus status; 145 enum ResolutionStatus status;
146 146
147 /**
148 * private key of an/our authoritative zone
149 * can be NULL but automatical PKEY import will not work
150 */
147 struct GNUNET_CRYPTO_RsaPrivateKey *priv_key; 151 struct GNUNET_CRYPTO_RsaPrivateKey *priv_key;
148 152
149 /* the heap node associated with this lookup, null if timeout is set */ 153 /**
154 * the heap node associated with this lookup, null if timeout is set
155 * used for DHT background lookups.
156 */
150 struct GNUNET_CONTAINER_HeapNode *dht_heap_node; 157 struct GNUNET_CONTAINER_HeapNode *dht_heap_node;
151 158
152}; 159};
@@ -233,6 +240,7 @@ struct GetPseuAuthorityHandle
233 240
234/** 241/**
235 * Initialize the resolver 242 * Initialize the resolver
243 * MUST be called before other gns_resolver_* methods
236 * 244 *
237 * @param nh handle to the namestore 245 * @param nh handle to the namestore
238 * @param dh handle to the dht 246 * @param dh handle to the dht
@@ -262,6 +270,18 @@ gns_resolver_lookup_record(struct GNUNET_CRYPTO_ShortHashCode zone,
262 RecordLookupProcessor proc, 270 RecordLookupProcessor proc,
263 void* cls); 271 void* cls);
264 272
273/**
274 * Shortens a name if possible. If the shortening fails
275 * name will be returned as shortened string. Else
276 * a shorter version of the name will be returned.
277 * There is no guarantee that the shortened name will
278 * actually be canonical/short etc.
279 *
280 * @param zone the zone to perform the operation in
281 * @param name name to shorten
282 * @param proc the processor to call on shorten result
283 * @param proc_cls teh closure to pass to proc
284 */
265void 285void
266gns_resolver_shorten_name(struct GNUNET_CRYPTO_ShortHashCode zone, 286gns_resolver_shorten_name(struct GNUNET_CRYPTO_ShortHashCode zone,
267 const char* name, 287 const char* name,