(no commit message)
authorNathan S. Evans <evans@in.tum.de>
Thu, 12 Aug 2010 16:21:51 +0000 (16:21 +0000)
committerNathan S. Evans <evans@in.tum.de>
Thu, 12 Aug 2010 16:21:51 +0000 (16:21 +0000)
src/include/gnunet_dht_service.h

index 5398b0ba1467da3888c0c40cad9371689e5b9d22..16dea8d1fdaa172d27aa5431c30c1fda6a8e7dde 100644 (file)
@@ -304,6 +304,43 @@ GNUNET_DHT_route_stop (struct GNUNET_DHT_RouteHandle *route_handle,
                       GNUNET_SCHEDULER_Task cont, 
                       void *cont_cls);
 
+/**
+ * Send a message to the DHT telling it to start issuing random GET
+ * requests every 'frequency' milliseconds.
+ *
+ * @param handle handle to the DHT service
+ * @param frequency delay (in milliseconds) between sending malicious messages
+ * @param cont continuation to call once the message is sent
+ * @param cont_cls closure for continuation
+ *
+ * @return GNUNET_YES if the control message was sent, GNUNET_NO if not
+ */
+int GNUNET_DHT_set_malicious_getter (struct GNUNET_DHT_Handle *handle, int frequency, GNUNET_SCHEDULER_Task cont, void *cont_cls);
+
+/**
+ * Send a message to the DHT telling it to start dropping
+ * all requests received.
+ *
+ * @param handle handle to the DHT service
+ * @param cont continuation to call once the message is sent
+ * @param cont_cls closure for continuation
+ *
+ * @return GNUNET_YES if the control message was sent, GNUNET_NO if not
+ */
+int GNUNET_DHT_set_malicious_dropper (struct GNUNET_DHT_Handle *handle, GNUNET_SCHEDULER_Task cont, void *cont_cls);
+
+/**
+ * Send a message to the DHT telling it to start issuing random PUT
+ * requests every 'frequency' milliseconds.
+ *
+ * @param handle handle to the DHT service
+ * @param frequency delay (in milliseconds) between sending malicious messages
+ * @param cont continuation to call once the message is sent
+ * @param cont_cls closure for continuation
+ *
+ * @return GNUNET_YES if the control message was sent, GNUNET_NO if not
+ */
+int GNUNET_DHT_set_malicious_putter (struct GNUNET_DHT_Handle *handle, int frequency, GNUNET_SCHEDULER_Task cont, void *cont_cls);
 
 #if 0                           /* keep Emacsens' auto-indent happy */
 {