2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-29 21:47:59 +00:00

2615 Commits

Author SHA1 Message Date
Michał Kępień
3a447d02b4 Prepare release notes for BIND 9.17.7 2020-11-26 12:12:17 +01:00
Matthijs Mekking
64db30942d Add NSEC3PARAM unit test, refactor zone.c
Add unit test to ensure the right NSEC3PARAM event is scheduled in
'dns_zone_setnsec3param()'.  To avoid scheduling and managing actual
tasks, split up the 'dns_zone_setnsec3param()' function in two parts:

1. 'dns__zone_lookup_nsec3param()' that will check if the requested
   NSEC3 parameters already exist, and if a new salt needs to be
   generated.

2. The actual scheduling of the new NSEC3PARAM event (if needed).
2020-11-26 10:43:59 +01:00
Matthijs Mekking
114af58ee2 Support for NSEC3 in dnssec-policy
Implement support for NSEC3 in dnssec-policy.  Store the configuration
in kasp objects. When configuring a zone, call 'dns_zone_setnsec3param'
to queue an nsec3param event. This will ensure that any previous
chains will be removed and a chain according to the dnssec-policy is
created.

Add tests for dnssec-policy zones that uses the new 'nsec3param'
option, as well as changing to new values, changing to NSEC, and
changing from NSEC.
2020-11-26 10:43:27 +01:00
Evan Hunt
c3a90b1d2c create system test with asynchronous plugin
the test-async plugin uses ns_query_hookasync() at the
NS_QUERY_DONE_SEND hook point to call an asynchronous function.
the only effect is to change the query response code to "NOTIMP",
so we can confirm that the hook ran and resumed correctly.
2020-11-24 15:11:39 -08:00
JINMEI Tatuya
75cdd758ed implementation of hook-based asynchronous functionality
previously query plugins were strictly synchrounous - the query
process would be interrupted at some point, data would be looked
up or a change would be made, and then the query processing would
resume immediately.

this commit enables query plugins to initiate asynchronous processes
and resume on a completion event, as with recursion.
2020-11-24 15:11:39 -08:00
Mark Andrews
38d6f68de4 add dns_dns64_findprefix 2020-11-25 08:25:29 +11:00
Michal Nowak
a0d359bbfa
Add unused headers check to CI 2020-11-11 10:08:12 +01:00
Michal Nowak
9088052225
Drop unused headers 2020-11-11 10:08:12 +01:00
Michal Nowak
2f9f6f1fac
Revert "Drop bigkey"
This reverts commit ef6703351a726eb9a8d8305075f1ee0f5be83516.

It is believed that the bigkey test is still useful.
2020-11-10 17:34:05 +01:00
Witold Kręcicki
d2a2804069 DoT test
Preliminary test for DNSoverTLS - add the dot-port template to system
tests, test a simple query to an authoritative.
2020-11-10 14:17:18 +01:00
Witold Kręcicki
b2ee0e9dc3 netmgr: server-side TLS support
Add server-side TLS support to netmgr - that includes moving some of the
isc_nm_ functions from tcp.c to a wrapper in netmgr.c calling a proper
tcp or tls function, and a new isc_nm_listentls() function.

Add DoT support to tcpdns - isc_nm_listentlsdns().
2020-11-10 14:16:27 +01:00
Michal Nowak
ef6703351a
Drop bigkey
The 'bigkey' binary is not used anywhere, therefor it's sources should
be removed.
2020-11-05 17:17:14 +01:00
Ondřej Surý
14f54d13dc add a netmgr unit test
tests of UDP and TCP cases including:
- sending and receiving
- closure sockets without reading or sending
- closure of sockets at various points while sending and receiving
- since the teste is multithreaded, cmocka now aborts tests on the
  first failure, so that failures in subthreads are caught and
  reported correctly.
2020-10-30 11:11:54 +01:00
Mark Andrews
d7840f4b93 Check that a zone in the process of being signed resolves
ans10 simulates a local anycast server which has both signed and
unsigned instances of a zone.  'A' queries get answered from the
signed instance.  Everything else gets answered from the unsigned
instance.  The resulting answer should be insecure.
2020-10-30 00:17:24 +11:00
Ondřej Surý
37b9511ce1 Use libuv's shared library handling capabilities
While libltdl is a feature-rich library, BIND 9 code only uses its basic
capabilities, which are also provided by libuv and which BIND 9 already
uses for other purposes.  As libuv's cross-platform shared library
handling interface is modeled after the POSIX dlopen() interface,
converting code using the latter to the former is simple.  Replace
libltdl function calls with their libuv counterparts, refactoring the
code as necessary.  Remove all use of libltdl from the BIND 9 source
tree.
2020-10-28 15:48:58 +01:00
Michal Nowak
7ef268bb4b
Drop unused bufferlist code 2020-10-22 13:11:16 +02:00
Michal Nowak
1f6f7ccad6
Drop unused portlist code 2020-10-22 13:11:16 +02:00
Michal Nowak
e67737aa75
Drop unused dbtable code 2020-10-22 13:11:16 +02:00
Michał Kępień
3e007be912 Set up release notes for BIND 9.17.7 2020-10-22 08:58:55 +02:00
Michał Kępień
2291356b08 Prepare release notes for BIND 9.17.6 2020-10-22 08:54:32 +02:00
Matthijs Mekking
621093fe69 Test migration to dnssec-policy with views
This test case is unrelated to the fix for #2171 but was added to
reproduce the problem.
2020-10-02 09:20:40 +02:00
Mark Andrews
76837484e7 Add the ability to select tests to run
task_test [-t <test_name>]
2020-10-01 08:21:42 +00:00
Michał Kępień
8bdba2edeb Drop function wrapping as it is redundant for now
As currently used in the BIND source tree, the --wrap linker option is
redundant because:

  - static builds are no longer supported,

  - there is no need to wrap around existing functions - what is
    actually required (at least for now) is to replace them altogether
    in unit tests,

  - only functions exposed by shared libraries linked into unit test
    binaries are currently being replaced.

