diff options
author | Nick Mathewson <nickm@torproject.org> | 2005-10-04 22:23:31 +0000 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2005-10-04 22:23:31 +0000 |
commit | 61ea5168859785207062ca22be403bbac32f49e3 (patch) | |
tree | 166d3b8fc6374a5d7c8bb2b5de2d4376dd1d51cc /src/or/control.c | |
parent | 2d203fdcf319b45477bdcad7e3476ac3c45ee7e0 (diff) | |
download | tor-61ea5168859785207062ca22be403bbac32f49e3.tar.gz tor-61ea5168859785207062ca22be403bbac32f49e3.zip |
Check for named servers when looking them up by nickname;
warn when we'recalling a non-named server by its nickname;
don't warn twice about the same name.
Fix a bug in routers_update_status_from_networkstatus that made nearly
all clients never update routerinfo_t.is_named.
Try to list MyFamily elements by key, not by nickname.
Only warn about names that we generated ourself, or got from the local
user.
On TLS handshake, only check the other router's nickname against its
expected nickname if is_named is set.
svn:r5185
Diffstat (limited to 'src/or/control.c')
-rw-r--r-- | src/or/control.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/or/control.c b/src/or/control.c index dccb2d55a5..f522f79acd 100644 --- a/src/or/control.c +++ b/src/or/control.c @@ -1226,7 +1226,7 @@ handle_getinfo_helper(const char *question, char **answer) if (ri && ri->signed_descriptor) *answer = tor_strdup(ri->signed_descriptor); } else if (!strcmpstart(question, "desc/name/")) { - routerinfo_t *ri = router_get_by_nickname(question+strlen("desc/name/")); + routerinfo_t *ri = router_get_by_nickname(question+strlen("desc/name/"),1); if (ri && ri->signed_descriptor) *answer = tor_strdup(ri->signed_descriptor); } else if (!strcmpstart(question, "unregistered-servers-")) { @@ -1513,7 +1513,7 @@ handle_control_extendcircuit(connection_t *conn, uint32_t len, routers = smartlist_create(); SMARTLIST_FOREACH(router_nicknames, const char *, n, { - routerinfo_t *r = router_get_by_nickname(n); + routerinfo_t *r = router_get_by_nickname(n, 1); if (!r) { if (v0) send_control0_error(conn, ERR_NO_ROUTER, n); |