aboutsummaryrefslogtreecommitdiff
path: root/src/or/protover.c
diff options
context:
space:
mode:
authorIsis Lovecruft <isis@torproject.org>2018-05-07 23:59:06 +0000
committerNick Mathewson <nickm@torproject.org>2018-05-22 12:13:41 -0400
commitb681438daf06d8d5b1c67d8c78f1b041f9b1f5b8 (patch)
tree094e2e02c6f291acea1e28d74d8ff509705246b4 /src/or/protover.c
parenteb966928428a80c105d33bd60bcae5503a1adeb7 (diff)
downloadtor-b681438daf06d8d5b1c67d8c78f1b041f9b1f5b8.tar.gz
tor-b681438daf06d8d5b1c67d8c78f1b041f9b1f5b8.zip
vote: TROVE-2018-005 Make DirAuths omit misbehaving routers from their vote.
Diffstat (limited to 'src/or/protover.c')
-rw-r--r--src/or/protover.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/or/protover.c b/src/or/protover.c
index 24b3813614..94e6b11c46 100644
--- a/src/or/protover.c
+++ b/src/or/protover.c
@@ -274,6 +274,18 @@ parse_protocol_list(const char *s)
}
/**
+ * Return true if the unparsed protover in <b>s</b> would contain a protocol
+ * name longer than MAX_PROTOCOL_NAME_LENGTH, and false otherwise.
+ */
+bool
+protover_contains_long_protocol_names(const char *s)
+{
+ if (!parse_protocol_list(s))
+ return true;
+ return false;
+}
+
+/**
* Given a protocol type and version number, return true iff we know
* how to speak that protocol.
*/