]> git.ipfire.org Git - thirdparty/pdns.git/blame - regression-tests.recursor-dnssec/test_NoDS.py
Merge pull request #13927 from rgacogne/fix-fclose-warnings
[thirdparty/pdns.git] / regression-tests.recursor-dnssec / test_NoDS.py
CommitLineData
e9321921
PL
1import dns
2from recursortests import RecursorTest
3
4
5class testNoDS(RecursorTest):
6 _confdir = 'NoDS'
7
8 _config_template = """dnssec=validate"""
9 _lua_config_file = """clearDS(".")"""
10
11 def testNoDSInsecure(self):
12 """#4430 When the root DS is removed, the result must be Insecure"""
13
14 msg = dns.message.make_query("ted.bogus.example.", dns.rdatatype.A)
15 msg.flags = dns.flags.from_text('AD RD')
16 msg.use_edns(edns=0, ednsflags=dns.flags.edns_from_text('DO'))
17
18 res = self.sendUDPQuery(msg)
19
20 self.assertMessageHasFlags(res, ['QR', 'RA', 'RD'], ['DO'])
21 self.assertRcodeEqual(res, dns.rcode.NOERROR)