summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorRoger Dingledine <arma@torproject.org>2004-04-05 22:01:35 +0000
committerRoger Dingledine <arma@torproject.org>2004-04-05 22:01:35 +0000
commit2bb18e62cb7a323b08577b107c32b8c2976e2453 (patch)
treef3a831ead3da595216538ee3a6c08c0b04fbf4e4 /src
parent62b7ae6c9d1d02f08540ff968daa21369eadfaa6 (diff)
downloadtor-2bb18e62cb7a323b08577b107c32b8c2976e2453.tar.gz
tor-2bb18e62cb7a323b08577b107c32b8c2976e2453.zip
make rend apconn send to the right cpath layer
and fix circuit_log_path to know about rend circs svn:r1496
Diffstat (limited to 'src')
-rw-r--r--src/or/circuit.c6
-rw-r--r--src/or/command.c2
-rw-r--r--src/or/rendclient.c4
3 files changed, 8 insertions, 4 deletions
diff --git a/src/or/circuit.c b/src/or/circuit.c
index 82fb5aa74c..97ce3d21f4 100644
--- a/src/or/circuit.c
+++ b/src/or/circuit.c
@@ -944,7 +944,11 @@ void circuit_log_path(int severity, circuit_t *circ) {
snprintf(s, sizeof(buf) - (s - buf), "%s(%s) ",
router->nickname, states[hop->state]);
} else {
- snprintf(s, sizeof(buf) - (s - buf), "UNKNOWN ");
+ if(circ->purpose == CIRCUIT_PURPOSE_C_REND_JOINED) {
+ snprintf(s, sizeof(buf) - (s - buf), "(rend join)");
+ } else {
+ snprintf(s, sizeof(buf) - (s - buf), "UNKNOWN ");
+ }
}
hop=hop->next;
} while(hop!=circ->cpath);
diff --git a/src/or/command.c b/src/or/command.c
index b180c47505..4c4010970f 100644
--- a/src/or/command.c
+++ b/src/or/command.c
@@ -193,7 +193,7 @@ static void command_process_destroy_cell(cell_t *cell, connection_t *conn) {
return;
}
- log_fn(LOG_DEBUG,"Received for circID %d.",cell->circ_id);
+ log_fn(LOG_INFO,"Received for circID %d.",cell->circ_id);
if(circ->state == CIRCUIT_STATE_ONIONSKIN_PENDING) {
onion_pending_remove(circ);
}
diff --git a/src/or/rendclient.c b/src/or/rendclient.c
index ec052cd8d4..af4edde2cf 100644
--- a/src/or/rendclient.c
+++ b/src/or/rendclient.c
@@ -163,8 +163,6 @@ rend_client_receive_rendezvous(circuit_t *circ, const char *request, int request
connection_t *apconn;
crypt_path_t *hop;
char keys[DIGEST_LEN+CPATH_KEY_MATERIAL_LEN];
- char buf[DIGEST_LEN+9];
- char expected_digest[DIGEST_LEN];
if(circ->purpose != CIRCUIT_PURPOSE_C_REND_READY ||
!circ->build_state->pending_final_cpath) {
@@ -203,6 +201,8 @@ rend_client_receive_rendezvous(circuit_t *circ, const char *request, int request
circ->build_state->pending_final_cpath = NULL; /* prevent double-free */
for(apconn = circ->p_streams; apconn; apconn = apconn->next_stream) {
+ apconn->cpath_layer = circ->cpath->prev;
+ /* now the last hop is different. be sure to send all the way. */
if(connection_ap_handshake_send_begin(apconn, circ) < 0)
return -1;
}