From: Peter van Dijk Date: Mon, 13 May 2013 07:54:10 +0000 (+0200) Subject: add recursor txt escaping test X-Git-Tag: auth-3.3-rc1~65 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b3fef90e58836668edd585029c10ae8f7d4599ca;p=thirdparty%2Fpdns.git add recursor txt escaping test --- diff --git a/regression-tests.recursor/config.sh b/regression-tests.recursor/config.sh index bdfe3e0a1b..e9a3e6ffc2 100755 --- a/regression-tests.recursor/config.sh +++ b/regression-tests.recursor/config.sh @@ -62,6 +62,7 @@ example.net. 3600 IN NS ns2.example.net. ns.example.net. 3600 IN A $PREFIX.10 ns2.example.net. 3600 IN A $PREFIX.11 www.example.net. 3600 IN A 192.0.2.1 +weirdtxt.example.net. 3600 IN IN TXT "x\014x" arthur.example.net. 3600 IN NS ns.arthur.example.net. arthur.example.net. 3600 IN NS ns2.arthur.example.net. ns.arthur.example.net. 3600 IN A $PREFIX.12 diff --git a/regression-tests.recursor/txt-escaping/command b/regression-tests.recursor/txt-escaping/command new file mode 100755 index 0000000000..d12c03b647 --- /dev/null +++ b/regression-tests.recursor/txt-escaping/command @@ -0,0 +1,2 @@ +#!/bin/sh +cleandig weirdtxt.example.net txt | sed 's/\(.*\tIN\t[A-Z0-9]\+\t\)\([0-9]\+\)/\13600/' diff --git a/regression-tests.recursor/txt-escaping/description b/regression-tests.recursor/txt-escaping/description new file mode 100644 index 0000000000..375fc7c29b --- /dev/null +++ b/regression-tests.recursor/txt-escaping/description @@ -0,0 +1 @@ +Simple resolving of a TXT with characters in it that we used to choke on. diff --git a/regression-tests.recursor/txt-escaping/expected_result b/regression-tests.recursor/txt-escaping/expected_result new file mode 100644 index 0000000000..84ecdc49b6 --- /dev/null +++ b/regression-tests.recursor/txt-escaping/expected_result @@ -0,0 +1,3 @@ +0 weirdtxt.example.net. IN TXT 3600 "xx" +Rcode: 0, RD: 1, QR: 1, TC: 0, AA: 0, opcode: 0 +Reply to question for qname='weirdtxt.example.net.', qtype=TXT