]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
test/parseconf: Update config parsing tests for 32410
authorteor <teor@torproject.org>
Thu, 7 Nov 2019 01:44:51 +0000 (11:44 +1000)
committerteor <teor@torproject.org>
Thu, 7 Nov 2019 01:44:51 +0000 (11:44 +1000)
22 files changed:
src/test/conf_examples/badnick_1/error_no_dirauth_relay [deleted file]
src/test/conf_examples/badnick_1/expected_no_dirauth_relay [new file with mode: 0644]
src/test/conf_examples/badnick_1/torrc
src/test/conf_examples/badnick_2/error_no_dirauth_relay [deleted file]
src/test/conf_examples/badnick_2/expected_no_dirauth_relay [new file with mode: 0644]
src/test/conf_examples/badnick_2/torrc
src/test/conf_examples/contactinfo_notutf8/error_no_dirauth_relay [deleted file]
src/test/conf_examples/contactinfo_notutf8/expected_no_dirauth_relay [new file with mode: 0644]
src/test/conf_examples/contactinfo_notutf8/torrc
src/test/conf_examples/example_1/error_no_dirauth_relay [deleted file]
src/test/conf_examples/example_3/error_no_dirauth_relay [deleted file]
src/test/conf_examples/pt_01/error_no_dirauth_relay [deleted file]
src/test/conf_examples/pt_02/error_no_dirauth_relay [deleted file]
src/test/conf_examples/pt_02/expected_no_dirauth_relay [new file with mode: 0644]
src/test/conf_examples/pt_02/torrc
src/test/conf_examples/pt_03/error_no_dirauth_relay [deleted file]
src/test/conf_examples/pt_04/error_no_dirauth_relay [deleted file]
src/test/conf_examples/pt_06/error_no_dirauth_relay [deleted file]
src/test/conf_examples/pt_08/error_no_dirauth_relay [deleted file]
src/test/conf_examples/pt_08/expected_no_dirauth_relay [new file with mode: 0644]
src/test/conf_examples/pt_08/torrc
src/test/conf_examples/relay_01/error_no_dirauth_relay [deleted file]

diff --git a/src/test/conf_examples/badnick_1/error_no_dirauth_relay b/src/test/conf_examples/badnick_1/error_no_dirauth_relay
deleted file mode 100644 (file)
index 9f9c0fd..0000000
+++ /dev/null
@@ -1 +0,0 @@
-This tor was built with relay mode disabled.
diff --git a/src/test/conf_examples/badnick_1/expected_no_dirauth_relay b/src/test/conf_examples/badnick_1/expected_no_dirauth_relay
new file mode 100644 (file)
index 0000000..b00be15
--- /dev/null
@@ -0,0 +1 @@
+Nickname TooManyCharactersInThisNickname
index 41ee4894f114280dd2e5fcebb72731bdc2ec7e33..087e3f2ff15a255265f3faad5a27a7d3813403f9 100644 (file)
@@ -1,2 +1,4 @@
 # This nickname is too long; we won't accept it.
+# (Unless the relay module is disabled, because Nickname is a
+# relay-only option. We'll ignore all relay-only options in #32395.)
 Nickname TooManyCharactersInThisNickname
diff --git a/src/test/conf_examples/badnick_2/error_no_dirauth_relay b/src/test/conf_examples/badnick_2/error_no_dirauth_relay
deleted file mode 100644 (file)
index 9f9c0fd..0000000
+++ /dev/null
@@ -1 +0,0 @@
-This tor was built with relay mode disabled.
diff --git a/src/test/conf_examples/badnick_2/expected_no_dirauth_relay b/src/test/conf_examples/badnick_2/expected_no_dirauth_relay
new file mode 100644 (file)
index 0000000..08dcdc3
--- /dev/null
@@ -0,0 +1 @@
+Nickname has a space
index 07acc61698ea9b7e782ab38fdf8a81c09bade213..51a5f96c0025421c82e5ba76ce726df593688e9b 100644 (file)
@@ -1,2 +1,4 @@
 # this nickname has spaces in it and won't work.
+# (Unless the relay module is disabled, because Nickname is a
+# relay-only option. We'll ignore all relay-only options in #32395.)
 Nickname has a space
diff --git a/src/test/conf_examples/contactinfo_notutf8/error_no_dirauth_relay b/src/test/conf_examples/contactinfo_notutf8/error_no_dirauth_relay
deleted file mode 100644 (file)
index 9f9c0fd..0000000
+++ /dev/null
@@ -1 +0,0 @@
-This tor was built with relay mode disabled.
diff --git a/src/test/conf_examples/contactinfo_notutf8/expected_no_dirauth_relay b/src/test/conf_examples/contactinfo_notutf8/expected_no_dirauth_relay
new file mode 100644 (file)
index 0000000..cc8bd7b
--- /dev/null
@@ -0,0 +1 @@
+ContactInfo "\304\353\304\353\304\353@example.com"
index 2ee4d093c58d1c0ddd39f0bc849bdf5d6a7da34f..0176a56a975090aff3640f400efad52de3edcb50 100644 (file)
@@ -1 +1,5 @@
+# We only accept ContactInfo in UTF-8 (or 7-bit ASCII)
+# (Unless the relay module is disabled, because ContactInfo is a
+# relay-only option. We'll ignore all relay-only options in #32395.
+# But at the moment, tor canonicalises and quotes the string.)
 ContactInfo ÄëÄëÄë@example.com
