summaryrefslogtreecommitdiffstats
path: root/src/fastd.h
diff options
context:
space:
mode:
authorMatthias Schiffer <mschiffer@universe-factory.net>2014-01-26 01:52:00 +0100
committerMatthias Schiffer <mschiffer@universe-factory.net>2014-01-26 01:52:00 +0100
commit23d90c62f2807bda87c6021785e6e51d3c627e0c (patch)
tree6327ca4bde6a9b4a796cabac53dd8fd87070bb3c /src/fastd.h
parent8430688acb6e922bba903f04f560744736853c07 (diff)
downloadfastd-23d90c62f2807bda87c6021785e6e51d3c627e0c.tar
fastd-23d90c62f2807bda87c6021785e6e51d3c627e0c.zip
Add minimum handshake interval for unknown addresses (handles up to 8 addresses for now)
Diffstat (limited to 'src/fastd.h')
-rw-r--r--src/fastd.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/fastd.h b/src/fastd.h
index d03465d..268c2c7 100644
--- a/src/fastd.h
+++ b/src/fastd.h
@@ -138,6 +138,11 @@ struct fastd_stats {
uint64_t bytes;
};
+struct fastd_handshake_timeout {
+ fastd_peer_address_t address;
+ struct timespec timeout;
+};
+
struct fastd_config {
struct timespec long_ago;
@@ -281,6 +286,9 @@ struct fastd_context {
unsigned int randseed;
+ size_t unknown_handshake_pos;
+ fastd_handshake_timeout_t unknown_handshakes[8];
+
fastd_protocol_state_t *protocol_state;
};