[tor-commits] [tor/release-0.3.2] Add another NULL-pointer fix for protover.c.
nickm at torproject.org
nickm at torproject.org
Sat Mar 3 13:17:13 UTC 2018
commit a83650852d3cd00c9916cae74d755ae55a6b506d
Author: Nick Mathewson <nickm at torproject.org>
Date: Wed Feb 14 10:45:57 2018 -0500
Add another NULL-pointer fix for protover.c.
This one can only be exploited if you can generate a correctly
signed consensus, so it's not as bad as 25074.
Fixes bug 25251; also tracked as TROVE-2018-004.
---
changes/trove-2018-004 | 8 ++++++++
src/or/protover.c | 5 +++++
2 files changed, 13 insertions(+)
diff --git a/changes/trove-2018-004 b/changes/trove-2018-004
new file mode 100644
index 000000000..37e0a89b0
--- /dev/null
+++ b/changes/trove-2018-004
@@ -0,0 +1,8 @@
+ o Minor bugfixes (denial-of-service):
+ - Fix a possible crash on malformed consensus. If a consensus had
+ contained an unparseable protocol line, it could have made clients
+ and relays crash with a null-pointer exception. To exploit this
+ issue, however, an attacker would need to be able to subvert the
+ directory-authority system. Fixes bug 25251; bugfix on
+ 0.2.9.4-alpha. Also tracked as TROVE-2018-004.
+
diff --git a/src/or/protover.c b/src/or/protover.c
index a75077462..e63036f78 100644
--- a/src/or/protover.c
+++ b/src/or/protover.c
@@ -624,6 +624,11 @@ protover_all_supported(const char *s, char **missing_out)
}
smartlist_t *entries = parse_protocol_list(s);
+ if (BUG(entries == NULL)) {
+ log_warn(LD_NET, "Received an unparseable protocol list %s"
+ " from the consensus", escaped(s));
+ return 1;
+ }
missing = smartlist_new();
More information about the tor-commits
mailing list