diff options
author | David Goulet <dgoulet@torproject.org> | 2017-08-25 14:03:15 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2017-09-05 08:24:22 -0400 |
commit | 9e900d1db7c8c9e164b5b14d5cdd4099c1ce45f0 (patch) | |
tree | abc7f4ba0b40ac72611c1262e00cd4f8ab0e1ee0 /src/or/main.c | |
parent | f2f1cab2b3c6a56f93862c424663f083b79c7bc3 (diff) | |
download | tor-9e900d1db7c8c9e164b5b14d5cdd4099c1ce45f0.tar.gz tor-9e900d1db7c8c9e164b5b14d5cdd4099c1ce45f0.zip |
hs: Don't enter the HS v3 subsystem without a live consensus
The service needs the latest SRV and set of relays for the best accurate
hashring to upload its descriptor to so it needs a live consensus thus don't
do anything until we have it.
Fixes #23331
Signed-off-by: David Goulet <dgoulet@torproject.org>
Diffstat (limited to 'src/or/main.c')
-rw-r--r-- | src/or/main.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/or/main.c b/src/or/main.c index 5d51d1dead..d57ef521c6 100644 --- a/src/or/main.c +++ b/src/or/main.c @@ -2110,7 +2110,8 @@ hs_service_callback(time_t now, const or_options_t *options) /* We need to at least be able to build circuits and that we actually have * a working network. */ - if (!have_completed_a_circuit() || net_is_disabled()) { + if (!have_completed_a_circuit() || net_is_disabled() || + networkstatus_get_live_consensus(now) == NULL) { goto end; } |