[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[or-cvs] r13133: Add a missing "goto err" when parsing v2 ns docs (in tor/trunk: . src/or)
Author: nickm
Date: 2008-01-14 14:00:33 -0500 (Mon, 14 Jan 2008)
New Revision: 13133
Modified:
tor/trunk/
tor/trunk/ChangeLog
tor/trunk/src/or/routerparse.c
Log:
r17614@catbus: nickm | 2008-01-14 13:55:25 -0500
Add a missing "goto err" when parsing v2 ns docs
Property changes on: tor/trunk
___________________________________________________________________
svk:merge ticket from /tor/trunk [r17614] on 8246c3cf-6607-4228-993b-4d95d33730f1
Modified: tor/trunk/ChangeLog
===================================================================
--- tor/trunk/ChangeLog 2008-01-14 19:00:28 UTC (rev 13132)
+++ tor/trunk/ChangeLog 2008-01-14 19:00:33 UTC (rev 13133)
@@ -47,6 +47,9 @@
- Detect more kinds of possible internal error.
- Avoid possible segfault if key generation fails in
crypto_pk_hybrid_encrypt. Bugfix on 0.2.0.
+ - Avoid segfault in the case where a badly behaved v2 versioning
+ directory sends a signed networkstatus with missing client-versions.
+ Bugfix on 0.1.2.
o Minor features (controller):
- Get NS events working again. (Patch from tup)
Modified: tor/trunk/src/or/routerparse.c
===================================================================
--- tor/trunk/src/or/routerparse.c 2008-01-14 19:00:28 UTC (rev 13132)
+++ tor/trunk/src/or/routerparse.c 2008-01-14 19:00:33 UTC (rev 13133)
@@ -1882,7 +1882,8 @@
if (ns->recommends_versions) {
if (!(tok = find_first_by_keyword(tokens, K_CLIENT_VERSIONS))) {
- log_warn(LD_DIR, "Missing client-versions");
+ log_warn(LD_DIR, "Missing client-versions on versioning directory");
+ goto err;
}
ns->client_versions = tok->args[0];
tok->args[0] = NULL;