mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-12-06 19:41:15 +01:00
Don't allow v0 HS auths to act as clients
A v0 HS authority stores v0 HS descriptors in the same descriptor cache that its HS client functionality uses. Thus, if the HS authority operator clears its client HS descriptor cache, ALL v0 HS descriptors will be lost. That would be bad.
This commit is contained in:
committed by
Nick Mathewson
parent
2dc9546eef
commit
df5c7fedbd
@@ -3078,6 +3078,10 @@ options_validate(or_options_t *old_options, or_options_t *options,
|
||||
REJECT("FetchDirInfoExtraEarly requires that you also set "
|
||||
"FetchDirInfoEarly");
|
||||
|
||||
if (options->HSAuthoritativeDir && proxy_mode(options))
|
||||
REJECT("Running as authoritative v0 HS directory, but also configured "
|
||||
"as a client.");
|
||||
|
||||
if (options->ConnLimit <= 0) {
|
||||
tor_asprintf(msg,
|
||||
"ConnLimit must be greater than 0, but was set to %d",
|
||||
|
||||
Reference in New Issue
Block a user