summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoger Dingledine <arma@torproject.org>2005-04-06 05:35:06 +0000
committerRoger Dingledine <arma@torproject.org>2005-04-06 05:35:06 +0000
commit94cecc712d023902653a1c04afbb65804c748876 (patch)
tree64d72fe2ef088564c5c40509cf0f18c6d4094353
parentb7cdcf34622eff7e2d805452e94883e8bd94f5d6 (diff)
downloadtor-94cecc712d023902653a1c04afbb65804c748876.tar.gz
tor-94cecc712d023902653a1c04afbb65804c748876.zip
note some features we intend to add.
svn:r4021
-rw-r--r--src/or/connection_or.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/or/connection_or.c b/src/or/connection_or.c
index bea644f51e..aa33b1c525 100644
--- a/src/or/connection_or.c
+++ b/src/or/connection_or.c
@@ -507,6 +507,7 @@ connection_tls_finish_handshake(connection_t *conn) {
log_fn(LOG_WARN, "Identity key not as expected for router at %s:%d: wanted %s but got %s",
conn->address, conn->port, conn->nickname, d);
control_event_or_conn_status(conn, OR_CONN_EVENT_FAILED);
+ // XXX if we're an authdir_mode, forget about nickname's descriptor
return -1;
}
} else if (strcasecmp(conn->nickname, nickname)) {
@@ -515,8 +516,14 @@ connection_tls_finish_handshake(connection_t *conn) {
"Other side (%s:%d) is '%s', but we tried to connect to '%s'",
conn->address, conn->port, nickname, conn->nickname);
control_event_or_conn_status(conn, OR_CONN_EVENT_FAILED);
+ // XXX if we're an authdir_mode, forget about nickname's descriptor
return -1;
}
+ if (authdir_mode(options)) {
+ /* I got exactly the guy I wanted. Now go through and blow away
+ * descriptors for exactly this Address:ORPort that aren't this guy. */
+ //XXX
+ }
} else {
if ((c=connection_get_by_identity_digest(digest_rcvd, CONN_TYPE_OR))) {
log_fn(LOG_INFO,"Router '%s' is already connected on fd %d. Dropping fd %d.", nickname, c->s, conn->s);