aboutsummaryrefslogtreecommitdiff
path: root/src/or/dirserv.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2017-02-15 07:48:42 -0500
committerNick Mathewson <nickm@torproject.org>2017-02-15 07:48:42 -0500
commit76d79d597aeba1d9182414acf038ed376cd5139c (patch)
tree4a666199c7c3d186060a162d86a9d82b0044ce3e /src/or/dirserv.c
parentdec7dc3d823a8a9cc1d9d75d1b803a6e6b308a8e (diff)
parent5d88267bf47fb532b53691ab428cbfd9db3881cf (diff)
downloadtor-76d79d597aeba1d9182414acf038ed376cd5139c.tar.gz
tor-76d79d597aeba1d9182414acf038ed376cd5139c.zip
Merge branch 'maint-0.2.9'
Diffstat (limited to 'src/or/dirserv.c')
-rw-r--r--src/or/dirserv.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/or/dirserv.c b/src/or/dirserv.c
index f62f2d1c2f..af01f8c283 100644
--- a/src/or/dirserv.c
+++ b/src/or/dirserv.c
@@ -365,6 +365,16 @@ dirserv_get_status_impl(const char *id_digest, const char *nickname,
strmap_size(fingerprint_list->fp_by_name),
digestmap_size(fingerprint_list->status_by_digest));
+ if (platform) {
+ tor_version_t ver_tmp;
+ if (tor_version_parse_platform(platform, &ver_tmp, 1) < 0) {
+ if (msg) {
+ *msg = "Malformed platform string.";
+ }
+ return FP_REJECT;
+ }
+ }
+
/* Versions before Tor 0.2.4.18-rc are too old to support, and are
* missing some important security fixes too. Disable them. */
if (platform && !tor_version_as_new_as(platform,"0.2.4.18-rc")) {