[tor-commits] [tor/master] hs: Note the connection attempt if descriptor is unusable

nickm at torproject.org nickm at torproject.org
Mon Aug 28 14:04:43 UTC 2017

commit e8c584176b92799126f9280a51f45e40db3cc119
Author: David Goulet <dgoulet at torproject.org>
Date:   Fri Aug 25 13:39:40 2017 -0400

    hs: Note the connection attempt if descriptor is unusable
    This way, we can clear off the directory requests from our cache and thus
    allow the next client to query those HSDir again at the next SOCKS connection.
    Signed-off-by: David Goulet <dgoulet at torproject.org>
 src/or/hs_client.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/or/hs_client.c b/src/or/hs_client.c
index 9c2aa34e9..99be058eb 100644
--- a/src/or/hs_client.c
+++ b/src/or/hs_client.c
@@ -1103,7 +1103,9 @@ hs_client_desc_has_arrived(const hs_ident_dir_conn_t *ident)
                         "Closing streams.");
-      /* XXX: Note the connection attempt. */
+      /* We are unable to use the descriptor so remove the directory request
+       * from the cache so the next connection can try again. */
+      note_connection_attempt_succeeded(edge_conn->hs_ident);
       goto end;

More information about the tor-commits mailing list