diff --git a/src/test/conf_examples/example_1/error_no_dirauth_relay b/src/test/conf_examples/example_1/error_no_dirauth_relay
deleted file mode 100644 (file)
index 9f9c0fd..0000000
+++ /dev/null
@@ -1 +0,0 @@
-This tor was built with relay mode disabled.
diff --git a/src/test/conf_examples/example_3/error_no_dirauth_relay b/src/test/conf_examples/example_3/error_no_dirauth_relay
deleted file mode 100644 (file)
index 9f9c0fd..0000000
+++ /dev/null
@@ -1 +0,0 @@
-This tor was built with relay mode disabled.
diff --git a/src/test/conf_examples/pt_01/error_no_dirauth_relay b/src/test/conf_examples/pt_01/error_no_dirauth_relay
deleted file mode 100644 (file)
index 9f9c0fd..0000000
+++ /dev/null
@@ -1 +0,0 @@
-This tor was built with relay mode disabled.
diff --git a/src/test/conf_examples/pt_02/error_no_dirauth_relay b/src/test/conf_examples/pt_02/error_no_dirauth_relay
deleted file mode 100644 (file)
index 9f9c0fd..0000000
+++ /dev/null
@@ -1 +0,0 @@
-This tor was built with relay mode disabled.
diff --git a/src/test/conf_examples/pt_02/expected_no_dirauth_relay b/src/test/conf_examples/pt_02/expected_no_dirauth_relay
new file mode 100644 (file)
index 0000000..f5cd26e
--- /dev/null
@@ -0,0 +1,8 @@
+ExtORPort illegal_hostname_chars$()^*%(%
+ServerTransportListenAddr bad
+ServerTransportListenAddr bad2 illegal_hostname_chars$()^*%(%
+ServerTransportOptions bad
+ServerTransportOptions bad2 not_kv
+ServerTransportPlugin bad
+ServerTransportPlugin bad2 exec
+ServerTransportPlugin bad3 exec /
index d047d615f74949b24fc8f762e3dffb8cc9447ce5..825f2c4be47c55c1ba321028e9503b45ee654646 100644 (file)
@@ -1,6 +1,8 @@
 # Relay PT tests
 # Options from relay/transport_config.c
 # Bad options are also ignored
+# (Unless the relay module is disabled, because they are relay-only
+# options. We'll ignore all relay-only options in #32395.)
 ExtORPort illegal_hostname_chars$()^*%(%#%)#(%*
 ServerTransportPlugin bad
 ServerTransportPlugin bad2 exec
diff --git a/src/test/conf_examples/pt_03/error_no_dirauth_relay b/src/test/conf_examples/pt_03/error_no_dirauth_relay
deleted file mode 100644 (file)
index 9f9c0fd..0000000
+++ /dev/null
@@ -1 +0,0 @@
-This tor was built with relay mode disabled.
diff --git a/src/test/conf_examples/pt_04/error_no_dirauth_relay b/src/test/conf_examples/pt_04/error_no_dirauth_relay
deleted file mode 100644 (file)
index 9f9c0fd..0000000
+++ /dev/null
@@ -1 +0,0 @@
-This tor was built with relay mode disabled.
diff --git a/src/test/conf_examples/pt_06/error_no_dirauth_relay b/src/test/conf_examples/pt_06/error_no_dirauth_relay
deleted file mode 100644 (file)
index 9f9c0fd..0000000
+++ /dev/null
@@ -1 +0,0 @@
-This tor was built with relay mode disabled.
diff --git a/src/test/conf_examples/pt_08/error_no_dirauth_relay b/src/test/conf_examples/pt_08/error_no_dirauth_relay
deleted file mode 100644 (file)
index 9f9c0fd..0000000
+++ /dev/null
@@ -1 +0,0 @@
-This tor was built with relay mode disabled.
diff --git a/src/test/conf_examples/pt_08/expected_no_dirauth_relay b/src/test/conf_examples/pt_08/expected_no_dirauth_relay
new file mode 100644 (file)
index 0000000..9a1a9bd
--- /dev/null
@@ -0,0 +1,2 @@
+ExtORPort unix:/
+ServerTransportPlugin bad3 exec /
index bf36a185a42f569d27cc7375063cb9d2322372d0..6f1d79d706a5649adc11fcc816119a1c7e6dda7d 100644 (file)
@@ -1,5 +1,7 @@
 # Relay PT tests
 # Options from relay/transport_config.c
 # Try an invalid config with a unix socket for ExtORPort
+# (Unless the relay module is disabled, because they are relay-only
+# options. We'll ignore all relay-only options in #32395.)
 ExtORPort unix:/
 ServerTransportPlugin bad3 exec /
diff --git a/src/test/conf_examples/relay_01/error_no_dirauth_relay b/src/test/conf_examples/relay_01/error_no_dirauth_relay
deleted file mode 100644 (file)
index 9f9c0fd..0000000
+++ /dev/null
@@ -1 +0,0 @@
-This tor was built with relay mode disabled.