]> git.ipfire.org Git - thirdparty/bind9.git/log
thirdparty/bind9.git
5 years agoMerge branch '2722-bad-sizeof-declaration-in-main' into 'main'
Ondřej Surý [Wed, 26 May 2021 08:10:45 +0000 (08:10 +0000)] 
Merge branch '2722-bad-sizeof-declaration-in-main' into 'main'

Fix the sizeof() for array holding the pointers to clientmgr

Closes #2722

See merge request isc-projects/bind9!5098

5 years agoFix the sizeof() for array holding the pointers to clientmgr
Ondřej Surý [Wed, 26 May 2021 08:01:30 +0000 (10:01 +0200)] 
Fix the sizeof() for array holding the pointers to clientmgr

The size of the array holding the pointers to clientmgr was created so
big it could hold the actual clientmgr objects, not just the pointer.
This commit fixes the size to be just the ncpus * sizeof(pointer).

5 years agoMerge branch '2721-shutdown-race-in-interfacemgr-cleanup' into 'main'
Ondřej Surý [Wed, 26 May 2021 08:00:25 +0000 (08:00 +0000)] 
Merge branch '2721-shutdown-race-in-interfacemgr-cleanup' into 'main'

Cleanup the struct isc_nmiface

Closes #2721

See merge request isc-projects/bind9!5096

5 years agoCleanup the struct isc_nmiface
Ondřej Surý [Wed, 26 May 2021 07:55:10 +0000 (09:55 +0200)] 
Cleanup the struct isc_nmiface

In previous MR, I forgot to remove the `struct isc_nmiface`, this commit
rectifies that.

5 years agoMerge branch '2721-shutdown-race-in-interfacemgr' into 'main'
Ondřej Surý [Wed, 26 May 2021 07:48:00 +0000 (07:48 +0000)] 
Merge branch '2721-shutdown-race-in-interfacemgr' into 'main'

Make a local copy of interface address when creating new socket

Closes #2721

See merge request isc-projects/bind9!5094

5 years agoRefactor the interface handling in the netmgr
Ondřej Surý [Wed, 26 May 2021 06:15:34 +0000 (08:15 +0200)] 
Refactor the interface handling in the netmgr

The isc_nmiface_t type was holding just a single isc_sockaddr_t,
so we got rid of the datatype and use plain isc_sockaddr_t in place
where isc_nmiface_t was used before.  This means less type-casting and
shorter path to access isc_sockaddr_t members.

At the same time, instead of keeping the reference to the isc_sockaddr_t
that was passed to us when we start listening, we will keep a local
copy. This prevents the data race on destruction of the ns_interface_t
objects where pending nmsockets could reference the sockaddr of already
destroyed ns_interface_t object.

5 years agoMerge branch '2685-max-ixfr-ratio-appears-to-be-forcing-axfr-very-prematurely-on...
Mark Andrews [Tue, 25 May 2021 22:46:52 +0000 (22:46 +0000)] 
Merge branch '2685-max-ixfr-ratio-appears-to-be-forcing-axfr-very-prematurely-on-bind-9-16-15' into 'main'

Resolve "max-ixfr-ratio appears to be forcing AXFR very prematurely on BIND 9.16.15"

Closes #2685

See merge request isc-projects/bind9!5011

