Commit Graph

33357 Commits

Author SHA1 Message Date
Ondřej Surý
549e5b693a Modify the way we benchmark mem_{get,put}
Previously, the mem_{get,put} benchmark would pass the allocation size
as thread_create argument.  This has been now changed, so the allocation
size is stored and decremented (divided) in atomic variable and the
thread create routing is given a memory context.  This will allow to
write tests where each thread is given different memory context and do
the same for mempool benchmarking.
2021-02-18 19:33:54 +01:00
Ondřej Surý
f34f943b16 Disable memory debugging features in non-developer build
The two memory debugging features: ISC_MEM_DEFAULTFILL
(ISC_MEMFLAG_FILL) and ISC_MEM_TRACKLINES were always enabled in all
builds and the former was only disabled in `named`.

This commits disables those two features in non-developer build to make
the memory allocator significantly faster.
2021-02-18 19:33:54 +01:00
Ondřej Surý
c9fe12443f Make the mempool names unconditional
The named memory pools were default and always compiled-in.  Remove the
extra complexity by removing the #define and #ifdefs around the code.
2021-02-18 19:33:54 +01:00
Ondřej Surý
b09106e93a Make the memory and mempool counters to be stdatomic types
This is yet another step into unlocking some parts of the memory
contexts.  All the regularly updated variables has been turned into
atomic types, so we can later remove the locks when updating various
counters.

Also unlock as much code as possible without breaking anything.
2021-02-18 19:33:51 +01:00
Ondřej Surý
0f44139145 Bump the maximum number of hazard pointers in tests
On 24-core machine, the tests would crash because we would run out of
the hazard pointers.  We now adjust the number of hazard pointers to be
in the <128,256> interval based on the number of available cores.

Note: This is just a band-aid and needs a proper fix.
2021-02-18 19:32:55 +01:00
Ondřej Surý
7de846977b Remove the extra level of indirection via isc_memmethods_t
Previously, the applications using libisc would be able to override the
internal memory methods with own implementation.  This was no longer
possible, but the extra level of indirection was not removed.  This
commit removes the extra level of indirection for the memory methods and
the default_memalloc() and default_memfree().
2021-02-18 19:32:55 +01:00
Ondřej Surý
55ace5d3aa Remove the internal memory allocator
The internal memory allocator had an extra code to keep a list of blocks
for small size allocation.  This would help to reduce the interactions
with the system malloc as the memory would be already allocated from the
system, but there's an extra cost associated with that - all the
allocations/deallocations must be locked, effectively eliminating any
optimizations in the system allocator targeted at multi-threaded
applications. While the isc_mem API is still using locks pretty heavily,
this is a first step into reducing the memory allocation/deallocation
contention.
2021-02-18 19:32:02 +01:00
Michal Nowak
706c57280f Merge branch 'mnowak/fix-feature-test-tool-location' into 'main'
Use FEATURETEST variable instead of a path

See merge request isc-projects/bind9!4694
2021-02-18 14:43:29 +00:00
Michal Nowak
102f012631 Use FEATURETEST variable instead of a path
feature-test tool location needs to be determined by its associated
variable; otherwise, the tool is not found on Windows:

    setup.sh: line 22: ../feature-test: No such file or directory
2021-02-18 15:41:09 +01:00
Michał Kępień
da21650949 Merge branch 'michal/add-a-checklist-for-handling-cves' into 'main'
Add a checklist for handling security issues

See merge request isc-projects/bind9!3950
2021-02-18 10:16:57 +00:00
Michał Kępień
3e5efc46d4 Add a checklist for handling security issues 2021-02-18 11:11:40 +01:00
Michał Kępień
a55f4106ef Merge branch 'v9_17_10-release' into 'main'
Merge 9.17.10 release branch

See merge request isc-projects/bind9!4699
2021-02-17 21:29:03 +00:00
Michał Kępień
ac95a9db99 Set up release notes for BIND 9.17.11 2021-02-17 22:25:26 +01:00
Michał Kępień
2b88a255d9 Update BIND version to 9.17.10 2021-02-17 22:20:24 +01:00
Michał Kępień
a02c5c350e Add a CHANGES marker 2021-02-17 22:20:24 +01:00
Michał Kępień
77026a0fc2 Merge branch 'michal/prepare-documentation-for-bind-9.17.10' into 'v9_17_10-release'
Prepare documentation for BIND 9.17.10

