]> git.ipfire.org Git - thirdparty/bind9.git/log
thirdparty/bind9.git
6 years agoAdd failure handling when iterators don't end with ISC_R_NOMORE
Ondřej Surý [Wed, 18 Dec 2019 09:54:01 +0000 (10:54 +0100)] 
Add failure handling when iterators don't end with ISC_R_NOMORE

(cherry picked from commit bff83b9480c9efe88dfde41f664a5bb7c1cad94c)

6 years agoRefactor receive_secure_db to make the variables and code flow around the iterator...
Ondřej Surý [Wed, 18 Dec 2019 09:34:29 +0000 (10:34 +0100)] 
Refactor receive_secure_db to make the variables and code flow around the iterator more local

(cherry picked from commit 6012479419273fa615a4e20e96d678a4182d2520)

6 years agoCall dns_dbiterator_destroy earlier to prevent potential deadlock.
Mark Andrews [Mon, 16 Dec 2019 07:13:05 +0000 (18:13 +1100)] 
Call dns_dbiterator_destroy earlier to prevent potential deadlock.

(cherry picked from commit 9d8f9cc8f282843d6de6a00815affa51eea9af7c)

6 years agoMerge branch '1523-pkcs11-destroy-s-usage-message-is-misleading-v9_14' into 'v9_14'
Mark Andrews [Fri, 20 Dec 2019 09:24:30 +0000 (09:24 +0000)] 
Merge branch '1523-pkcs11-destroy-s-usage-message-is-misleading-v9_14' into 'v9_14'

update usage message

See merge request isc-projects/bind9!2787

6 years agoupdate usage message
Mark Andrews [Thu, 19 Dec 2019 02:36:24 +0000 (13:36 +1100)] 
update usage message

(cherry picked from commit 41d827893e2b8529738491e4780fd76039ccf291)

6 years agoMerge branch 'feature/master/maxminddb-version-v9_14' into 'v9_14'
Mark Andrews [Wed, 18 Dec 2019 00:57:50 +0000 (00:57 +0000)] 
Merge branch 'feature/master/maxminddb-version-v9_14' into 'v9_14'

Feature/master/maxminddb version v9 14

See merge request isc-projects/bind9!2778

6 years agoadd CHANGES
Mark Andrews [Tue, 17 Dec 2019 23:57:25 +0000 (10:57 +1100)] 
add CHANGES

(cherry picked from commit 2f2bc03b2d4bdb984e21b8969e6fa6a3af48225d)

6 years agoInclude protobuf-c version
Petr Menšík [Mon, 18 Nov 2019 21:14:20 +0000 (22:14 +0100)] 
Include protobuf-c version

Include used version of protobuf-c in version info, both link time and
runtime version is available.

(cherry picked from commit 85f3476894c6fa913bfc333b243b56d832f25848)

6 years agoProvide GeoIP2 library version in version
Petr Menšík [Mon, 18 Nov 2019 20:51:36 +0000 (21:51 +0100)] 
Provide GeoIP2 library version in version

Libmaxmind does not provide any version macro for link time version.
Print at least runtime version library used, if linked.

(cherry picked from commit e6d7384c0d08dc56af6ed0c902ba2baf87f58119)

6 years agoMerge branch 'ondrej/remove-too-generic-node_count-macro-from-dns_acl-v9_14' into...
Mark Andrews [Wed, 18 Dec 2019 00:30:53 +0000 (00:30 +0000)] 
Merge branch 'ondrej/remove-too-generic-node_count-macro-from-dns_acl-v9_14' into 'v9_14'

Change the (acl)->node_count macro to dns_acl_node_count(acl) macro to clean the global namespace

See merge request isc-projects/bind9!2779

6 years agoChange the (acl)->node_count macro to dns_acl_node_count(acl) macro to clean the...
Ondřej Surý [Fri, 6 Dec 2019 14:47:39 +0000 (15:47 +0100)] 
Change the (acl)->node_count macro to dns_acl_node_count(acl) macro to clean the global namespace

(cherry picked from commit 8120088ec73c6399c921a112aca93d8c9a76f1d9)

6 years agoMerge branch '1423-threadsanitizer-data-race-time-c-170-in-isc_time_nowplusinterval...
Ondřej Surý [Thu, 12 Dec 2019 15:37:36 +0000 (15:37 +0000)] 
Merge branch '1423-threadsanitizer-data-race-time-c-170-in-isc_time_nowplusinterval-v9_14' into 'v9_14'

Ensure all zone_settimer() calls are done on locked zone

See merge request isc-projects/bind9!2769

6 years agoEnsure all zone_settimer() calls are done on locked zone
Ondřej Surý [Tue, 10 Dec 2019 09:02:09 +0000 (10:02 +0100)] 
Ensure all zone_settimer() calls are done on locked zone

(cherry picked from commit cf48e8eb326f824170f2069e5d5c33992b1783a4)

6 years agoMerge branch '1486-threadsanitizer-lock-order-inversion-potential-deadlock-dns_resolv...
Mark Andrews [Thu, 12 Dec 2019 10:05:05 +0000 (10:05 +0000)] 
Merge branch '1486-threadsanitizer-lock-order-inversion-potential-deadlock-dns_resolver_createfetch-vs-v9_14' into 'v9_14'

make resolver->zspill atomic to prevent potential deadlock

See merge request isc-projects/bind9!2765

6 years agomake resolver->zspill atomic to prevent potential deadlock
Mark Andrews [Wed, 11 Dec 2019 23:33:23 +0000 (10:33 +1100)] 
make resolver->zspill atomic to prevent potential deadlock

