From 743a5ef2b3781b593f5299758d0a7fc78b5816c4 Mon Sep 17 00:00:00 2001 From: David Goulet Date: Thu, 14 Jan 2021 09:42:56 -0500 Subject: relay: Don't flag that we published if descriptor build fails In case building the descriptor would fail, we could still flag that we did in fact publish the descriptors leading to no more attempt at publishing it which in turn makes the relay silent for some hours and not try to rebuild the descriptor later. This has been spotted with #40231 because the operator used a localhost address for the ORPort and "AssumeReachable 1" leading to this code path where the descriptor failed to build but all conditions to "can I publish" were met. Related to #40231 Signed-off-by: David Goulet --- src/feature/relay/router.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/feature/relay/router.h') diff --git a/src/feature/relay/router.h b/src/feature/relay/router.h index 2648bb5112..aa03c27142 100644 --- a/src/feature/relay/router.h +++ b/src/feature/relay/router.h @@ -102,7 +102,7 @@ int router_extrainfo_digest_is_me(const char *digest); int router_is_me(const routerinfo_t *router); bool router_addr_is_my_published_addr(const tor_addr_t *addr); int router_build_fresh_descriptor(routerinfo_t **r, extrainfo_t **e); -int router_rebuild_descriptor(int force); +bool router_rebuild_descriptor(int force); char *router_dump_router_to_string(routerinfo_t *router, const crypto_pk_t *ident_key, const crypto_pk_t *tap_key, -- cgit v1.2.3-54-g00ecf