Upgrade the warn for EntryNodes without UseEntryGuards to an error

fixes bug 8180
This commit is contained in:
Nick Mathewson
2013-03-15 10:42:17 -04:00
parent c6ca199888
commit 686aaa5c4c
2 changed files with 11 additions and 4 deletions
+4 -4
View File
@@ -1,4 +1,4 @@
/* Copyright (c) 2001 Matej Pfajfar.
/* Copyright (c) 2001 Matej Pfajfar.
* Copyright (c) 2001-2004, Roger Dingledine.
* Copyright (c) 2004-2006, Roger Dingledine, Nick Mathewson.
* Copyright (c) 2007-2012, The Tor Project, Inc. */
@@ -3664,9 +3664,9 @@ options_validate(or_options_t *old_options, or_options_t *options,
if (options->UseBridges && options->EntryNodes)
REJECT("You cannot set both UseBridges and EntryNodes.");
if (options->EntryNodes && !options->UseEntryGuards)
log_warn(LD_CONFIG, "EntryNodes is set, but UseEntryGuards is disabled. "
"EntryNodes will be ignored.");
if (options->EntryNodes && !options->UseEntryGuards) {
REJECT("If EntryNodes is set, UseEntryGuards must be enabled.");
}
options->_AllowInvalid = 0;
if (options->AllowInvalidNodes) {