(cherry picked from commit 62abb6aa823037231333640567d917c5cfadc660)

6 years agoMerge branch 'prep-release-v9_14_9' into 'v9_14' v9.14.9
Evan Hunt [Thu, 12 Dec 2019 06:12:17 +0000 (06:12 +0000)] 
Merge branch 'prep-release-v9_14_9' into 'v9_14'

Prep 9.14.9

See merge request isc-projects/bind9!2762

6 years agoMerge branch 'prep-release' into v9_14
Tinderbox User [Thu, 12 Dec 2019 06:09:31 +0000 (06:09 +0000)] 
Merge branch 'prep-release' into v9_14

6 years agoprep 9.14.9
Tinderbox User [Thu, 12 Dec 2019 05:39:26 +0000 (05:39 +0000)] 
prep 9.14.9

6 years agoMerge branch 'michal/add-empty-release-notes-section-for-bind-9.14.9' into 'v9_14'
Evan Hunt [Wed, 11 Dec 2019 22:12:02 +0000 (22:12 +0000)] 
Merge branch 'michal/add-empty-release-notes-section-for-bind-9.14.9' into 'v9_14'

Add empty release notes section for BIND 9.14.9

See merge request isc-projects/bind9!2754

6 years agoAdd empty release notes section for BIND 9.14.9
Michał Kępień [Wed, 11 Dec 2019 13:16:39 +0000 (14:16 +0100)] 
Add empty release notes section for BIND 9.14.9

6 years agoMerge branch 'mnowak/fedora31-v9.14' into 'v9_14'
Michal Nowak [Wed, 11 Dec 2019 16:33:34 +0000 (16:33 +0000)] 
Merge branch 'mnowak/fedora31-v9.14' into 'v9_14'

[9.14] Update GitLab CI to Fedora 31

See merge request isc-projects/bind9!2758

6 years agoUpdate GitLab CI to Fedora 31
Michal Nowak [Wed, 11 Dec 2019 16:33:33 +0000 (16:33 +0000)] 
Update GitLab CI to Fedora 31

Since Fedora 31 is the current Fedora release, replace Fedora 30 GitLab
CI jobs with their up-to-date counterparts.

(cherry picked from commit b36f5496237f0dbb84d7541140e87d7da475cd36)

6 years agoMerge branch 'michal/create-release-tarballs-in-gitlab-ci-v9_14' into 'v9_14'
Michał Kępień [Wed, 11 Dec 2019 12:31:13 +0000 (12:31 +0000)] 
Merge branch 'michal/create-release-tarballs-in-gitlab-ci-v9_14' into 'v9_14'

[v9_14] Create release tarballs in GitLab CI

See merge request isc-projects/bind9!2752

6 years agoAdd a job creating a release tarball to GitLab CI
Michał Kępień [Wed, 11 Dec 2019 11:04:29 +0000 (12:04 +0100)] 
Add a job creating a release tarball to GitLab CI

Add a GitLab CI job (which is run only if all other jobs in a pipeline
succeed) that builds a BIND release tarball, i.e. fetches the source
tarball from the tarball building job, creates Windows zips, puts
certain parts of BIND documentation into the appropriate places, and
packs it all up into a single tarball whose contents can be subsequently
signed and published.

(cherry picked from commit 5a4a6b5e91c318c5f5bf655572de77f3a37bcdf2)

6 years agoAdd a Windows debug system test job to GitLab CI
Michał Kępień [Wed, 11 Dec 2019 11:04:29 +0000 (12:04 +0100)] 
Add a Windows debug system test job to GitLab CI

Add a system test job for binaries created by Visual Studio in the
"Debug" build configuration to GitLab CI so that they can be tested
along their "Release" counterparts when necessary.

(cherry picked from commit 2b1c8c54d1e88c0d70accb4e85e0948c04478be9)

6 years agoAdd a Windows debug build job to GitLab CI
Michał Kępień [Wed, 11 Dec 2019 11:04:29 +0000 (12:04 +0100)] 
Add a Windows debug build job to GitLab CI

Add a Visual Studio build job using the "Debug" build configuration to
GitLab CI without enabling it for every pipeline as it takes about twice
as long to complete as its "Release" counterpart.

(cherry picked from commit 12564928a76f8ff613ac061e243693d29279339d)

6 years agoCreate and test BIND source tarballs in GitLab CI
Michał Kępień [Wed, 11 Dec 2019 11:04:29 +0000 (12:04 +0100)] 
Create and test BIND source tarballs in GitLab CI

Add a set of jobs to GitLab CI that create a BIND source tarball and
then build and test its contents.  Run those extra jobs only when a tag
is pushed to the Git repository as they are only meant to be sanity
checks of BIND source tarball contents.

(cherry picked from commit 8d567490460c2ef6b00bc505793f31c06718fee2)

6 years agoInclude prepare-softhsm2.sh in source tarballs
Michał Kępień [Wed, 11 Dec 2019 11:04:29 +0000 (12:04 +0100)] 
Include prepare-softhsm2.sh in source tarballs

The util/prepare-softhsm2.sh script is useful for initializing a working
SoftHSM environment which can be used by unit tests and system tests.
However, since it is a test-specific script, it does not really belong
in the util/ subdirectory which is mostly pruned during the BIND source
tarball creation process.  Move the prepare-softhsm2.sh script to
bin/tests/ so that its location is more appropriate for its purpose and
also so that it does not get removed during the BIND source tarball
creation process, allowing it to be used for setting up test
environments for tarball-based builds.