Given the above, providing the alternative implementations of functions
to be overridden in lib/ns/tests/nstest.c is a much simpler alternative
to using the --wrap linker option.  Drop the code detecting support for
the latter from configure.ac, simplify the relevant Makefile.am, and
remove lib/ns/tests/wrap.c, updating lib/ns/tests/nstest.c accordingly
(it is harmless for unit tests which are not calling the overridden
functions).
2020-09-28 09:09:21 +02:00
Michał Kępień
a8dd69a431 Minimize stdout logging in pairwise testing jobs
The size of the log generated by each GitLab CI job is limited to 4 MB
by default.  While this limit is configurable, it makes little sense to
print build logs to standard output if they are being captured to files
anyway.  Limit use of "tee" in util/pairwise-testing.sh to printing the
combination of configure switches used for a given build.  This way the
job should never exceed the default 4 MB log size limit, yet it will
still indicate its progress in a concise way.
2020-09-22 08:40:04 +02:00
Michal Nowak
420986bf18 Add pairwise testing
Pairwise testing is a test case generation technique based on the
observation that most faults are caused by interactions of at most two
factors.  For BIND, its configure options can be thought of as such
factors.

Process BIND configure options into a model that is subsequently
processed by the PICT tool in order to find an effective test vector.
That test vector is then used for configuring and building BIND using
various combinations of configure options.
2020-09-21 11:19:19 +02:00
Michał Kępień
9040f9d63a Set up release notes for BIND 9.17.6 2020-09-16 22:41:35 +02:00
Michał Kępień
74ac8bf33a Prepare release notes for BIND 9.17.5 2020-09-16 22:34:05 +02:00
Evan Hunt
dcee985b7f update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
Evan Hunt
481a7aae44 fix a typo in copyright headers, and change "http" to "https" 2020-09-14 16:19:37 -07:00
Mark Andrews
86316ed29d Don't run dyndb and dlzexternal if running TSAN as
the dlopen flags being used are incompatible with TSAN.
2020-09-07 22:07:40 +00:00
Ondřej Surý
2c796bb9c8 Add PoC for assertion failure on large TCP DNS messages 2020-08-31 12:04:01 +02:00
Evan Hunt
dd8db89525 test whether DS chasing works correctly when forwarding 2020-08-31 11:21:22 +02:00
Ondřej Surý
a69433ba40 Add PoC system test for pk11_numbits() assertion 2020-08-31 09:18:13 +02:00
Mark Andrews
8bbf3eb5f3 check that a malformed truncated response to a TSIG query is handled 2020-08-31 08:19:13 +02:00
Ondřej Surý
01cc80376e Add dns_message_parse() fuzzer
Previously, the bin/system/wire_test.c was optionally used as a fuzzer,
this commit extracts the parts relevant to the fuzzing into a
specialized fuzzer that can be used in oss-fuzz project.

