diff options
author | Peter Palfrader <peter@palfrader.org> | 2016-03-01 17:08:14 +0100 |
---|---|---|
committer | Peter Palfrader <peter@palfrader.org> | 2016-03-01 17:08:14 +0100 |
commit | 1ef7df551d8efc0a74536006c17bdaa3cbb0931d (patch) | |
tree | fcfbd01f83184691a22d72e0883c8cb001ca9f73 /src/test/test_config.c | |
parent | 9fc472e1a8a53a18dfbd5c9cde2f1c268c335e96 (diff) | |
download | tor-1ef7df551d8efc0a74536006c17bdaa3cbb0931d.tar.gz tor-1ef7df551d8efc0a74536006c17bdaa3cbb0931d.zip |
First RelaxDirModeCheck implementation
Diffstat (limited to 'src/test/test_config.c')
-rw-r--r-- | src/test/test_config.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/test/test_config.c b/src/test/test_config.c index b11848102e..6d9b4916e3 100644 --- a/src/test/test_config.c +++ b/src/test/test_config.c @@ -4038,6 +4038,13 @@ test_config_parse_port_config__ports__ports_given(void *data) "127.0.0.3", 0, 0); tt_int_op(ret, OP_EQ, -1); + // Test failure if we specify group writable for an IP Port + config_free_lines(config_port_invalid); config_port_invalid = NULL; + config_port_invalid = mock_config_line("DNSPort", "42 RelaxDirModeCheck"); + ret = parse_port_config(NULL, config_port_invalid, NULL, "DNS", 0, + "127.0.0.3", 0, 0); + tt_int_op(ret, OP_EQ, -1); + // Test success with only a port (this will fail without a default address) config_free_lines(config_port_valid); config_port_valid = NULL; config_port_valid = mock_config_line("DNSPort", "42"); |