(cherry picked from commit c0be772ebc1406b761eb870d97acd72ebebad541)

6 years agoList paths which should be excluded from tarballs
Michał Kępień [Wed, 11 Dec 2019 11:04:29 +0000 (12:04 +0100)] 
List paths which should be excluded from tarballs

Convert the logic (currently present in the form of "rm -rf" calls in
util/kit.sh) for removing files and directories which are tracked by Git
but redundant in release tarballs into a set of .gitattributes rules
which allow the same effect to be achieved using "git archive".

(cherry picked from commit 925ecb0aae7caa257c8c704364f715e463c44f47)

6 years agoMerge branch '1411-threadsanitizer-data-race-resolver-c-2153-in-fctx_query-v9_14...
Mark Andrews [Wed, 11 Dec 2019 00:35:59 +0000 (00:35 +0000)] 
Merge branch '1411-threadsanitizer-data-race-resolver-c-2153-in-fctx_query-v9_14' into 'v9_14'

Resolve "ThreadSanitizer: data race resolver.c:2153 in fctx_query"

See merge request isc-projects/bind9!2748

6 years agoNote bucket lock requirements and move REQUIRE inside locked section.
Mark Andrews [Thu, 5 Dec 2019 04:25:21 +0000 (15:25 +1100)] 
Note bucket lock requirements and move REQUIRE inside locked section.

(cherry picked from commit 13aaeaa06f79e520a0b18a431dfe449d2edf4476)

6 years agolock access to fctx->nqueries
Mark Andrews [Mon, 2 Dec 2019 05:58:57 +0000 (16:58 +1100)] 
lock access to fctx->nqueries

(cherry picked from commit 5589748ecac0b016c2221ba74249fbfbddf412b6)

6 years agoMerge branch '1441-threadsanitizer-lock-order-inversion-potential-deadlock-usr-lib...
Mark Andrews [Tue, 10 Dec 2019 13:04:22 +0000 (13:04 +0000)] 
Merge branch '1441-threadsanitizer-lock-order-inversion-potential-deadlock-usr-lib-x86_64-linux-gnu-libtsan-so-0-v9_14' into 'v9_14'

address deadlock introduced in cd2469d3cdbc211ecf8a82c76c1a0a1c4a545fec

See merge request isc-projects/bind9!2743

6 years agoaddress deadlock introduced in cd2469d3cdbc211ecf8a82c76c1a0a1c4a545fec
Mark Andrews [Tue, 10 Dec 2019 02:16:58 +0000 (13:16 +1100)] 
address deadlock introduced in cd2469d3cdbc211ecf8a82c76c1a0a1c4a545fec

(cherry picked from commit fd52417f712dedc6caec64c43969450fdd41b352)

6 years agoMerge branch '1465-fix-idna-system-test-v9_14' into 'v9_14'
Michał Kępień [Tue, 10 Dec 2019 11:28:43 +0000 (11:28 +0000)] 
Merge branch '1465-fix-idna-system-test-v9_14' into 'v9_14'

[v9_14] Fix the "idna" system test

See merge request isc-projects/bind9!2741

6 years agoOnly use LC_ALL=C where intended
Michał Kępień [Tue, 10 Dec 2019 09:31:33 +0000 (10:31 +0100)] 
Only use LC_ALL=C where intended

The LC_ALL=C assignments in the "idna" system test, which were only
meant to affect a certain subset of checks, in fact persist throughout
all the subsequent checks in that system test.  That affects the test's
behavior and is misleading.

When the "VARIABLE=value command ..." syntax is used in a shell script,
in order for the variable assignment to only apply to "command", the
latter must be an external binary; otherwise, the VARIABLE=value
assignment persists for all subsequent commands in a script:

    $ cat foo.sh
    #!/bin/sh

    foo() {
        /bin/sh bar.sh
    }

    BAR="baz0"
    BAR="baz1" /bin/sh bar.sh
    echo "foo: BAR=${BAR}"
    BAR="baz2" foo
    echo "foo: BAR=${BAR}"

    $ cat bar.sh
    #!/bin/sh

    echo "bar: BAR=${BAR}"

    $ /bin/sh foo.sh
    bar: BAR=baz1
    foo: BAR=baz0
    bar: BAR=baz2
    foo: BAR=baz2
    $

Fix by saving the value of LC_ALL before the relevant set of checks in
the "idna" system test, restoring it afterwards, and dropping the
"LC_ALL=C command ..." syntax.

(cherry picked from commit 2ee7ff23ce9c3ff6c920b68b5f25682d1e76e5e7)

6 years agoMerge branch '1457-intermittent-failure-autosign-v9_14' into 'v9_14'
Matthijs Mekking [Mon, 9 Dec 2019 15:30:27 +0000 (15:30 +0000)] 
Merge branch '1457-intermittent-failure-autosign-v9_14' into 'v9_14'

Resolve "Intermittent failure in the autosign system test"

See merge request isc-projects/bind9!2732

6 years agoBetter error handling in autosign system test
Matthijs Mekking [Mon, 9 Dec 2019 10:22:57 +0000 (11:22 +0100)] 
Better error handling in autosign system test

(cherry picked from commit bd4035900ad622c9201be6f323724760c68125cb)

6 years agoFix race in autosign test
Matthijs Mekking [Mon, 9 Dec 2019 07:26:46 +0000 (08:26 +0100)] 
Fix race in autosign test