See merge request isc-private/bind9!237
2021-02-17 22:20:24 +01:00
Michał Kępień
48353879e5 Prepare release notes for BIND 9.17.10 2021-02-17 22:20:24 +01:00
Michał Kępień
5c15c6ab21 Add release note for GL #2073 2021-02-17 22:20:24 +01:00
Michał Kępień
fc4b7e72cc Reorder release notes 2021-02-17 22:20:24 +01:00
Michał Kępień
3799e66f04 Tweak and reword release notes 2021-02-17 22:20:24 +01:00
Michał Kępień
589cbe9bad Tweak and reword recent CHANGES entries 2021-02-17 22:20:24 +01:00
Michał Kępień
234ff52725 Use :rfc:<number> references in release notes 2021-02-17 22:20:24 +01:00
Michał Kępień
e63b385073 Document the build-time requirement for nghttp2 2021-02-17 22:20:24 +01:00
Michal Nowak
8836a6e2b5 Merge branch 'mnowak/system-test-check-for-file-not-removed' into 'main'
Check for "file not removed" in system test output

See merge request isc-projects/bind9!4680
2021-02-17 16:08:26 +00:00
Michal Nowak
f310b75250 Prevent Git to expand $systest
CentOS 8 "git status" unexpectedly expands search directory "tsig" to
also search in the "tsiggss" directory, thus incorrectly identifying
files as "not removed" in the "tsig" directory:

$ git status -su --ignored tsig
$ touch tsiggss/ns1/{named.run,named.memstats}
$ git status -su --ignored tsig
!! tsiggss/ns1/named.memstats
!! tsiggss/ns1/named.run
2021-02-17 16:35:21 +01:00
Michal Nowak
14a104d121 Clean omitted files from system tests
Any CI job:
- I:dnssec:file dnssec/ns1/trusted.keys not removed
- I:rpzrecurse:file rpzrecurse/ns3/named.run.prev not removed

system:clang:freebsd11:amd64:
- I:tkey:file tkey/ns1/named.conf-e not removed

system:gcc:sid:amd64:
- I:mirror:file mirror/ns3/_default.nzf not removed

system:gcc:xenial:amd64:
- I:rpzextra:file rpzextra/.cache/v/cache/lastfailed not removed
- I:rpzrecurse:file rpzrecurse/ns3/named.run.prev not removed
- I:shutdown:file shutdown/.cache/v/cache/lastfailed not removed
2021-02-17 16:35:21 +01:00
Michal Nowak
e48d7db13a Copy testcrypto.sh to out-of-tree directory
System tests run in out-of-tree directory fail to find testcrypto.sh and
produce:

    /bin/bash: ../testcrypto.sh: No such file or directory
2021-02-17 16:35:21 +01:00
Michal Nowak
4a2778abdf Check for "file not removed" in system test output
Run this check only when in Git repository, because the run.sh function
which produces the "file not removed" warning is run only when build
directory is the same as the source directory, that is only for in-tree
builds.
2021-02-17 16:35:21 +01:00
Michal Nowak
10bf725ee2 Add system test name to "file not removed" info 2021-02-17 16:35:21 +01:00
Michal Nowak
09acebd910 Merge branch 'mnowak/enable-dh-unit-test-to-run-under-pkcs11' into 'main'
Drop USE_OPENSSL constraint from dh_test

See merge request isc-projects/bind9!4621
2021-02-17 11:44:39 +00:00
Michal Nowak
c341e7f740 Drop USE_OPENSSL constraint from dh_test
The USE_OPENSSL constraint in dh_test does not seems to be necessary
anymore, the test runs with PKCS#11 as well.
2021-02-17 12:21:41 +01:00
Ondřej Surý
f8fa64b706 Merge branch '2487-rollback-setting-dontfrag-option' into 'main'
Rollback setting IP_DONTFRAG option on the UDP sockets

Closes #2466 and #2487

See merge request isc-projects/bind9!4668
2021-02-17 08:02:08 +00:00
Ondřej Surý
6d442e9c04 Add CHANGES and release notes for GL #2487 2021-02-17 08:10:45 +01:00
Ondřej Surý
66eefac78c Rollback setting IP_DONTFRAG option on the UDP sockets
In DNS Flag Day 2020, the development branch started setting the
IP_DONTFRAG option on the UDP sockets.  It turned out, that this
code was incomplete leading to dropping the outgoing UDP packets.
Henceforth this commit rolls back this setting until we have a
proper fix that would send back empty response with TC flag set.
2021-02-17 08:09:56 +01:00
Evan Hunt
0f1a4ff2b1 Merge branch 'each-note-cleanup' into 'main'
some release note corrections