5 years agoAdd release note for [GL #2685]
Mark Andrews [Fri, 14 May 2021 01:15:30 +0000 (11:15 +1000)] 
Add release note for [GL #2685]

5 years agoAdd CHANGES note for [GL #2685]
Mark Andrews [Tue, 11 May 2021 07:06:06 +0000 (17:06 +1000)] 
Add CHANGES note for [GL #2685]

5 years agoConsolidate xhdr fixups
Mark Andrews [Thu, 13 May 2021 05:44:02 +0000 (15:44 +1000)] 
Consolidate xhdr fixups

5 years agoCheck that IXFR delta size is correct
Mark Andrews [Wed, 12 May 2021 07:13:21 +0000 (17:13 +1000)] 
Check that IXFR delta size is correct

5 years agoCorrect size calculation in dns_journal_iter_init()
Mark Andrews [Tue, 11 May 2021 06:39:41 +0000 (16:39 +1000)] 
Correct size calculation in dns_journal_iter_init()

* dns_journal_next() leaves the read point in the journal after the
transaction header so journal_seek() should be inside the loop.
* we need to recover from transaction header inconsistencies

Additionally when correcting for <size, serial0, serial1, 0> the
correct consistency check is isc_serial_gt() rather than
isc_serial_ge().  All instances updated.

5 years agoMerge branch '2629-man-pages-aren-t-installed-when-building-9-17-x' into 'main'
Michal Nowak [Tue, 25 May 2021 09:34:11 +0000 (09:34 +0000)] 
Merge branch '2629-man-pages-aren-t-installed-when-building-9-17-x' into 'main'

Install man pages when sphinx-build tool is missing

Closes #2629

See merge request isc-projects/bind9!4945

5 years agoInstall BIND with "make DESTDIR=<PATH> install"
Michal Nowak [Tue, 13 Apr 2021 16:58:22 +0000 (18:58 +0200)] 
Install BIND with "make DESTDIR=<PATH> install"

BIND installation should be done by setting DESTDIR during "make
install" not by setting prefix via ./configure.

Make sure that installation with DESTDIR=<PATH> works by checking that
named binary and it's respective man page were installed and that
well-known BIND9 directories - and only them - are present in DESTDIR.

Also rename install path variable from BIND_INSTALL_PATH to
INSTALL_PATH to avoid namespace clash in stress tests which use
BIND_INSTALL_PATH variable to configure path to BIND9 binaries.

5 years agoInstall man pages when sphinx-build tool is missing
Michal Nowak [Tue, 13 Apr 2021 16:26:24 +0000 (18:26 +0200)] 
Install man pages when sphinx-build tool is missing

The exclusion of doc/man/ when the sphinx-build tool is missing was
excessive as some targets in doc/man/ are necessary to install man
pages.

5 years agoMerge branch 'ondrej/dont-set-mctx-name-in-resolver' into 'main'
Ondřej Surý [Tue, 25 May 2021 05:27:59 +0000 (05:27 +0000)] 
Merge branch 'ondrej/dont-set-mctx-name-in-resolver' into 'main'

Don't set memory context name in resolver.c

See merge request isc-projects/bind9!5090

5 years agoDon't set memory context name in resolver.c
Ondřej Surý [Tue, 25 May 2021 05:25:44 +0000 (07:25 +0200)] 
Don't set memory context name in resolver.c

We now attach to existing memory context instead of creating a new
memory context, so we should not set its name.

5 years agoMerge branch 'ondrej/replace-ubuntu-xenial-with-ubuntu-bionic' into 'main'
Ondřej Surý [Mon, 24 May 2021 19:43:15 +0000 (19:43 +0000)] 
Merge branch 'ondrej/replace-ubuntu-xenial-with-ubuntu-bionic' into 'main'

Replace Ubuntu 16.04 LTS with Ubuntu 18.04 LTS in the GitLab CI

See merge request isc-projects/bind9!4800

5 years agoReplace Ubuntu 16.04 LTS with Ubuntu 18.04 LTS in the GitLab CI
Ondřej Surý [Fri, 12 Mar 2021 13:02:57 +0000 (14:02 +0100)] 
Replace Ubuntu 16.04 LTS with Ubuntu 18.04 LTS in the GitLab CI

Ubuntu 16.04 (Xenial Xerus) is reaching End of Standard Support in April
2021 thus we are removing it from the list of supported platforms and
replacing it with Ubuntu 18.04 LTS (Bionic Beaver).

5 years agoMerge branch '2433-reduce-clientmgr-memory-contexts-and-tasks' into 'main'
Ondřej Surý [Mon, 24 May 2021 19:20:15 +0000 (19:20 +0000)] 
Merge branch '2433-reduce-clientmgr-memory-contexts-and-tasks' into 'main'

Reduce the number of clientmgr objects created

Closes #2433

See merge request isc-projects/bind9!5085

5 years agoAdd CHANGES and release note for GL #2433
Ondřej Surý [Mon, 24 May 2021 12:47:11 +0000 (14:47 +0200)] 
Add CHANGES and release note for GL #2433

5 years agoAdjust the fillcount and freemax for dns_message mempools
Ondřej Surý [Sun, 23 May 2021 13:36:06 +0000 (15:36 +0200)] 
Adjust the fillcount and freemax for dns_message mempools

According to the measurements (recorded on GL!5085), the fillcount of 2
for namepool and fillcount of 4 for rdspool can fit 99.99% of request
for tested scenarios.

This was discovered by perf recording the single second recursive test
using flamethrower where the initial malloc lit up like a flare.

5 years agoReduce the number of clientmgr objects created
Ondřej Surý [Sat, 22 May 2021 16:12:11 +0000 (18:12 +0200)] 
Reduce the number of clientmgr objects created

Previously, as a way of reducing the contention between threads a
clientmgr object would be created for each interface/IP address.

We tasks being more strictly bound to netmgr workers, this is no longer
needed and we can just create clientmgr object per worker queue (ncpus).

Each clientmgr object than would have a single task and single memory
context.

5 years agoDon't create per bucket memory contexts in resolver
Ondřej Surý [Tue, 11 May 2021 10:09:15 +0000 (12:09 +0200)] 
Don't create per bucket memory contexts in resolver

Similarly, the resolver code would create hundreds of memory contexts
just on the resolver setup.  The contention will be reduced directly in
the allocator, so for now just attach to the view memory instead of
creating separate memory context for each bucket.

5 years agoRun shutdown events with the task's existing threadid
Ondřej Surý [Wed, 19 May 2021 06:27:16 +0000 (08:27 +0200)] 
Run shutdown events with the task's existing threadid

Previously, task->threadid was reassigned to 0 while shutting
down, which caused an assertion.

5 years agoReduce the number of client tasks and bind them to netmgr queues
Ondřej Surý [Tue, 18 May 2021 17:44:31 +0000 (19:44 +0200)] 
Reduce the number of client tasks and bind them to netmgr queues

Since a client object is bound to a netmgr handle, each client
will always be processed by the same netmgr worker, so we can
simplify the code by binding client->task to the same thread as
the client. Since ns__client_request() now runs in the same event
loop as client->task events, is no longer necessary to pause the
task manager before launching them.

Also removed some functions in isc_task that were not used.

5 years agoReduce the number of tasks in the clientmgr
Ondřej Surý [Thu, 13 May 2021 06:40:33 +0000 (08:40 +0200)] 
Reduce the number of tasks in the clientmgr

We now use one task per CPU per dispatchmgr (that's still a lot).

5 years agoReduce the number of mctx created in clientmgr
Ondřej Surý [Tue, 11 May 2021 10:03:11 +0000 (12:03 +0200)] 
Reduce the number of mctx created in clientmgr

The number of memory contexts created in the clientmgr was enormous.  It
could easily create thousands of memory contexts because the formula was:

    nprotocols * ncpus * ninterfaces * CLIENT_NMCTXS_PERCPU (8)

The original goal was to reduce the contention when allocating the
memory, but after a while nobody noticed that the amount of memory
context allocated would not reduce contention at all.

This commit removes the whole mctxpool and just uses the mctx from
clientmgr as the contention will be reduced directly in the allocator.

5 years agoMerge branch 'mnowak/freebsd-13' into 'main'
Michal Nowak [Mon, 24 May 2021 16:15:35 +0000 (16:15 +0000)] 
Merge branch 'mnowak/freebsd-13' into 'main'

Add FreeBSD 13.0

See merge request isc-projects/bind9!4814

5 years agoRun gcc:tarball CI job for merge requests
Michal Nowak [Thu, 20 May 2021 16:00:28 +0000 (18:00 +0200)] 
Run gcc:tarball CI job for merge requests

Running gcc:tarball CI job for merge requests is consistent with how we
run gcc:out-of-tree CI job and should help identify problems with the
build system during the review process, not once merged during daily
runs. For the sake of time, unit and system tests associated with the
gcc:tarball CI job are excluded from merge requests.

5 years agoDo not spawn FreeBSD 11 CI jobs in merge requests
Michal Nowak [Thu, 20 May 2021 09:06:48 +0000 (11:06 +0200)] 
Do not spawn FreeBSD 11 CI jobs in merge requests

5 years agoCreate an anchor for schedules, tags, and web rules
Michal Nowak [Thu, 20 May 2021 08:56:12 +0000 (10:56 +0200)] 
Create an anchor for schedules, tags, and web rules

It's a common pattern to spawn CI jobs only for pipelines triggered by
schedules, tags, and web. There should be an anchor so that the rules
are not repeated.

5 years agoAdd FreeBSD 13.0
Michal Nowak [Wed, 17 Mar 2021 16:19:47 +0000 (17:19 +0100)] 
Add FreeBSD 13.0

5 years agoMerge branch '2643-fix-rndc-timeout' into 'main'
Ondřej Surý [Sat, 22 May 2021 09:46:27 +0000 (09:46 +0000)] 
Merge branch '2643-fix-rndc-timeout' into 'main'

extend rndc timeout to 60 seconds

Closes #2643

See merge request isc-projects/bind9!5082

5 years agoextend rndc timeout to 60 seconds
Evan Hunt [Sat, 22 May 2021 02:33:54 +0000 (19:33 -0700)] 
extend rndc timeout to 60 seconds

the idle timeout for rndc connections was set to 10 seconds, but this
caused intermittent system failures of the 'rndc' system test on slow
platforms, since 'rndc reconfig' could time out before reconfiguration
was complete.

this commit restores the original timeout value of 60 seconds, which was
changed inadvertently after rndc was updated to use the network manager.

even with this change, however, the test can still time out under
TSAN because loading the huge zone can take a very long time (upwards
of two minutes). so the test is modified here to generate a smaller zone
file when running under TSAN.

5 years agoMerge branch 'each-rename-copynf' into 'main'
Evan Hunt [Sat, 22 May 2021 08:10:10 +0000 (08:10 +0000)] 
Merge branch 'each-rename-copynf' into 'main'

rename dns_name_copynf() to dns_name_copy()

See merge request isc-projects/bind9!5081

5 years agoCHANGES
Evan Hunt [Sat, 22 May 2021 00:31:57 +0000 (17:31 -0700)] 
CHANGES

5 years agoupdate dev.md with name copying information
Evan Hunt [Sat, 22 May 2021 01:06:57 +0000 (18:06 -0700)] 
update dev.md with name copying information

revise the Developer Information document with updated information
about copying names.

5 years agoclean up coccinelle patches for dns_name_copy()
Evan Hunt [Sat, 22 May 2021 00:59:09 +0000 (17:59 -0700)] 
clean up coccinelle patches for dns_name_copy()

no need for semantic patches to use dns_name_copynf() any longer.

5 years agorename dns_name_copynf() to dns_name_copy()
Evan Hunt [Sat, 22 May 2021 00:20:44 +0000 (17:20 -0700)] 
rename dns_name_copynf() to dns_name_copy()

dns_name_copy() is now the standard name-copying function.

5 years agoremove dns_name_copy() implementation
Evan Hunt [Sat, 22 May 2021 00:17:23 +0000 (17:17 -0700)] 
remove dns_name_copy() implementation

Remove dns_name_copy() and refactor the underlying code since
it will only be called by dns_name_copynf() now, and can't fail.

5 years agoremove the remaining uses of dns_name_copy()
Evan Hunt [Sat, 22 May 2021 00:10:59 +0000 (17:10 -0700)] 
remove the remaining uses of dns_name_copy()

dns_name_copy() has been replaced nearly everywhere with
dns_name_copynf().  this commit changes the last two uses of
the original function.  afterward, we can remove the old
dns_name_copy() implementation, and replace it with _copynf().

5 years agoMerge branch '2713-intermittent-crashes-in-the-tkey-system-test-caused-by-broken...
Evan Hunt [Sat, 22 May 2021 04:30:19 +0000 (04:30 +0000)] 
Merge branch '2713-intermittent-crashes-in-the-tkey-system-test-caused-by-broken-dns_name_t-structures' into 'main'

Use dns_name_copy() to hold the copied name

Closes #2713

See merge request isc-projects/bind9!5079

5 years agoUse dns_name_copynf() with dns_message_gettempname() when needed
Ondřej Surý [Fri, 21 May 2021 13:30:00 +0000 (15:30 +0200)] 
Use dns_name_copynf() with dns_message_gettempname() when needed

dns_message_gettempname() returns an initialized name with a dedicated
buffer, associated with a dns_fixedname object.  Using dns_name_copynf()
to write a name into this object will actually copy the name data
from a source name. dns_name_clone() merely points target->ndata to
source->ndata, so it is faster, but it can lead to a use-after-free if
the source is freed before the target object is released via
dns_message_puttempname().

In a few places, clone was being used where copynf should have been;
this is now fixed.

As a side note, no memory was lost, because the ndata buffer used in
the dns_fixedname_t is internal to the structure, and is freed when
the dns_fixedname_t is freed regardless of the .ndata contents.

5 years agoMerge branch '2662-fix-broken-SYSTEMTEST_NO_CLEAN' into 'main'
Brian Conry [Fri, 21 May 2021 13:38:25 +0000 (13:38 +0000)] 
Merge branch '2662-fix-broken-SYSTEMTEST_NO_CLEAN' into 'main'

Preserve SYSTEMTEST_NO_CLEAN when run.sh calls make.

Closes #2662

See merge request isc-projects/bind9!5003

5 years agoPreserve additional environment variables with run.sh
Brian Conry [Wed, 19 May 2021 14:10:29 +0000 (09:10 -0500)] 
Preserve additional environment variables with run.sh

When executed in "legacy mode" (i.e. without the '-r' parameter)
run.sh invokes make with a modified environment.

SYSTEMTEST_FORCE_COLOR is now preserved for use by the individual test
scripts.

CYGWIN is now preserved for named, as it controls behavior relating to
crash reporting.

5 years agoPreserve SYSTEMTEST_NO_CLEAN when run.sh calls make
Brian Conry [Thu, 6 May 2021 18:50:44 +0000 (13:50 -0500)] 
Preserve SYSTEMTEST_NO_CLEAN when run.sh calls make

This restores legacy behavior in bin/tests/system where running:
  SYSTEMTEST_NO_CLEAN=1 ./run.sh <testname>
would run the test and preserve the output files.

This has been broken since the change that has run.sh invoke "make",
due to SYSTEMTEST_NO_CLEAN not being preserved in the environment
that's set up for "make".

Another option would be to completely remove SYSTEMTEST_NO_CLEAN.

This seems to be the only behavior-changing environment variable
not accounted for in the call to "make".

I don't think this needs a CHANGES entry.

5 years agoMerge branch 'michal/regenerate-man-pages-with-sphinx-4.0.2' into 'main'
Michał Kępień [Fri, 21 May 2021 09:26:16 +0000 (09:26 +0000)] 
Merge branch 'michal/regenerate-man-pages-with-sphinx-4.0.2' into 'main'

Regenerate man pages with Sphinx 4.0.2

See merge request isc-projects/bind9!5077

5 years agoExplicitly set "man_make_section_directory"
Michał Kępień [Fri, 21 May 2021 08:29:02 +0000 (10:29 +0200)] 
Explicitly set "man_make_section_directory"

The default value of the "man_make_section_directory" Sphinx option was
changed in Sphinx 4.0.1, which broke building man pages in maintainer
mode as the shell code in doc/man/Makefile.am expects man pages to be
built in doc/man/_build/man/, not doc/man/_build/man/<section_number>/.
The aforementioned change in defaults was reverted in Sphinx 4.0.2, but
this issue should still be prevented from reoccurring in the future.
Ensure that by explicitly setting the "man_make_section_directory"
option to False.

5 years agoRegenerate man pages with Sphinx 4.0.2
Michał Kępień [Fri, 21 May 2021 08:29:02 +0000 (10:29 +0200)] 
Regenerate man pages with Sphinx 4.0.2

The man pages produced by Sphinx 4.0.2 are slightly different than those
produced by Sphinx 3.5.4.  As Sphinx 4.0.2 is now used in GitLab CI,
update all doc/man/*in files so that they reflect what that version of
Sphinx produces, in order to prevent GitLab CI job failures.

5 years agoMerge branch '2515-improve-glue-cache-performance' into 'main'
Ondřej Surý [Thu, 20 May 2021 19:04:35 +0000 (19:04 +0000)] 
Merge branch '2515-improve-glue-cache-performance' into 'main'

use a fixedname buffer in dns_message_gettempname()

Closes #2515

See merge request isc-projects/bind9!5071

5 years agoOptimize rdataset_getownercase not to use bitshifts
Ondřej Surý [Thu, 20 May 2021 11:01:41 +0000 (13:01 +0200)] 
Optimize rdataset_getownercase not to use bitshifts

The last rdataset_getownercase() left it in a state where the code was
mix of microoptimizations (manual loop unrolling, complicated bitshifts)
with a code that would always rewrite the character even if it stayed
the same after transformation.

This commit makes sure that we modify only the characters that actually
need to change, removes the manual loop unrolling, and replaces the
weird bit arithmetics with a simple shift and bit-and.

5 years agouse a fixedname buffer in dns_message_gettempname()
Evan Hunt [Thu, 20 May 2021 00:18:22 +0000 (17:18 -0700)] 
use a fixedname buffer in dns_message_gettempname()

dns_message_gettempname() now returns a pointer to an initialized
name associated with a dns_fixedname_t object. it is no longer
necessary to allocate a buffer for temporary names associated with
the message object.

5 years agoMerge branch 'v9_17_13-release' into 'main'
Michał Kępień [Thu, 20 May 2021 10:10:37 +0000 (10:10 +0000)] 
Merge branch 'v9_17_13-release' into 'main'

Merge 9.17.13 release branch

See merge request isc-projects/bind9!5068

5 years agoSet up release notes for BIND 9.17.14
Michał Kępień [Thu, 20 May 2021 10:03:47 +0000 (12:03 +0200)] 
Set up release notes for BIND 9.17.14

5 years agoUpdate BIND version to 9.17.13
Michał Kępień [Wed, 12 May 2021 09:02:57 +0000 (11:02 +0200)] 
Update BIND version to 9.17.13

5 years agoAdd a CHANGES marker
Michał Kępień [Wed, 12 May 2021 09:02:57 +0000 (11:02 +0200)] 
Add a CHANGES marker

5 years agoMerge branch 'michal/prepare-documentation-for-bind-9.17.13' into 'v9_17_13-release'
Michał Kępień [Wed, 12 May 2021 09:02:07 +0000 (09:02 +0000)] 
Merge branch 'michal/prepare-documentation-for-bind-9.17.13' into 'v9_17_13-release'

Prepare documentation for BIND 9.17.13

See merge request isc-private/bind9!293

5 years agoPrepare release notes for BIND 9.17.13
Michał Kępień [Tue, 11 May 2021 21:28:48 +0000 (23:28 +0200)] 
Prepare release notes for BIND 9.17.13

5 years agoAdd release note for GL #2626
Michał Kępień [Tue, 11 May 2021 21:28:48 +0000 (23:28 +0200)] 
Add release note for GL #2626

5 years agoReorder release notes
Michał Kępień [Tue, 11 May 2021 21:28:48 +0000 (23:28 +0200)] 
Reorder release notes

5 years agoTweak and reword release notes
Michał Kępień [Tue, 11 May 2021 21:28:48 +0000 (23:28 +0200)] 
Tweak and reword release notes

5 years agoTweak and reword recent CHANGES entries
Michał Kępień [Tue, 11 May 2021 21:28:48 +0000 (23:28 +0200)] 
Tweak and reword recent CHANGES entries

5 years agoDrop duplicate release note for GL #2347
Michal Nowak [Thu, 6 May 2021 17:37:41 +0000 (19:37 +0200)] 
Drop duplicate release note for GL #2347

5 years agoFix typo in doc/dnssec-guide/recipes.rst
Michal Nowak [Wed, 5 May 2021 12:30:19 +0000 (14:30 +0200)] 
Fix typo in doc/dnssec-guide/recipes.rst

5 years agoMerge branch '1875-kasp-views-keyfile-race' into 'main'
Matthijs Mekking [Thu, 20 May 2021 07:55:26 +0000 (07:55 +0000)] 
Merge branch '1875-kasp-views-keyfile-race' into 'main'

Lock key files when looking for zone keys

Closes #1875

See merge request isc-projects/bind9!4919

5 years agoRelease notes and changes for [#1875]
Matthijs Mekking [Fri, 16 Apr 2021 06:39:40 +0000 (08:39 +0200)] 
Release notes and changes for [#1875]

5 years agoLock kasp when looking for zone keys
Matthijs Mekking [Mon, 19 Apr 2021 14:32:40 +0000 (16:32 +0200)] 
Lock kasp when looking for zone keys

We should also lock kasp when reading key files, because at the same
time the zone in another view may be updating the key file.

5 years agoMerge branch 'mnowak/openbsd-6.9' into 'main'
Michal Nowak [Wed, 19 May 2021 17:10:53 +0000 (17:10 +0000)] 
Merge branch 'mnowak/openbsd-6.9' into 'main'

Add OpenBSD 6.9

See merge request isc-projects/bind9!5031

5 years agoAdd OpenBSD 6.9
Michal Nowak [Mon, 17 May 2021 10:02:31 +0000 (12:02 +0200)] 
Add OpenBSD 6.9

5 years agoMerge branch '2694-drop-seq-command-from-views-tests-sh' into 'main'
Michal Nowak [Wed, 19 May 2021 13:55:53 +0000 (13:55 +0000)] 
Merge branch '2694-drop-seq-command-from-views-tests-sh' into 'main'

Replace seq command with POSIX-compliant shell code

Closes #2694

See merge request isc-projects/bind9!5061

5 years agoMake views system test ShellCheck-clean
Michal Nowak [Wed, 19 May 2021 10:38:33 +0000 (12:38 +0200)] 
Make views system test ShellCheck-clean

Also, add "set -e" to all shell scripts of the views test to exit when
any command fails or is unknown, e.g., this on OpenBSD:

    tests.sh[174]: seq: not found

5 years agoReplace seq command with POSIX-compliant shell code
Michal Nowak [Wed, 19 May 2021 10:33:16 +0000 (12:33 +0200)] 
Replace seq command with POSIX-compliant shell code

The seq command is not defined in the POSIX standard and is missing on
OpenBSD. Given that the system test code is meant to be POSIX-compliant
replace it with a shell construct.

5 years agoMerge branch '2709-placeholder' into 'main'
Michał Kępień [Wed, 19 May 2021 12:00:02 +0000 (12:00 +0000)] 
Merge branch '2709-placeholder' into 'main'

Add placeholder for GL #2709

See merge request isc-projects/bind9!5060

5 years agoAdd placeholder for GL #2709
Michał Kępień [Wed, 19 May 2021 11:57:21 +0000 (13:57 +0200)] 
Add placeholder for GL #2709

5 years agoMerge branch 'artem/doh-quota-tests' into 'main'
Artem Boldariev [Wed, 19 May 2021 08:30:17 +0000 (08:30 +0000)] 
Merge branch 'artem/doh-quota-tests' into 'main'

Add DoH quota tests

See merge request isc-projects/bind9!5024

5 years agoAdd DoH quota tests
Artem Boldariev [Fri, 14 May 2021 08:50:33 +0000 (11:50 +0300)] 
Add DoH quota tests

This commit adds unit tests which ensure that DoH code is compatible
with quota functionality.

5 years agoMerge branch '2688-cid331478-forwardnull' into 'main'
Mark Andrews [Wed, 19 May 2021 01:55:53 +0000 (01:55 +0000)] 
Merge branch '2688-cid331478-forwardnull' into 'main'

Fix possible null dereference (coverity issue 331478)

Closes #2688

See merge request isc-projects/bind9!5034

5 years agoFix coverity issue 331478
Matthijs Mekking [Mon, 17 May 2021 12:06:46 +0000 (14:06 +0200)] 
Fix coverity issue 331478

Move the "cannot start rollover" warning into code block that checks
if 'active_key' is not NULL.

5 years agoMerge branch '2550-remove-dns_zone_setflag' into 'main'
Mark Andrews [Tue, 18 May 2021 23:54:35 +0000 (23:54 +0000)] 
Merge branch '2550-remove-dns_zone_setflag' into 'main'

Resolve "Remove dns_zone_setflag"

Closes #2550

See merge request isc-projects/bind9!4762

5 years agoRemove dns_zone_setflag()
Mark Andrews [Thu, 4 Mar 2021 01:35:11 +0000 (12:35 +1100)] 
Remove dns_zone_setflag()

This function has never been used since it was added to the source tree
by commit 686b27bfd3ef906721fad485e3dae759679890b7 back in 1999.  As
the dns_zoneflg_t type is only defined in lib/dns/zone.c, no function
external to that file would be able to use dns_zone_setflag() properly
anyway - the DNS_ZONE_SETFLAG() and DNS_ZONE_CLRFLAG() macros should be
used instead. Zone options that can be set from outside zone.c are set
using dns_zone_setoption().

5 years agoMerge branch '2463-kasp-views-different-policy-same-keydirectory' into 'main'
Matthijs Mekking [Tue, 18 May 2021 14:40:26 +0000 (14:40 +0000)] 
Merge branch '2463-kasp-views-different-policy-same-keydirectory' into 'main'

Check key-directory duplicates for kasp zones

Closes #2463

See merge request isc-projects/bind9!4989

5 years agoRelease notes and changes for [GL #2463]
Matthijs Mekking [Tue, 4 May 2021 14:43:40 +0000 (16:43 +0200)] 
Release notes and changes for [GL #2463]

Mention the bugfix.

5 years agoAdd checkconf tests for [#2463]
Matthijs Mekking [Tue, 4 May 2021 14:30:17 +0000 (16:30 +0200)] 
Add checkconf tests for [#2463]

Add two tests to make sure named-checkconf catches key-directory issues
where a zone in multiple views uses the same directory but has
different dnssec-policies. One test sets the key-directory specifically,
the other inherits the default key-directory (NULL, aka the working
directory).

Also update the good.conf test to allow zones in different views
with the same key-directory if they use the same dnssec-policy.

Also allow zones in different views with different key-directories if
they use different dnssec-policies.

Also allow zones in different views with the same key-directories if
only one view uses a dnssec-policy (the other is set to "none").

Also allow zones in different views with the same key-directories if
no views uses a dnssec-policy (zone in both views has the dnssec-policy
set to "none").

5 years agoCheck key-directory duplicates for kasp zones
Matthijs Mekking [Tue, 4 May 2021 13:35:39 +0000 (15:35 +0200)] 
Check key-directory duplicates for kasp zones

Don't allow the same zone with different dnssec-policies in separate
views have the same key-directory.

Track zones plus key-directory in a symtab and if there is a match,
check the offending zone's dnssec-policy name. If the name is "none"
(there is no kasp for the offending zone), or if the name is the same
(the zone shares keys), it is fine, otherwise it is an error (zones
in views using different policies cannot share the same key-directory).

5 years agoMerge branch '2696-misleading-diagnostic-in-update_soa_serial-indicates-bind-will...
Mark Andrews [Tue, 18 May 2021 12:51:00 +0000 (12:51 +0000)] 
Merge branch '2696-misleading-diagnostic-in-update_soa_serial-indicates-bind-will-use-increment-but-it-doesn-t' into 'main'

Resolve "Misleading diagnostic in update_soa_serial indicates BIND will use increment but it doesn't"

Closes #2696

See merge request isc-projects/bind9!5029

5 years agoAdjust returned method from dns_updatemethod_date
Mark Andrews [Mon, 17 May 2021 03:32:26 +0000 (13:32 +1000)] 
Adjust returned method from dns_updatemethod_date

if dns_updatemethod_date is used do that the returned method is only
set to dns_updatemethod_increment if the new serial does not encode
the current day (YYYYMMDDXX).

5 years agoMerge branch 'michal/use-context-managers-as-suggested-by-pylint-2.8.2' into 'main'
Michał Kępień [Tue, 18 May 2021 08:56:50 +0000 (08:56 +0000)] 
Merge branch 'michal/use-context-managers-as-suggested-by-pylint-2.8.2' into 'main'

Use context managers as suggested by PyLint 2.8.2

See merge request isc-projects/bind9!5041

5 years agoUse context managers as suggested by PyLint 2.8.2
Michał Kępień [Tue, 18 May 2021 08:53:17 +0000 (10:53 +0200)] 
Use context managers as suggested by PyLint 2.8.2

PyLint 2.8.2 reports the following suggestions for two Python scripts
used in the system test suite:

    ************* Module tests_rndc_deadlock
    bin/tests/system/addzone/tests_rndc_deadlock.py:71:4: R1732: Consider using 'with' for resource-allocating operations (consider-using-with)
    ************* Module tests-shutdown
    bin/tests/system/shutdown/tests-shutdown.py:68:4: R1732: Consider using 'with' for resource-allocating operations (consider-using-with)
    bin/tests/system/shutdown/tests-shutdown.py:154:8: R1732: Consider using 'with' for resource-allocating operations (consider-using-with)

Implement the above suggestions by using
concurrent.futures.ThreadPoolExecutor() and subprocess.Popen() as
context managers.

5 years agoMerge branch '2706-worker-cond_prio-needs-to-be-initialised' into 'main'
Mark Andrews [Tue, 18 May 2021 08:39:28 +0000 (08:39 +0000)] 
Merge branch '2706-worker-cond_prio-needs-to-be-initialised' into 'main'

Resolve "worker->cond_prio needs to be initialised"

Closes #2706

See merge request isc-projects/bind9!5048

5 years agoinitialise worker->cond_prio
Mark Andrews [Tue, 18 May 2021 06:34:52 +0000 (16:34 +1000)] 
initialise worker->cond_prio

5 years agoMerge branch '2701-gcc-10-fanalyzer-reports-dereference-of-null-label-in-lib-dns...
Mark Andrews [Tue, 18 May 2021 06:41:56 +0000 (06:41 +0000)] 
Merge branch '2701-gcc-10-fanalyzer-reports-dereference-of-null-label-in-lib-dns-name-c-1167' into 'main'

Resolve "gcc-10+ -fanalyzer reports: dereference of NULL ‘label’ in lib/dns/name.c:1167"

Closes #2701

See merge request isc-projects/bind9!5046

5 years agoSilence gcc-10-fanalyzer false positive
Mark Andrews [Tue, 18 May 2021 05:51:51 +0000 (15:51 +1000)] 
Silence gcc-10-fanalyzer false positive

If 'state == ft_ordinary' then 'label' can't be NULL. Add
INSIST to reflect this.

5 years agoMerge branch '2702-gcc-10-fanalyzer-reports' into 'main'
Mark Andrews [Tue, 18 May 2021 05:45:26 +0000 (05:45 +0000)] 
Merge branch '2702-gcc-10-fanalyzer-reports' into 'main'

Resolve "gcc-10+ -fanalyzer reports:"

Closes #2702

See merge request isc-projects/bind9!5043

5 years agoSilence gcc-10-fanalyzer false positive
Mark Andrews [Tue, 18 May 2021 05:19:28 +0000 (15:19 +1000)] 
Silence gcc-10-fanalyzer false positive

Add REQUIRE(type == dns_rdatatype_nsec3 || firstp != NULL); so
that dereferences of *firstp is not flagged as a NULL pointer
dereference.

5 years agoMerge branch '2689-cid-331477-resource-leaks-resource_leak' into 'main'
Mark Andrews [Tue, 18 May 2021 00:53:38 +0000 (00:53 +0000)] 
Merge branch '2689-cid-331477-resource-leaks-resource_leak' into 'main'

Resolve "CID 331477: Resource leaks (RESOURCE_LEAK)"

Closes #2689

See merge request isc-projects/bind9!5016

5 years agoAdd CHANGES for [GL #2689]
Mark Andrews [Thu, 13 May 2021 06:50:39 +0000 (16:50 +1000)] 
Add CHANGES for [GL #2689]

5 years agoAddress potential resource leak in dst_key_fromnamedfile
Mark Andrews [Thu, 13 May 2021 06:33:49 +0000 (16:33 +1000)] 
Address potential resource leak in dst_key_fromnamedfile

5 years agoMerge branch 'each-bufsize-doc' into 'main'
Evan Hunt [Mon, 17 May 2021 17:02:18 +0000 (17:02 +0000)] 
Merge branch 'each-bufsize-doc' into 'main'

clarify buffer size options

See merge request isc-projects/bind9!5037

5 years agoclarify buffer size options
Evan Hunt [Mon, 17 May 2021 16:34:08 +0000 (09:34 -0700)] 
clarify buffer size options

the documentation for {udp,tcp}-{send,receive}-buffer options
was not complete. also revised for grammar.