The autosign test has a test case where a DNSSEC maintaiend zone
has a set of DNSSEC keys without any timing metadata set.  It
tests if named picks up the key for publication and signing if a
delayed dnssec-settime/loadkeys event has occured.

The test failed intermittently despite the fact it sleeps for 5
seconds but the triggered key reconfigure action should happen after
3 seconds.

However, the test output showed that the test query came in before
the key reconfigure action was complete (see excerpts below).

The loadkeys command is received:

15:38:36 received control channel command 'loadkeys delay.example.'

The reconfiguring zone keys action is triggered after 3 seconds:

15:38:39 zone delay.example/IN: reconfiguring zone keys
15:38:39 DNSKEY delay.example/NSEC3RSASHA1/7484 (ZSK) is now published
15:38:39 DNSKEY delay.example/NSEC3RSASHA1/7455 (KSK) is now published
15:38:39 writing to journal

Two seconds later the test query comes in:

15:38:41 client @0x7f1b8c0562b0 10.53.0.1#44177: query
15:38:41 client @0x7f1b8c0562b0 10.53.0.1#44177: endrequest

And 6 more seconds later the reconfigure keys action is complete:

15:38:47 zone delay.example/IN: next key event: 05-Dec-2019 15:48:39

This commit fixes the test by checking the "next key event" log has
been seen before executing the test query, making sure that the
reconfigure keys action has been complete.

This commit however does not fix, nor explain why it took such a long
time (8 seconds) to reconfigure the keys.

(cherry picked from commit 2e4273b55a27dcefa775161b1387fa25f95b678d)

6 years agoIntroduce wait_for_log in autosign test
Matthijs Mekking [Mon, 9 Dec 2019 14:52:00 +0000 (15:52 +0100)] 
Introduce wait_for_log in autosign test

6 years agoSave settime output
Matthijs Mekking [Fri, 6 Dec 2019 15:48:49 +0000 (16:48 +0100)] 
Save settime output

(cherry picked from commit 6b4a17ef7c9aa48510f246d683b96f6838bd6d57)

6 years agoMerge branch '1452-system-test-framework-cleanup-tweaks-v9_14' into 'v9_14'
Michał Kępień [Fri, 6 Dec 2019 13:48:53 +0000 (13:48 +0000)] 
Merge branch '1452-system-test-framework-cleanup-tweaks-v9_14' into 'v9_14'

[v9_14] System test framework: cleanup tweaks

See merge request isc-projects/bind9!2721

6 years agoAutomatically run clean.sh from run.sh
Michał Kępień [Fri, 6 Dec 2019 13:11:01 +0000 (14:11 +0100)] 
Automatically run clean.sh from run.sh

The first step in all existing setup.sh scripts is to call clean.sh.  To
reduce code duplication and ensure all system tests added in the future
behave consistently with existing ones, invoke clean.sh from run.sh
before calling setup.sh.

(cherry picked from commit d8905b7a9ceafedf782dca78bc454364ad52cfe9)

6 years agoRemove bin/tests/system/clean.sh
Michał Kępień [Fri, 6 Dec 2019 13:11:01 +0000 (14:11 +0100)] 
Remove bin/tests/system/clean.sh

Since the role of the bin/tests/system/clean.sh script has now been
reduced to calling a given system test's clean.sh script, remove the
former altogether and replace its only use with a direct invocation of
the latter.

(cherry picked from commit bf3eeac06731ef4bb377315b8df409e9b2ad9027)

6 years agoRemove the -r switch from system test scripts
Michał Kępień [Fri, 6 Dec 2019 13:11:01 +0000 (14:11 +0100)] 
Remove the -r switch from system test scripts

Since files containing system test output are no longer stored in test
subdirectories, bin/tests/system/clean.sh no longer needs to take care
of removing the test.output file for a given test as testsummary.sh
already takes care of that and even if a test suite terminates
abnormally and another one is started, tee invoked without the -a
command line switch overwrites the destination file if it exists, so
leftover test.output.* files from previous test suite runs are not a
concern.  Remove the -r command line switch and the code associated with
it from the relevant scripts.

(cherry picked from commit b4d37878f6ab6f0026c4a36763148be527e04a38)

6 years agoStore system test output in bin/tests/system/
Michał Kępień [Fri, 6 Dec 2019 13:11:01 +0000 (14:11 +0100)] 
Store system test output in bin/tests/system/

Some clean.sh scripts contain overly broad file deletion wildcards which
cause the test.output file (used by the system test framework for
collecting output) in a given system test's directory to be erroneously
removed immediately after the test is started (due to setup.sh scripts
calling clean.sh at the beginning).  This prevents the test's output
from being placed in bin/tests/system/systests.output at the end of a
test suite run and thus can lead to test failures being ignored.  Fix by
storing each test's output in a test.output.<test-name> file in
bin/tests/system/, which prevents clean.sh scripts from removing it (as
they should only ever affect files contained in a given system test's
directory).

(cherry picked from commit b0916bba41b2898185c91a9ddc07dea42d1bdfaa)

6 years agoMerge branch '1452-detect-missing-system-test-results-v9_14' into 'v9_14'
Michał Kępień [Fri, 6 Dec 2019 13:46:31 +0000 (13:46 +0000)] 
Merge branch '1452-detect-missing-system-test-results-v9_14' into 'v9_14'

[v9_14] Detect missing system test results

See merge request isc-projects/bind9!2720

6 years agoDetect missing system test results
Michał Kępień [Fri, 6 Dec 2019 13:11:01 +0000 (14:11 +0100)] 
Detect missing system test results

