config: Remove AllowSingleHopExits option

Deprecated in 0.2.9.2-alpha, this commits changes it as OBSOLETE() and cleans
up the code associated with it.

Partially fixes #22060

Signed-off-by: David Goulet <dgoulet@torproject.org>
This commit is contained in:
David Goulet
2017-04-25 13:44:06 -04:00
committed by Nick Mathewson
parent fea72571df
commit d52a1e2faa
7 changed files with 11 additions and 74 deletions
-43
View File
@@ -4189,48 +4189,6 @@ test_options_validate__virtual_addr(void *ignored)
tor_free(msg);
}
static void
test_options_validate__exits(void *ignored)
{
(void)ignored;
int ret;
char *msg;
options_test_data_t *tdata = NULL;
setup_capture_of_logs(LOG_WARN);
free_options_test_data(tdata);
tdata = get_options_test_data(TEST_OPTIONS_DEFAULT_VALUES
"AllowSingleHopExits 1"
);
ret = options_validate(tdata->old_opt, tdata->opt, tdata->def_opt, 0, &msg);
tt_int_op(ret, OP_EQ, 0);
expect_log_msg("You have set AllowSingleHopExits; "
"now your relay will allow others to make one-hop exits. However,"
" since by default most clients avoid relays that set this option,"
" most clients will ignore you.\n");
tor_free(msg);
free_options_test_data(tdata);
tdata = get_options_test_data(TEST_OPTIONS_DEFAULT_VALUES
"AllowSingleHopExits 1\n"
VALID_DIR_AUTH
);
mock_clean_saved_logs();
ret = options_validate(tdata->old_opt, tdata->opt, tdata->def_opt, 0, &msg);
tt_int_op(ret, OP_EQ, 0);
expect_no_log_msg("You have set AllowSingleHopExits; "
"now your relay will allow others to make one-hop exits. However,"
" since by default most clients avoid relays that set this option,"
" most clients will ignore you.\n");
tor_free(msg);
done:
policies_free_all();
teardown_capture_of_logs();
free_options_test_data(tdata);
tor_free(msg);
}
static void
test_options_validate__testing_options(void *ignored)
{
@@ -4502,7 +4460,6 @@ struct testcase_t options_tests[] = {
LOCAL_VALIDATE_TEST(constrained_sockets),
LOCAL_VALIDATE_TEST(v3_auth),
LOCAL_VALIDATE_TEST(virtual_addr),
LOCAL_VALIDATE_TEST(exits),
LOCAL_VALIDATE_TEST(testing_options),
LOCAL_VALIDATE_TEST(accel),
END_OF_TESTCASES /* */