See merge request isc-projects/bind9!4690
2021-02-17 00:59:01 +00:00
Evan Hunt
3126eb652d some release note corrections 2021-02-16 16:56:25 -08:00
Evan Hunt
62cf011eaa Merge branch '2472-tls-none' into 'main'
Resolve "too easy to configure unencrypted DoH"

Closes #2472

See merge request isc-projects/bind9!4653
2021-02-17 00:55:33 +00:00
Evan Hunt
5950b5c803 CHANGES 2021-02-16 16:24:52 -08:00
Evan Hunt
2b2e1a02bd allow configuration of "default" http endpoint
specifying "http default" in a listen-on statement sets up
the default "/dns-query" endpoint. tests and documentation
have been updated.
2021-02-16 16:24:35 -08:00
Evan Hunt
957052eea5 move listen-on correctness checks into check.c
errors in listen-on and listen-on-v6 can now be detected
by named-checkconf.
2021-02-16 16:24:35 -08:00
Evan Hunt
fd763d7223 enable listen-on parameters to be specified in any order
updated the parser to allow the "port", "tls" and "http"
paramters to "listen-on" and "listen-on-v6" to be specified in any
order. previously the parser would throw an error if any other order
was used than port, tls, http.
2021-02-16 16:24:35 -08:00
Evan Hunt
07f525bae5 require "tls none" for unencrypted HTTP listeners
unencrypted DoH connections may be used in some operational
environments where encryption is handled by a reverse proxy,
but it's going to be relatively rare, so we shouldn't make it
easy to do by mistake.  this commit changes the syntax for
listen-on and listen-on-v6 so that if "http" is specified, "tls"
must also be specified; for unencrypted listeners, "tls none"
can be used.
2021-02-16 16:24:35 -08:00
Mark Andrews
59a0637a8f Merge branch '2402-bind-9-16-11-build-fails-with-static-openssl-library' into 'main'
Resolve "BIND 9.16.11 build fails with static OpenSSL library"

Closes #2402

See merge request isc-projects/bind9!4591
2021-02-16 23:29:53 +00:00
Mark Andrews
98dc47d351 Add CHANGES for [GL #2402] 2021-02-16 22:54:03 +00:00
Mark Andrews
9223c7d599 Fix linking order for OpenSSL libraries
As libssl depends on libcrypto, -lssl needs to precede -lcrypto in
linker invocations or else the build will fail with static OpenSSL
libraries.  Adjust m4/ax_check_openssl.m4 to prevent this issue from
getting triggered when pkg-config files for OpenSSL are not available.
2021-02-16 22:54:03 +00:00
Evan Hunt
a36b0918a7 Merge branch '2484-nghttp2-version' into 'main'
report libnghttp2 version in 'named -V'

Closes #2484

See merge request isc-projects/bind9!4689
2021-02-16 22:45:52 +00:00
Evan Hunt
70da5c79cb report libnghttp2 version in 'named -V'
add lines indicating the versions of the nghttp2 library
against which named was compiled and to which it is linked.
2021-02-16 14:40:18 -08:00
Michal Nowak
1f44e6d442 Merge branch 'mnowak/consistent-use-of-SKIPPED_TEST_EXIT_CODE' into 'main'
Use SKIPPED_TEST_EXIT_CODE consistently in unit tests

See merge request isc-projects/bind9!4685
2021-02-16 13:56:18 +00:00
Michal Nowak
c286341703 Use SKIPPED_TEST_EXIT_CODE consistently
Commit fa505bfb0e omitted two unit tests
while introducing the SKIP_TEST_EXIT_CODE preprocessor macro.  Fix the
outliers to make use of SKIP_TEST_EXIT_CODE consistent across all unit
tests.  Also make sure lib/dns/tests/dnstap_test returns an exit code
that indicates a skipped test when dnstap is not enabled.
2021-02-16 13:41:50 +01:00
Ondřej Surý
2be0b5b90e Merge branch '2357-cleanup-public-headers' into 'main'
Resolve "Cannot compile current versions on macOS "Catalina""

Closes #2357

See merge request isc-projects/bind9!4670
2021-02-16 12:17:30 +00:00