At the end of each system test suite run, the system test framework
collects all existing test.output files from system test subdirectories
and produces bin/tests/system/systests.output from those files.
However, it does not check whether a test.output file was found for
every executed test.  Thus, if the test.output file is accidentally
deleted by the system test itself (e.g. due to an overly broad file
removal wildcard present in clean.sh), its output will not be included
in bin/tests/system/systests.output.  Since the result of each system
test suite run is determined by bin/tests/system/testsummary.sh, which
only operates on the contents of bin/tests/system/systests.output, this
can lead to test failures being ignored.  Fix by ensuring the number of
test results found in bin/tests/system/systests.output is equal to the
number of tests run and triggering a system test suite failure in case
of a discrepancy between these two values.

(cherry picked from commit 3c3085be3c02e2ce20372acbae8266ad37531246)

6 years agoMerge branch '1455-job-failed-453300-v9_14' into 'v9_14'
Mark Andrews [Fri, 6 Dec 2019 00:19:40 +0000 (00:19 +0000)] 
Merge branch '1455-job-failed-453300-v9_14' into 'v9_14'

loop waiting for the redirect zone to load

See merge request isc-projects/bind9!2713

6 years agoloop waiting for the redirect zone to load
Mark Andrews [Wed, 4 Dec 2019 23:42:33 +0000 (10:42 +1100)] 
loop waiting for the redirect zone to load

(cherry picked from commit e4b1d0b68653a76ec58ff5b3c67f2c703ec63e07)

6 years agoMerge branch '1434-explicitly-set-python-to-a-empty-string-with-without-python-v9_14...
Mark Andrews [Tue, 3 Dec 2019 13:32:47 +0000 (13:32 +0000)] 
Merge branch '1434-explicitly-set-python-to-a-empty-string-with-without-python-v9_14' into 'v9_14'

Resolve "explicitly set PYTHON to a empty string with --without-python"

See merge request isc-projects/bind9!2696

6 years agoadd AC_ARG_VAR([PYTHON], [path to python executable])
Mark Andrews [Mon, 2 Dec 2019 21:38:50 +0000 (08:38 +1100)] 
add AC_ARG_VAR([PYTHON], [path to python executable])

(cherry picked from commit eed2aabc409a41dc311e4101c399e461d5f92f9f)

6 years agoadd CHANGES
Mark Andrews [Sun, 1 Dec 2019 23:25:51 +0000 (10:25 +1100)] 
add CHANGES

(cherry picked from commit 8cd3cf90b2355a9e262141392bcd6d6d1b215d60)

6 years agounset PYTHON on --without-python to prevent python still being used
Mark Andrews [Sun, 1 Dec 2019 23:17:44 +0000 (10:17 +1100)] 
unset PYTHON on --without-python to prevent python still being used

(cherry picked from commit d8fc54456996a853fac75822988fb7c0d230247c)

6 years agoMerge branch '1419-threadsanitizer-data-race-rbtdb-c-7568-in-issecure-v9_14' into...
Mark Andrews [Tue, 3 Dec 2019 12:16:00 +0000 (12:16 +0000)] 
Merge branch '1419-threadsanitizer-data-race-rbtdb-c-7568-in-issecure-v9_14' into 'v9_14'

r/w of rbtdb->current_version requires that rbtdb->lock be held

See merge request isc-projects/bind9!2692

6 years agor/w of rbtdb->current_version requires that rbtdb->lock be held
Mark Andrews [Thu, 28 Nov 2019 06:58:40 +0000 (17:58 +1100)] 
r/w of rbtdb->current_version requires that rbtdb->lock be held

(cherry picked from commit cd2469d3cdbc211ecf8a82c76c1a0a1c4a545fec)

6 years agoMerge branch '1416-threadsanitizer-data-race-resolver-c-3384-in-findname-v9_14' into...
Mark Andrews [Tue, 3 Dec 2019 06:20:50 +0000 (06:20 +0000)] 
Merge branch '1416-threadsanitizer-data-race-resolver-c-3384-in-findname-v9_14' into 'v9_14'

Assign fctx->client when fctx is created rather when the join happens.

See merge request isc-projects/bind9!2694

6 years agoAssign fctx->client when fctx is created rather when the join happens.
Mark Andrews [Thu, 28 Nov 2019 22:59:03 +0000 (09:59 +1100)] 
Assign fctx->client when fctx is created rather when the join happens.

This prevents races on fctx->client whenever a new fetch joins a existing
fetch (by calling fctx_join) as it is now invariant for the active life of
fctx.

(cherry picked from commit 9ca6ad6311f3305cfefab32187c22afe48be30be)

6 years agoMerge branch '1412-threadsanitizer-data-race-resolver-c-7030-in-fctx_decreference...
Mark Andrews [Tue, 3 Dec 2019 01:34:36 +0000 (01:34 +0000)] 
Merge branch '1412-threadsanitizer-data-race-resolver-c-7030-in-fctx_decreference-2-v9_14' into 'v9_14'

Make fctx->attributes atomic.

See merge request isc-projects/bind9!2690

6 years agoback port atomic and / or support
Mark Andrews [Tue, 3 Dec 2019 00:38:06 +0000 (11:38 +1100)] 
back port atomic and / or support

6 years agoMake fctx->attributes atomic.
Mark Andrews [Mon, 2 Dec 2019 04:11:50 +0000 (15:11 +1100)] 
Make fctx->attributes atomic.

FCTX_ATTR_SHUTTINGDOWN needs to be set and tested while holding the node
lock but the rest of the attributes don't as they are task locked. Making
fctx->attributes atomic allows both behaviours without races.

(cherry picked from commit 912ce87479f7904221c45c195ef939be7fcc2d84)

6 years agoMerge branch 'michal/address-asan-memory-leak-reports-v9_14' into 'v9_14'
Michał Kępień [Mon, 2 Dec 2019 18:24:42 +0000 (18:24 +0000)] 
Merge branch 'michal/address-asan-memory-leak-reports-v9_14' into 'v9_14'

[v9_14] Address ASAN memory leak reports

See merge request isc-projects/bind9!2683

6 years agoMove xmlInitThreads()/xmlCleanupThreads() calls
Michał Kępień [Mon, 2 Dec 2019 15:03:23 +0000 (16:03 +0100)] 
Move xmlInitThreads()/xmlCleanupThreads() calls

xmlInitThreads() and xmlCleanupThreads() are called from within
named_statschannels_configure() and named_statschannels_shutdown(),
respectively.  Both of these functions are executed by worker threads,
not the main named thread.  This causes ASAN to report memory leaks like
the following one upon shutdown (as long as named is asked to produce
any XML output over its configured statistics channels during its
lifetime):

    Direct leak of 968 byte(s) in 1 object(s) allocated from:
        #0 0x7f677c249cd8 in __interceptor_calloc /build/gcc/src/gcc/libsanitizer/asan/asan_malloc_linux.cc:153
        #1 0x7f677bc1838f in xmlGetGlobalState (/usr/lib/libxml2.so.2+0xa838f)

The data mentioned in the above report is a libxml2 state structure
stored as thread-specific data.  Such chunks of memory are automatically
released (by a destructor passed to pthread_key_create() by libxml2)
whenever a thread that allocated a given chunk exits.  However, if
xmlCleanupThreads() is called by a given thread before it exits, the
destructor will not be invoked (due to xmlCleanupThreads() calling
pthread_key_delete()) and ASAN will report a memory leak.  Thus,
xmlInitThreads() and xmlCleanupThreads() must not be called from worker
threads.  Since xmlInitThreads() must be called on Windows in order for
libxml2 to work at all, move xmlInitThreads() and xmlCleanupThreads()
calls to the main named thread (which does not produce any XML output
itself) in order to prevent the memory leak from being reported by ASAN.

(cherry picked from commit b425b5d56e7dab15484c04153fe12f740c79a3ab)

6 years agoMerge branch '1445-fix-geoip2-memory-leak-upon-reconfiguration-v9_14' into 'v9_14'
Michał Kępień [Mon, 2 Dec 2019 16:07:29 +0000 (16:07 +0000)] 
Merge branch '1445-fix-geoip2-memory-leak-upon-reconfiguration-v9_14' into 'v9_14'

[v9_14] Fix GeoIP2 memory leak upon reconfiguration

See merge request isc-projects/bind9!2681

6 years agoAdd CHANGES entry
Michał Kępień [Mon, 2 Dec 2019 14:15:06 +0000 (15:15 +0100)] 
Add CHANGES entry

5329. [bug] Reconfiguring named caused memory to be leaked when any
GeoIP2 database was in use. [GL #1445]

(cherry picked from commit 628b1837d2d6b73d75d4c7039527bf8c5bd856be)

6 years agoFix GeoIP2 memory leak upon reconfiguration
Michał Kępień [Mon, 2 Dec 2019 14:15:06 +0000 (15:15 +0100)] 
Fix GeoIP2 memory leak upon reconfiguration

Loaded GeoIP2 databases are only released when named is shut down, but
not during server reconfiguration.  This causes memory to be leaked
every time "rndc reconfig" or "rndc reload" is used, as long as any
GeoIP2 database is in use.  Fix by releasing any loaded GeoIP2 databases
before reloading them.  Do not call dns_geoip_shutdown() until server
shutdown as that function releases the memory context used for caching
GeoIP2 lookup results.

(cherry picked from commit 670afbe84a87e202fa795079d9d6d1639bcf391d)

6 years agoMerge branch '1417-threadsanitizer-data-race-rbtdb-c-1535-in-add32-v9_14' into 'v9_14'
Mark Andrews [Thu, 28 Nov 2019 21:55:22 +0000 (21:55 +0000)] 
Merge branch '1417-threadsanitizer-data-race-rbtdb-c-1535-in-add32-v9_14' into 'v9_14'

Resolve "ThreadSanitizer: data race rbtdb.c:1535 in add32"

See merge request isc-projects/bind9!2664

6 years agoadd CHANGES
Mark Andrews [Wed, 27 Nov 2019 23:28:31 +0000 (10:28 +1100)] 
add CHANGES

(cherry picked from commit 68693f8279d6651155cff0f6d54eeb8e95b14a39)

6 years agordataset_setownercase and rdataset_getownercase need to obtain a node lock
Mark Andrews [Wed, 27 Nov 2019 23:24:12 +0000 (10:24 +1100)] 
rdataset_setownercase and rdataset_getownercase need to obtain a node lock

(cherry picked from commit 637b2c4e517b466900a8c00b52f7a15727e12ae9)

6 years agoMerge branch 'mnowak/runtime-forward-port-softhsm2-setup-9_14' into 'v9_14'
Ondřej Surý [Wed, 27 Nov 2019 17:14:53 +0000 (17:14 +0000)] 
Merge branch 'mnowak/runtime-forward-port-softhsm2-setup-9_14' into 'v9_14'

[9.14] Fix the UID switch test to work with PKCS#11 build

See merge request isc-projects/bind9!2653

6 years agoFix the UID switch test to work with PKCS#11 build
Michal Nowak [Wed, 27 Nov 2019 17:14:53 +0000 (17:14 +0000)] 
Fix the UID switch test to work with PKCS#11 build

Forward port of 32fe9a0051fc76be4657fc2742e71d2be6193011 by Ondřej Surý.

(cherry picked from commit c49c41a1adb9fa8ae75fe656692d9935de1d505f)

6 years agoMerge branch '1350-threadsanitizer-data-race-rbt-c-1312-in-dns_rbt_addnode-v9_14...
Mark Andrews [Wed, 27 Nov 2019 11:49:00 +0000 (11:49 +0000)] 
Merge branch '1350-threadsanitizer-data-race-rbt-c-1312-in-dns_rbt_addnode-v9_14' into 'v9_14'

Resolve "ThreadSanitizer: data race rbt.c:1312 in dns_rbt_addnode"

See merge request isc-projects/bind9!2650

6 years agoadd comments 'tree_lock(write) must be held'
Mark Andrews [Wed, 27 Nov 2019 09:00:26 +0000 (20:00 +1100)] 
add comments 'tree_lock(write) must be held'

(cherry picked from commit 8f6aaa7230b8d40c2acadc9c05c384052522af76)

6 years agorbtnode->nsec needs to be read while holding the tree lock
Mark Andrews [Wed, 27 Nov 2019 08:09:14 +0000 (19:09 +1100)] 
rbtnode->nsec needs to be read while holding the tree lock

(cherry picked from commit 7cad3b2e91501e82e6fc3bd72043cd8098117fce)

6 years agoMerge branch '1399-recursive-limit-stat-v9_14' into 'v9_14'
Evan Hunt [Tue, 26 Nov 2019 19:43:26 +0000 (19:43 +0000)] 
Merge branch '1399-recursive-limit-stat-v9_14' into 'v9_14'

Resolve "recursive-client limit should have a stat counter"

See merge request isc-projects/bind9!2645

6 years agoadd a stats counter for clients dropped due to recursive-clients limit
Evan Hunt [Tue, 26 Nov 2019 05:28:10 +0000 (21:28 -0800)] 
add a stats counter for clients dropped due to recursive-clients limit

(cherry picked from commit 715afa9c5771ca5b483aad77fe21906685d63889)

6 years agoMerge branch '1403-when-configuration-loading-fails-named-could-assert-v9_14' into...
Ondřej Surý [Tue, 26 Nov 2019 12:54:11 +0000 (12:54 +0000)] 
Merge branch '1403-when-configuration-loading-fails-named-could-assert-v9_14' into 'v9_14'

Request exclusive access when crashing via fatal()

See merge request isc-projects/bind9!2637

6 years agoRequest exclusive access when crashing via fatal()
Ondřej Surý [Fri, 22 Nov 2019 10:39:57 +0000 (11:39 +0100)] 
Request exclusive access when crashing via fatal()

When loading the configuration fails, there might be already other tasks
running and calling OpenSSL library functions.  The OpenSSL on_exit
handler is called when exiting the main process and there's a timing
race between the on_exit function that destroys OpenSSL allocated
resources (threads, locks, ...) and other tasks accessing the very same
resources leading to a crash in the system threading library. Therefore,
the fatal() function needs to request exlusive access to the task
manager to finish the already running tasks and exit only when no other
tasks are running.

(cherry picked from commit 952d7fde63dbe68f1a2955688ea06edf9eacc9e2)

6 years agoMerge branch 'ondrej/add-retry_quiet-function-to-conf.sh.common-v9_14' into 'v9_14'
Ondřej Surý [Tue, 26 Nov 2019 08:20:37 +0000 (08:20 +0000)] 
Merge branch 'ondrej/add-retry_quiet-function-to-conf.sh.common-v9_14' into 'v9_14'

Add retry_quiet() function to retry quietly for an event to occur

See merge request isc-projects/bind9!2631

6 years agoAdd retry_quiet() function to retry quietly for an event to occur
Ondřej Surý [Wed, 20 Nov 2019 16:05:58 +0000 (00:05 +0800)] 
Add retry_quiet() function to retry quietly for an event to occur

(cherry picked from commit 31264a7e003d89581c7110cb0055e22bc69e1653)

6 years agoMerge branch '1367-threadsanitizer-data-race-dispatch-c-901-in-free_buffer-v9_14...
Mark Andrews [Tue, 26 Nov 2019 02:37:14 +0000 (02:37 +0000)] 
Merge branch '1367-threadsanitizer-data-race-dispatch-c-901-in-free_buffer-v9_14' into 'v9_14'

Resolve "ThreadSanitizer: data race dispatch.c:901 in free_buffer"

See merge request isc-projects/bind9!2627

6 years agomove maxbuffers test to allocate_udp_buffer
Mark Andrews [Mon, 25 Nov 2019 00:38:09 +0000 (11:38 +1100)] 
move maxbuffers test to allocate_udp_buffer

(cherry picked from commit 26a93d77aa17bea5e0a67623558cd3cdcf10009b)

6 years agoLock dispatch manager buffer_lock before accessing buffers;
Mark Andrews [Fri, 22 Nov 2019 01:55:03 +0000 (12:55 +1100)] 
Lock dispatch manager buffer_lock before accessing buffers;
Only test buffers for UDP dispatches.

(cherry picked from commit 011af4de71f54743e650746c9ab7db80d1636800)

6 years agolock disp->mgr before reading disp->mgr->buffers
Mark Andrews [Fri, 22 Nov 2019 00:55:47 +0000 (11:55 +1100)] 
lock disp->mgr before reading disp->mgr->buffers

(cherry picked from commit afc7389ce8fb0fd5a360cb9a48b4db874aa230e2)

6 years agoMerge branch '1397-install-isc-python-module-v9_14' into 'v9_14'
Mark Andrews [Mon, 25 Nov 2019 23:38:44 +0000 (23:38 +0000)] 
Merge branch '1397-install-isc-python-module-v9_14' into 'v9_14'

Resolve "Install ISC python module"

See merge request isc-projects/bind9!2625

6 years agoadd CHANGES and note in README.md
Mark Andrews [Mon, 25 Nov 2019 22:53:19 +0000 (09:53 +1100)] 
add CHANGES and note in README.md

(cherry picked from commit 8bbafeb5efed9077c61f67afa0b62d64232a03a2)

6 years agocheck for 'distutils.core setup'
Mark Andrews [Mon, 25 Nov 2019 07:05:22 +0000 (18:05 +1100)] 
check for 'distutils.core setup'

(cherry picked from commit 50e1bf38004bf6a60d8599e59109c2aee5e599fe)

6 years agoMerge branch 'each-notes-v9_14' into 'v9_14'
Evan Hunt [Mon, 25 Nov 2019 21:20:18 +0000 (21:20 +0000)] 
Merge branch 'each-notes-v9_14' into 'v9_14'

cleanup release notes text

See merge request isc-projects/bind9!2623

6 years agocleanup release notes text
Evan Hunt [Mon, 25 Nov 2019 21:17:35 +0000 (13:17 -0800)] 
cleanup release notes text

(cherry picked from commit fa70fc87317baa4b630b4292fcb83b29eb9e70be)

6 years agoMerge branch '1334-threadsanitizer-data-race-dispatch-c-1339-in-tcp_recv-v9_14' into...
Mark Andrews [Fri, 22 Nov 2019 21:52:58 +0000 (21:52 +0000)] 
Merge branch '1334-threadsanitizer-data-race-dispatch-c-1339-in-tcp_recv-v9_14' into 'v9_14'

lock dispatch before reporting state

See merge request isc-projects/bind9!2618

6 years agolock dispatch before reporting state
Mark Andrews [Thu, 21 Nov 2019 23:49:40 +0000 (10:49 +1100)] 
lock dispatch before reporting state

(cherry picked from commit 3075445ed6c1160d2f033ac53aecd451f77666fc)

6 years agoMerge branch '1317-alphabetise-delv-s-usage-v9_14' into 'v9_14'
Mark Andrews [Fri, 22 Nov 2019 19:56:53 +0000 (19:56 +0000)] 
Merge branch '1317-alphabetise-delv-s-usage-v9_14' into 'v9_14'

alphabetise delv's usage.

See merge request isc-projects/bind9!2615

6 years agofix release line
Mark Andrews [Fri, 22 Nov 2019 13:19:40 +0000 (00:19 +1100)] 
fix release line

6 years agoalphabetise delv's usage.
Mark Andrews [Mon, 11 Nov 2019 23:14:50 +0000 (10:14 +1100)] 
alphabetise delv's usage.

(cherry picked from commit 78685ed173e34ad47a233173c4e7d1716a37aafd)

6 years agoMerge branch 'merge-v9_14_8' into 'v9_14'
Evan Hunt [Wed, 20 Nov 2019 21:42:11 +0000 (21:42 +0000)] 
Merge branch 'merge-v9_14_8' into 'v9_14'

merge 9.14.8 to v9_14 branch

See merge request isc-projects/bind9!2605

6 years agoMerge tag 'v9_14_8' into merge-v9_14_8
Evan Hunt [Wed, 20 Nov 2019 21:39:46 +0000 (13:39 -0800)] 
Merge tag 'v9_14_8' into merge-v9_14_8

6 years agoMerge branch 'mnowak/537_Add_CI_step_to_test_named_-u-v9_14' into 'v9_14'
Michal Nowak [Wed, 20 Nov 2019 11:01:05 +0000 (11:01 +0000)] 
Merge branch 'mnowak/537_Add_CI_step_to_test_named_-u-v9_14' into 'v9_14'

[9.14] Verifying that named switches UID

See merge request isc-projects/bind9!2599

6 years agoVerifying that named switches UID
Michal Nowak [Wed, 20 Nov 2019 11:01:05 +0000 (11:01 +0000)] 
Verifying that named switches UID

This test runs only under root, which is required for the user-switch
`-u` option to work.

Closes #537.

(cherry picked from commit b00360537eae440f03ee47e9779ceeecd491dba7)

6 years agoMerge branch '1341-threadsanitizer-data-race-rbtdb-c-5756-in-add32-v9_14' into 'v9_14'
Ondřej Surý [Tue, 19 Nov 2019 17:30:39 +0000 (17:30 +0000)] 
Merge branch '1341-threadsanitizer-data-race-rbtdb-c-5756-in-add32-v9_14' into 'v9_14'

Resolve "ThreadSanitizer: data race rbtdb.c:5756 in add32"

See merge request isc-projects/bind9!2593

6 years agoadd CHANGES
Mark Andrews [Tue, 19 Nov 2019 08:28:17 +0000 (19:28 +1100)] 
add CHANGES

(cherry picked from commit 4534fb5ec12ade8ef6d4e7d99455361795685d73)