/**
* Block for testing.
*/
- GNUNET_BLOCK_TYPE_TEST = 8
+ GNUNET_BLOCK_TYPE_TEST = 8,
+#if HAVE_MALICIOUS
+ /**
+ * Block for simulating malicious peers.
+ */
+ GNUNET_BLOCK_DHT_MALICIOUS_MESSAGE_TYPE = 9
+#endif
};
* @param block block to get the key for
* @param block_size number of bytes in block
* @param key set to the key (query) for the given block
- * @return GNUNET_OK on success, GNUNET_SYSERR if type not supported
+ * @return GNUNET_OK on success,
+ * GNUNET_NO if the block is malformed, FIXME: cg!
+ * GNUNET_SYSERR if type not supported
* (or if extracting a key from a block of this type does not work)
*/
int
typedef int (*GNUNET_DATACACHE_Iterator) (void *cls,
struct GNUNET_TIME_Absolute exp,
const GNUNET_HashCode * key,
- uint32_t size,
+ uint32_t size, /* FIXME: use size_t? */
const char *data,
enum GNUNET_BLOCK_Type type);