summaryrefslogtreecommitdiff
path: root/src/or/hs_common.h
diff options
context:
space:
mode:
authorDavid Goulet <dgoulet@torproject.org>2017-05-10 15:04:40 -0400
committerNick Mathewson <nickm@torproject.org>2017-08-08 20:29:33 -0400
commit30b5c6a95ec9932f17f0b171c60229c1d77f829d (patch)
treef2dd4f04855198ace2bde6fb0a797353604699e3 /src/or/hs_common.h
parent7163ce7f62d6c487193fe43828420ba4fe721b9f (diff)
downloadtor-30b5c6a95ec9932f17f0b171c60229c1d77f829d.tar.gz
tor-30b5c6a95ec9932f17f0b171c60229c1d77f829d.zip
prop224: Link rendezvous circuit to edge connection
This commit refactors the handle_hs_exit_conn() function introduced at a prior commit that connects the rendezvous circuit to the edge connection used to connect to the service virtual port requested in a BEGIN cell. The refactor adds the support for prop224 adding the hs_service_set_conn_addr_port() function that has the same purpose has rend_service_set_connection_addr_port() from the legacy code. The rend_service_set_connection_addr_port() has also been a bit refactored so the common code can be shared between the two HS subsystems (legacy and prop224). In terms of functionallity, nothing has changed, we still close the circuits in case of failure for the same reasons as the legacy system currently does. Signed-off-by: David Goulet <dgoulet@torproject.org>
Diffstat (limited to 'src/or/hs_common.h')
-rw-r--r--src/or/hs_common.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/or/hs_common.h b/src/or/hs_common.h
index 695f0b8954..3670ff3790 100644
--- a/src/or/hs_common.h
+++ b/src/or/hs_common.h
@@ -218,6 +218,8 @@ void hs_get_responsible_hsdirs(const ed25519_public_key_t *blinded_pk,
uint64_t time_period_num, int is_next_period,
int is_client, smartlist_t *responsible_dirs);
+int hs_set_conn_addr_port(const smartlist_t *ports, edge_connection_t *conn);
+
#ifdef HS_COMMON_PRIVATE
#ifdef TOR_UNIT_TESTS