The fuzzer parses the input as UDP DNS message, then prints parsed DNS
message, then renders the DNS message and then prints the rendered DNS
message.  No part of the code should cause a assertion failure.
2020-08-25 16:40:24 +02:00
Ondřej Surý
334350a75a Update util/copyright to include doc/notes/notes-current.rst 2020-08-24 09:06:13 +02:00
Evan Hunt
d7362ff16d BIND 9.17.4
-----BEGIN PGP SIGNATURE-----
 
 iQJDBAABCgAtFiEENKwGS3ftSQfs1TU17QVz/8hFYQUFAl8xHJ0PHG1pY2hhbEBp
 c2Mub3JnAAoJEO0Fc//IRWEFcAsQAIDxJLjMt5lMV3XnakCy+4TSW03QNbnqg/+f
 VLqDzzMBbuKWYVm8GkBFtKehWHfeYGytDDKReM88M7vHzdpi9jWGi0/OIr/nZmUn
 1oK6Kx5TxoIwtW0c1nGiLfOFlBXfzFblcUviaA0aW0v824GkHEEM0gYTp6VJqL3N
 NHtkJXXVNyRRK0ER6xQtSJaizGV2Zt3qYrfo3xUJsFIt5vRUcGipHcaRAQxvmYvw
 SM2heKe4J4qONvFbNlsHRlMdQ4QKIUzFO5XB9hL8kiO1Yyt5bXKi4JRdNb1YkIbk
 pOjm3uNrXrCe8t3r1WxiCY8+9XNDxShL4VirmGKVGAZ/BktJzlyaa1LgkdA+6ggz
 UOo3/wREojYlKtuepZzgz4G5SUl7f5CIMmotAhF9qxDYOAJ/wWCxGhfcFtHUKHrk
 aqFdpQgYcqcT+z479Gov9DTu4RAX+yCSBELOJBPaEE/n4WAFP0p8zWlyFSw4i4hw
 7SFU9yhjpJgrj3HEuKlkK3v3WKFMRgOfeQgMmYNprxT/6NfQiF7PRK3Xrc12OE1m
 hY6wNf8e3VfuMmXJeAE+Ypjwl0bbeHzBCgVqDTqMAYOaW4VvsRV3d52kzWzDz3w8
 xfXWM3RGYlg1QVVo3dCNaKUL9lqVWAX0EXHinNueaiiakeB0FVNDOBtHHxpOlSkT
 izv1V//F
 =JqeM
 -----END PGP SIGNATURE-----

Merge tag 'v9_17_4' into main

BIND 9.17.4
2020-08-20 12:05:01 -07:00
Ondřej Surý
ba2376b9e0 Update and cleanup the readline library support
This commit updates and simplifies the checks for the readline support
in nslookup and nsupdate:

  * Change the autoconf checks to pkg-config only, all supported
    libraries have accompanying .pc files now.
  * Add editline support in addition to libedit and GNU readline
  * Add isc/readline.h shim header that defines dummy readline()
    function when no readline library is available
2020-08-18 10:27:14 +02:00
Michał Kępień
e0f394bbc4 Prepare release notes for BIND 9.17.4 2020-08-05 16:02:38 +02:00
Mark Andrews
88ff6b846c Check rcode is FORMERR 2020-08-04 12:20:37 +00:00
Ondřej Surý
ba99bdbf6f Add fuzzing for the isc_lex (isc_lex_gettoken,isc_lex_getmastertoken) API
In this commit, the simple fuzzing tests for the isc_lex_gettoken() and
isc_lex_getmastertoken() functions have been added.

As part of this commit, the initialization has been moved from fuzz.h
constructor/destructor to LLVMFuzzerInitialize() in each fuzz test.  The
main.c of no-fuzzing and AFL modes have been modified to run the
LLVMFuzzerInitialize() at the start of the main() function mimicking
the libfuzzer mode of operation.
2020-07-31 17:28:35 +02:00
Ondřej Surý
23b1caabae Re-enable the fuzzing tests
The fuzzing tests were temporarily disabled when the build system has been
converted to automake.  This commit restores the functionality to run the
fuzzing tests as part of the `make check`.  When the afl or libfuzzer
is enabled via ./configure, it uses a custom LOG_DRIVER (fuzz/<fuzzer.sh>).

Currently only libfuzzer.sh has been implemented that runs each fuzz
test for 5 seconds each.
2020-07-31 17:28:35 +02:00
Michal Nowak
a3b02d627f
Remove cross-test dependency on ckdnsrps.sh 2020-07-30 15:58:54 +02:00
Michal Nowak
2064e01cd0
Drop feature test for dlopen()
With libtool being mandatory from 9.17 on, so is dlopen() (via libltdl).
2020-07-21 11:22:13 +02:00
Michał Kępień
2b2e97a815 Set up release notes for BIND 9.17.4 2020-07-15 23:06:25 +02:00
Michał Kępień
aa1d6a46ab Prepare release notes for BIND 9.17.3 2020-07-15 22:51:32 +02:00
Ondřej Surý
514ab2cc4f Fixup the manpages after ddns-confgen.rst -> tsig-keygen.rst rename
There were some missing bits in the other rst files and Makefile.am(s)
that didn't reflect the rename of the main document.  Also add
ddns-confgen.8 manpage.
2020-07-08 11:05:24 +02:00
Evan Hunt
ba52377b37 use 'tsig-keygen' as the primary name for the tool
'ddns-confgen' is now an alias for 'tsig-keygen', rather than
the other way around.
2020-07-06 01:41:52 -07:00
Diego Fronza
042e509753 Added test for the fix
This test ensures that named will correctly shutdown
when receiving multiple control connections after processing
of either "rncd stop" or "kill -SIGTERM" commands.

Before the fix, named was crashing due to a race condition happening
between two threads, one running shutdown logic in named/server.c
and other handling control logic in controlconf.c.

This test tries to reproduce the above scenario by issuing multiple
queries to a target named instance, issuing either rndc stop or kill
-SIGTERM command to the same named instance, then starting multiple rndc
status connections to ensure it is not crashing anymore.
2020-07-01 11:59:01 +02:00
Michał Kępień
a4bb843075 Set up release notes for BIND 9.17.3 2020-06-18 10:10:02 +02:00