summaryrefslogtreecommitdiff
path: root/src/or/hs_service.c
diff options
context:
space:
mode:
authorDavid Goulet <dgoulet@torproject.org>2017-11-10 14:34:41 -0500
committerNick Mathewson <nickm@torproject.org>2017-12-05 19:39:46 -0500
commitb71a9b60cc0c29899637acc0610cb87c56869c1e (patch)
treece1d22cf93c266f64585a7780b5dedf670e613fe /src/or/hs_service.c
parent3b436d495fc6ad59ff5d9406d7ef17494286c299 (diff)
downloadtor-b71a9b60cc0c29899637acc0610cb87c56869c1e.tar.gz
tor-b71a9b60cc0c29899637acc0610cb87c56869c1e.zip
hs-v3: Implement HS_DESC CREATED event
This makes the REPLICA= field optional for the control port event. A v2 service will always pass it and v3 is ignored. Signed-off-by: David Goulet <dgoulet@torproject.org>
Diffstat (limited to 'src/or/hs_service.c')
-rw-r--r--src/or/hs_service.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/or/hs_service.c b/src/or/hs_service.c
index a659a126fc..65df5b2693 100644
--- a/src/or/hs_service.c
+++ b/src/or/hs_service.c
@@ -30,6 +30,7 @@
#include "hs_circuit.h"
#include "hs_common.h"
#include "hs_config.h"
+#include "hs_control.h"
#include "hs_circuit.h"
#include "hs_descriptor.h"
#include "hs_ident.h"
@@ -1431,6 +1432,9 @@ build_service_descriptor(hs_service_t *service, time_t now,
/* Assign newly built descriptor to the next slot. */
*desc_out = desc;
+ /* Fire a CREATED control port event. */
+ hs_control_desc_event_created(service->onion_address,
+ &desc->blinded_kp.pubkey);
return;
err: