]> git.ipfire.org Git - thirdparty/bind9.git/log
thirdparty/bind9.git
6 years agoAdd respdiff job
Michal Nowak [Thu, 6 Feb 2020 14:53:36 +0000 (15:53 +0100)] 
Add respdiff job

This job leverages respdiff test from the private bind-qa repo.

(cherry picked from commit 04f8b65a8f280b35ba7a466f5eedc99798d9eafb)

6 years agoMerge branch 'mnowak/pkcs11-test-fix-v9_11' into 'v9_11'
Michal Nowak [Thu, 5 Mar 2020 07:37:52 +0000 (07:37 +0000)] 
Merge branch 'mnowak/pkcs11-test-fix-v9_11' into 'v9_11'

[v9_11] Fix "pkcs11" system test

See merge request isc-projects/bind9!3161

6 years agoFix "pkcs11" system test
Michal Nowak [Mon, 24 Feb 2020 15:37:25 +0000 (15:37 +0000)] 
Fix "pkcs11" system test

  - Define the SLOT environment variable before starting the test.  This
    variable defaults to 0 and that does not work with SoftHSM 2.

  - The system test expects the PIN environment variable to be set to
    "1234" while bin/tests/prepare-softhsm2.sh sets it to "0000".
    Update bin/tests/prepare-softhsm2.sh so that it sets the PIN to
    "1234".

  - Move contents of bin/tests/system/pkcs11/prereq.sh to
    bin/tests/system/pkcs11/setup.sh as the former was creating a file
    called "supported" that was getting removed by the latter before
    bin/tests/system/pkcs11/tests.sh could access it.

  - Fix typo in "have_ecx".

(cherry picked from commit 100a230e80f01a777b917b135b4bae9a4ac0e8ae)

6 years agoMerge branch 'michal/fix-cppcheck-warnings' into 'v9_11'
Michał Kępień [Wed, 4 Mar 2020 11:42:43 +0000 (11:42 +0000)] 
Merge branch 'michal/fix-cppcheck-warnings' into 'v9_11'

Fix cppcheck warnings for 9.11

See merge request isc-projects/bind9!3143

6 years agoFix cppcheck 1.90 warnings
Michał Kępień [Wed, 4 Mar 2020 11:41:01 +0000 (12:41 +0100)] 
Fix cppcheck 1.90 warnings

cppcheck 1.90 reports the following false positives for
lib/dns/tests/rbt_serialize_test.c:

    lib/dns/tests/rbt_serialize_test.c:412:12: warning: Either the condition 'base!=NULL' is redundant or there is pointer arithmetic with NULL pointer. [nullPointerArithmeticRedundantCheck]
      p = base + (r % filesize);
               ^
    lib/dns/tests/rbt_serialize_test.c:407:20: note: Assuming that condition 'base!=NULL' is not redundant
      assert_true(base != NULL && base != MAP_FAILED);
                       ^
    lib/dns/tests/rbt_serialize_test.c:405:14: note: Assignment 'base=mmap(NULL,filesize,PROT_READ|PROT_WRITE,0|MAP_PRIVATE,fd,0)', assigned value is 0
      base = mmap(NULL, filesize, PROT_READ|PROT_WRITE,
                 ^
    lib/dns/tests/rbt_serialize_test.c:412:12: note: Null pointer addition
      p = base + (r % filesize);
               ^
    lib/dns/tests/rbt_serialize_test.c:413:12: warning: Either the condition 'base!=NULL' is redundant or there is pointer arithmetic with NULL pointer. [nullPointerArithmeticRedundantCheck]
      q = base + filesize;
               ^
    lib/dns/tests/rbt_serialize_test.c:407:20: note: Assuming that condition 'base!=NULL' is not redundant
      assert_true(base != NULL && base != MAP_FAILED);
                       ^
    lib/dns/tests/rbt_serialize_test.c:405:14: note: Assignment 'base=mmap(NULL,filesize,PROT_READ|PROT_WRITE,0|MAP_PRIVATE,fd,0)', assigned value is 0
      base = mmap(NULL, filesize, PROT_READ|PROT_WRITE,
                 ^
    lib/dns/tests/rbt_serialize_test.c:413:12: note: Null pointer addition
      q = base + filesize;
               ^

This is caused by cppcheck not understanding how cmocka's assert_true()
macro works.  The problem being reported is a false positive: if mmap()
fails, the lines flagged by cppcheck will never be reached.  Address the
problem by suppressing nullPointerArithmeticRedundantCheck warnings for
the affected lines.

6 years agoFix cppcheck 1.90 warning
Michał Kępień [Wed, 4 Mar 2020 11:41:01 +0000 (12:41 +0100)] 
Fix cppcheck 1.90 warning

cppcheck 1.90 reports the following issue for bin/named/query.c:

    bin/named/query.c:6838:2: warning: %d in format string (no. 3) requires 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint]
     snprintf(mbuf, sizeof(mbuf) - 1,
     ^

Tweak the format specifier for client->query.restarts to address the
problem.

6 years agoFix cppcheck 1.90 warnings
Michał Kępień [Wed, 4 Mar 2020 11:41:01 +0000 (12:41 +0100)] 
Fix cppcheck 1.90 warnings

cppcheck 1.90 reports some false positives for lib/dns/client.c:

    lib/dns/client.c:1431:2: warning: Either the condition 'rctx==((void*)0)' is redundant or there is possible null pointer dereference: rctx. [nullPointerRedundantCheck]
     rctx->rdataset = rdataset;
     ^
    lib/dns/client.c:1416:11: note: Assuming that condition 'rctx==((void*)0)' is not redundant
     if (rctx == NULL)
              ^
    lib/dns/client.c:1415:9: note: Assignment 'rctx=isc__mem_get(mctx,sizeof(*rctx),"lib/dns/client.c",1415)', assigned value is 0
     rctx = isc_mem_get(mctx, sizeof(*rctx));
            ^
    lib/dns/client.c:1431:2: note: Null pointer dereference
     rctx->rdataset = rdataset;
     ^
    lib/dns/client.c:1438:2: warning: Either the condition 'rctx==((void*)0)' is redundant or there is possible null pointer dereference: rctx. [nullPointerRedundantCheck]
     rctx->sigrdataset = sigrdataset;
     ^
    lib/dns/client.c:1416:11: note: Assuming that condition 'rctx==((void*)0)' is not redundant
     if (rctx == NULL)
              ^
    lib/dns/client.c:1415:9: note: Assignment 'rctx=isc__mem_get(mctx,sizeof(*rctx),"lib/dns/client.c",1415)', assigned value is 0
     rctx = isc_mem_get(mctx, sizeof(*rctx));
            ^
    lib/dns/client.c:1438:2: note: Null pointer dereference
     rctx->sigrdataset = sigrdataset;
     ^
    lib/dns/client.c:1445:2: warning: Either the condition 'rctx==((void*)0)' is redundant or there is possible null pointer dereference: rctx. [nullPointerRedundantCheck]
     rctx->client = client;
     ^
    lib/dns/client.c:1416:11: note: Assuming that condition 'rctx==((void*)0)' is not redundant
     if (rctx == NULL)
              ^
    lib/dns/client.c:1415:9: note: Assignment 'rctx=isc__mem_get(mctx,sizeof(*rctx),"lib/dns/client.c",1415)', assigned value is 0
     rctx = isc_mem_get(mctx, sizeof(*rctx));
            ^
    lib/dns/client.c:1445:2: note: Null pointer dereference
     rctx->client = client;
     ^
    lib/dns/client.c:1827:2: warning: Either the condition 'ctx==((void*)0)' is redundant or there is possible null pointer dereference: ctx. [nullPointerRedundantCheck]
     ctx->client = client;
     ^
    lib/dns/client.c:1815:10: note: Assuming that condition 'ctx==((void*)0)' is not redundant
     if (ctx == NULL)
             ^
    lib/dns/client.c:1814:8: note: Assignment 'ctx=isc__mem_get(client->mctx,sizeof(*ctx),"lib/dns/client.c",1814)', assigned value is 0
     ctx = isc_mem_get(client->mctx, sizeof(*ctx));
           ^
    lib/dns/client.c:1827:2: note: Null pointer dereference
     ctx->client = client;
     ^

All of them are caused by cppcheck not recognizing the relationship
between isc_mem_get() returning NULL and the result variable being set
to ISC_R_NOMEMORY (with a subsequent jump to a cleanup section).

Move "goto cleanup;" statements into error handling branches to prevent
cppcheck from generating these warnings.

6 years agoFix cppcheck 1.89 warnings
Michał Kępień [Wed, 16 Oct 2019 20:06:00 +0000 (22:06 +0200)] 
Fix cppcheck 1.89 warnings

cppcheck 1.89 enabled certain value flow analysis mechanisms [1] which
trigger null pointer dereference false positives that were previously
not reported.  It seems that cppcheck no longer treats at least some
REQUIRE() assertion failures as fatal, so add extra assertion macro
definitions to lib/isc/include/isc/util.h that are only used when the
CPPCHECK preprocessor macro is defined; these definitions make cppcheck
1.89 behave as expected.

There is an important requirement for these custom definitions to work:
cppcheck must properly treat abort() as a function which does not
return.  In order for that to happen, the __GNUC__ macro must be set to
a high enough number (because system include directories are used and
system headers compile attributes away if __GNUC__ is not high enough).
__GNUC__ is thus set to the major version number of the GCC compiler
used, which is what that latter does itself during compilation.

[1] https://github.com/danmar/cppcheck/commit/aaeec462e6d96bb70c2b1cf030979d09e2d7c959

(cherry picked from commit abfde3d543576311ce5d32089d774a360b7edc9f)

6 years agoMerge branch '1656-masterformat-system-test-failed-missing-sleep-1-v9_11' into 'v9_11'
Mark Andrews [Wed, 4 Mar 2020 07:41:32 +0000 (07:41 +0000)] 
Merge branch '1656-masterformat-system-test-failed-missing-sleep-1-v9_11' into 'v9_11'

properly wait for zone to be loaded

See merge request isc-projects/bind9!3154

6 years agoproperly wait for zone to be loaded
Mark Andrews [Wed, 4 Mar 2020 04:39:08 +0000 (15:39 +1100)] 
properly wait for zone to be loaded

(cherry picked from commit 0abcface49789c5fdc28fec062cdf692c43a3e7a)

6 years agoMerge branch 'marka-check-touched-v9_11' into 'v9_11'
Mark Andrews [Tue, 3 Mar 2020 22:41:06 +0000 (22:41 +0000)] 
Merge branch 'marka-check-touched-v9_11' into 'v9_11'

Marka check touched v9 11

See merge request isc-projects/bind9!3149

6 years agoAdd CHANGES entry
Mark Andrews [Tue, 3 Mar 2020 01:31:55 +0000 (12:31 +1100)] 
Add CHANGES entry

(cherry picked from commit 64474db14e715e4b1a545406acf9fb5be8200f50)

6 years agoRestart zone maintenance if it had been stalled.
Mark Andrews [Mon, 2 Mar 2020 23:50:06 +0000 (10:50 +1100)] 
Restart zone maintenance if it had been stalled.

(cherry picked from commit f171347b5f27c1b0dfe1ef935512b20a820901c9)

6 years agoCheck inline master zones that are touched reload correctly.
Mark Andrews [Mon, 2 Mar 2020 08:38:29 +0000 (19:38 +1100)] 
Check inline master zones that are touched reload correctly.

(cherry picked from commit 50e079d6c3eea1a16b94bdb10d9e19939147bc30)

6 years agoMerge branch '1627-call-set_resigntime-and-zone_settimer-v9_11' into 'v9_11'
Mark Andrews [Tue, 3 Mar 2020 05:56:15 +0000 (05:56 +0000)] 
Merge branch '1627-call-set_resigntime-and-zone_settimer-v9_11' into 'v9_11'

Resolve "inline re-signing stops"

See merge request isc-projects/bind9!3139

6 years agoadd release note entry
Mark Andrews [Tue, 3 Mar 2020 04:37:42 +0000 (15:37 +1100)] 
add release note entry

(cherry picked from commit 23ce0f32e5a770c16a76d19e2a1c9e1322433d69)

6 years agoAdd CHANGES note
Mark Andrews [Tue, 3 Mar 2020 04:30:52 +0000 (15:30 +1100)] 
Add CHANGES note

(cherry picked from commit 905549f061dab784c533287db087d3705cfe0a1d)

6 years agoAdjust lock/unlock in zone_rekey()
Ondřej Surý [Thu, 27 Feb 2020 07:45:10 +0000 (08:45 +0100)] 
Adjust lock/unlock in zone_rekey()

(cherry picked from commit aaaa7e67fa2b0ec618ec4be1af175fd6d73b76a0)

6 years agoEnsure that resigintime and the zone timer are set
Mark Andrews [Fri, 28 Feb 2020 03:01:40 +0000 (14:01 +1100)] 
Ensure that resigintime and the zone timer are set

(cherry picked from commit a6626594aa348209eb02ec1ba8d3539821144aca)

6 years agoAdd more zone locks
Matthijs Mekking [Thu, 27 Feb 2020 10:59:12 +0000 (11:59 +0100)] 
Add more zone locks

Add more zone locks around code that touches zone timer setting
in failure modes.

(cherry picked from commit 143d1c9767e25d35dd939f43f6bae462ee9db477)

6 years agoAlways call set_resigntime with the zone lock held
Mark Andrews [Thu, 27 Feb 2020 06:48:05 +0000 (17:48 +1100)] 
Always call set_resigntime with the zone lock held

(cherry picked from commit 7212961849510f97146f815fa03f1e90de9d3201)

6 years agoAlways call zone_settimer()
Mark Andrews [Thu, 27 Feb 2020 06:43:26 +0000 (17:43 +1100)] 
Always call zone_settimer()

zone_needdump() could potentially not call zone_settimer() so
explitly call zone_settimer() as zone->resigntime could have
gone backward.

(cherry picked from commit 5ec57f31b0cca77f2629bac888c323cd619979ee)

6 years agoCall set_resigntime() in receive_secure_serial()
Mark Andrews [Thu, 27 Feb 2020 06:35:18 +0000 (17:35 +1100)] 
Call set_resigntime() in receive_secure_serial()

With RRSIG records no longer being signed with the full
sig-validity-interval we need to ensure the zone->resigntime
as it may need to be set to a earlier time.

(cherry picked from commit 5d1611afdc61ea8f19ceecc3e88cdb2296ec3914)

6 years agoMerge branch 'ondrej/use-pkg-config-for-libxml2-v9_11' into 'v9_11'
Ondřej Surý [Mon, 2 Mar 2020 14:33:49 +0000 (14:33 +0000)] 
Merge branch 'ondrej/use-pkg-config-for-libxml2-v9_11' into 'v9_11'

use pkg-config for libxml2 (v9.11)

See merge request isc-projects/bind9!3118

6 years agoAdd release notes for pkg-config requirement for libxml2
Ondřej Surý [Mon, 2 Mar 2020 10:15:30 +0000 (11:15 +0100)] 
Add release notes for pkg-config requirement for libxml2

6 years agoUse pkg-config for --with-libxml2=auto/yes
Ondřej Surý [Tue, 25 Feb 2020 14:22:54 +0000 (15:22 +0100)] 
Use pkg-config for --with-libxml2=auto/yes

The downstream distributors of BIND 9 (Debian in this case) are in
process of removing xml2-config command from the libxml2-dev package
(see Debian Bug #949056 for details).  The removal of the script will
make BIND 9 to fail to build from the source when --with-libxml2=yes is
specified or not link with libxml2 when --with-libxml2=auto is specified
and then fail ABI changes (Debian Bug #949056).

When --with-libxml2=<path>, the script checks for <path>/bin/xml2-config
and uses the specified path to link with libxml2. This has been kept to
retain backwards compatibility with systems that does not ship
pkg-config.

6 years agoMerge branch '414-use-p11-kit-headers-v9_11' into 'v9_11'
Ondřej Surý [Mon, 2 Mar 2020 10:29:36 +0000 (10:29 +0000)] 
Merge branch '414-use-p11-kit-headers-v9_11' into 'v9_11'

Resolve "Legal issue with pkcs11 headers"

See merge request isc-projects/bind9!3133

6 years agoUse standard PKCS#11 standard error codes instead of custom error codes
Ondřej Surý [Thu, 8 Aug 2019 13:52:47 +0000 (15:52 +0200)] 
Use standard PKCS#11 standard error codes instead of custom error codes

* CKR_CRYPTOKI_ALREADY_INITIALIZED: This value can only be returned by
  `C_Initialize`. It means that the Cryptoki library has already been
  initialized (by a previous call to `C_Initialize` which did not have a
  matching `C_Finalize` call).

* CKR_FUNCTION_NOT_SUPPORTED: The requested function is not supported by this
  Cryptoki library. Even unsupported functions in the Cryptoki API should have a
  "stub" in the library; this stub should simply return the value
  CKR_FUNCTION_NOT_SUPPORTED.

* CKR_LIBRARY_LOAD_FAILED: The Cryptoki library could not load a dependent
  shared library.

(cherry picked from commit f6922d6e7866f65bed5623ff90e14a7398337b21)

6 years agoReplace the OASIS PKCS#11 header file with one from p11-kit
Ondřej Surý [Wed, 29 May 2019 09:07:46 +0000 (11:07 +0200)] 
Replace the OASIS PKCS#11 header file with one from p11-kit

The OASIS pkcs11.h header has a restrictive license.  Replace the
pkcs11.h pkcs11f.h and pkcs11t.h headers with pkcs11.h from p11-kit.

For source distribution, the license for the OASIS headers itself
doesn't pose any licensing problem when combined with MPL license, but
it possibly creates problem for downstream distributors of BIND 9.

(cherry picked from commit c47fad24315f507ae3c671813c2e34e9e5e7e155)

6 years agoMerge branch '1638-rrsig-soa-and-re-signing-v9_11' into 'v9_11'
Mark Andrews [Thu, 27 Feb 2020 23:31:02 +0000 (23:31 +0000)] 
Merge branch '1638-rrsig-soa-and-re-signing-v9_11' into 'v9_11'

Resolve "RRSIG(SOA) and re-signing."

See merge request isc-projects/bind9!3129

6 years agocapture named-journalprint output
Mark Andrews [Tue, 25 Feb 2020 01:17:11 +0000 (12:17 +1100)] 
capture named-journalprint output

(cherry picked from commit 88c828cb9ff876319f01ce37d26ad4a052201ec5)

6 years agosort RRSIG(SOA) to be last of RRSIGs with a common re-resign time
Mark Andrews [Tue, 25 Feb 2020 01:11:27 +0000 (12:11 +1100)] 
sort RRSIG(SOA) to be last of RRSIGs with a common re-resign time

(cherry picked from commit a24fd55836775a717efaedd3c0e080a991dc6b73)

6 years agouse the full sig-validity-interval for RRSIG(SOA)
Mark Andrews [Tue, 25 Feb 2020 01:09:13 +0000 (12:09 +1100)] 
use the full sig-validity-interval for RRSIG(SOA)

(cherry picked from commit 660dc3eba75b2d0ba21e5a697387acb615293140)

6 years agoMerge branch '1632-spelling-v9_11-take2' into 'v9_11'
Evan Hunt [Tue, 25 Feb 2020 06:27:50 +0000 (06:27 +0000)] 
Merge branch '1632-spelling-v9_11-take2' into 'v9_11'

fix additional spelling errors

See merge request isc-projects/bind9!3115

6 years agofix additional spelling errors
Evan Hunt [Tue, 25 Feb 2020 05:59:02 +0000 (21:59 -0800)] 
fix additional spelling errors

6 years agoMerge branch '1632-spelling-v9_11' into 'v9_11'
Evan Hunt [Fri, 21 Feb 2020 23:02:26 +0000 (23:02 +0000)] 
Merge branch '1632-spelling-v9_11' into 'v9_11'

fix spelling errors reported by Fossies.

See merge request isc-projects/bind9!3112

6 years agofix spelling errors reported by Fossies.
Evan Hunt [Fri, 21 Feb 2020 22:07:57 +0000 (14:07 -0800)] 
fix spelling errors reported by Fossies.

6 years agoMerge branch 'marka-fix-signature-test-v9_11' into 'v9_11'
Mark Andrews [Fri, 21 Feb 2020 07:20:38 +0000 (07:20 +0000)] 
Merge branch 'marka-fix-signature-test-v9_11' into 'v9_11'

Fix code to generate the test signatues.

See merge request isc-projects/bind9!3106

6 years agofixup! Fix code to generate the test signatues.
Mark Andrews [Fri, 21 Feb 2020 07:10:44 +0000 (18:10 +1100)] 
fixup! Fix code to generate the test signatues.

6 years agoFix code to generate the test signatues.
Mark Andrews [Fri, 21 Feb 2020 05:40:50 +0000 (21:40 -0800)] 
Fix code to generate the test signatues.

* ctx needs to be destroyed before it is regenerated.
* emit the name of the signature to be replaced.
* cleanup memory before asserting so post longjump doesn't detect a
  memory leak.
* comment code.

(cherry picked from commit 3a8c8a2a3199844bb16232e2f362f67d14181939)

6 years agoMerge branch 'michal/make-a-sed-script-in-doc-arm-makefile.in-portable-v9_11' into...
Michał Kępień [Thu, 20 Feb 2020 11:28:32 +0000 (11:28 +0000)] 
Merge branch 'michal/make-a-sed-script-in-doc-arm-makefile.in-portable-v9_11' into 'v9_11'

[v9_11] Make a sed script in doc/arm/Makefile.in portable

See merge request isc-projects/bind9!3099

6 years agoMake a sed script in doc/arm/Makefile.in portable
Michał Kępień [Thu, 20 Feb 2020 11:23:36 +0000 (12:23 +0100)] 
Make a sed script in doc/arm/Makefile.in portable

BSD sed does not recognize \s as a whitespace matching token.  Make the
sed script in doc/arm/Makefile.in which ensures GitLab identifiers are
not split across lines portable by replacing \s with [[:space:]].

(cherry picked from commit b25e6b51f6e16c983ab7c0f5cd8187bdd197b8d3)

6 years agoMerge branch 'michal/increase-lifetime-of-docs-sid-amd64-artifacts-v9_11' into 'v9_11'
Michał Kępień [Thu, 20 Feb 2020 10:57:38 +0000 (10:57 +0000)] 
Merge branch 'michal/increase-lifetime-of-docs-sid-amd64-artifacts-v9_11' into 'v9_11'

[v9_11] Increase lifetime of docs:sid:amd64 artifacts

See merge request isc-projects/bind9!3094

6 years agoIncrease lifetime of docs:sid:amd64 artifacts
Michał Kępień [Thu, 20 Feb 2020 10:51:58 +0000 (11:51 +0100)] 
Increase lifetime of docs:sid:amd64 artifacts

Artifacts generated by the docs:sid:amd64 job need to be retained longer
than for other jobs as they are used for building bind.isc.org contents.
If these artifacts are removed too quickly, pipelines in the pages/bind
GitLab project start failing, preventing content updates from being
published.  Increase lifetime of the relevant job artifacts to prevent
this from happening.

(cherry picked from commit 9751ba5a7568a550e62096661515ebc1c2efe3a4)

6 years agoMerge branch 'prep-release' into v9_11 v9.11.16
Tinderbox User [Wed, 12 Feb 2020 15:42:40 +0000 (15:42 +0000)] 
Merge branch 'prep-release' into v9_11

6 years agoprep 9.11.16
Tinderbox User [Wed, 12 Feb 2020 14:42:14 +0000 (14:42 +0000)] 
prep 9.11.16

6 years agoMerge branch 'mnowak/coverity-disable-web-tag-v9_11' into 'v9_11'
Michal Nowak [Wed, 12 Feb 2020 15:00:33 +0000 (15:00 +0000)] 
Merge branch 'mnowak/coverity-disable-web-tag-v9_11' into 'v9_11'

[v9_11] Run Coverity Scan only when specific variables are present

See merge request isc-projects/bind9!3056

6 years agoRun Coverity Scan only when specific variables are present
Michal Nowak [Wed, 12 Feb 2020 15:00:32 +0000 (15:00 +0000)] 
Run Coverity Scan only when specific variables are present

Submissions to Coverity Scan should be limited to those originated from
release branches and only from a specific schedule which holds
COVERITY_SCAN_PROJECT_NAME and COVERITY_SCAN_TOKEN variables.

(cherry picked from commit 48530aa21395414b0f9788ea5ab158b2b09ab977)

6 years agoMerge branch 'michal/prepare-release-notes-for-bind-9.11.16' into 'v9_11'
Michał Kępień [Wed, 12 Feb 2020 13:18:59 +0000 (13:18 +0000)] 
Merge branch 'michal/prepare-release-notes-for-bind-9.11.16' into 'v9_11'

Prepare release notes for BIND 9.11.16

See merge request isc-projects/bind9!3052

6 years agoAdd release notes section for BIND 9.11.16
Michał Kępień [Wed, 12 Feb 2020 12:58:01 +0000 (13:58 +0100)] 
Add release notes section for BIND 9.11.16

6 years agoMerge branch 'michal/minor-README-tweaks-v9_11' into 'v9_11'
Michał Kępień [Wed, 12 Feb 2020 10:39:09 +0000 (10:39 +0000)] 
Merge branch 'michal/minor-README-tweaks-v9_11' into 'v9_11'

[v9_11] Minor README tweaks

See merge request isc-projects/bind9!3049

6 years agoMinor CHANGES tweak
Michał Kępień [Wed, 12 Feb 2020 10:23:48 +0000 (11:23 +0100)] 
Minor CHANGES tweak

(cherry picked from commit a0349b18e0049de6fb842219b92e2fb6ed44b2ca)

6 years agoMinor README tweaks
Stephen Morris [Tue, 11 Feb 2020 14:14:50 +0000 (15:14 +0100)] 
Minor README tweaks

(cherry picked from commit bc539d48e7ea2588c9a9353b5212534693116056)

6 years agoMerge branch 'mnowak/coverity2-v9_11' into 'v9_11'
Michal Nowak [Wed, 12 Feb 2020 10:15:39 +0000 (10:15 +0000)] 
Merge branch 'mnowak/coverity2-v9_11' into 'v9_11'

[v9_11] Add Coverity Scan to CI

See merge request isc-projects/bind9!3047

6 years agoAdd Coverity Scan to CI
Michal Nowak [Wed, 12 Feb 2020 10:15:39 +0000 (10:15 +0000)] 
Add Coverity Scan to CI

This job requires two CI variables to be set:

  - COVERITY_SCAN_PROJECT_NAME: project name, which is associated with
    the BIND branch for which this job is executed, e.g. "bind-master",

  - COVERITY_SCAN_TOKEN: project token.

(cherry picked from commit e8392e4bb911366b65cdc461ec907d9e1a68bf54)

6 years agoMerge branch '1602-rpz-system-test-failed-because-protoype-responses-timed-out-v9_11...
Mark Andrews [Wed, 12 Feb 2020 09:18:33 +0000 (09:18 +0000)] 
Merge branch '1602-rpz-system-test-failed-because-protoype-responses-timed-out-v9_11' into 'v9_11'

spin waiting for prototype dig responses

See merge request isc-projects/bind9!3044

6 years agospin waiting for prototype dig responses
Mark Andrews [Wed, 12 Feb 2020 02:54:17 +0000 (13:54 +1100)] 
spin waiting for prototype dig responses

(cherry picked from commit c38752b07ce8256488b7c31ec1175ac5c926e456)

6 years agoMerge branch '1616-autosign-not-waiting-long-enough-for-zone-to-be-signed-v9_11-and...
Mark Andrews [Wed, 12 Feb 2020 08:06:03 +0000 (08:06 +0000)] 
Merge branch '1616-autosign-not-waiting-long-enough-for-zone-to-be-signed-v9_11-and-maybe-others' into 'v9_11'

Resolve "autosign not waiting long enough for zone to be signed v9_11 and maybe others"

See merge request isc-projects/bind9!3039

6 years agowait for apex NSEC3 to be generated
Mark Andrews [Wed, 12 Feb 2020 01:47:09 +0000 (12:47 +1100)] 
wait for apex NSEC3 to be generated

6 years agoMerge branch '1428-possible-data-race-in-rbtdb-happens-occasionally-on-ppc64le-v9_14...
Ondřej Surý [Tue, 11 Feb 2020 22:06:53 +0000 (22:06 +0000)] 
Merge branch '1428-possible-data-race-in-rbtdb-happens-occasionally-on-ppc64le-v9_14-v9_11' into 'v9_11'

Resolve "Possible data race in rbtdb, happens occasionally on ppc64le"

See merge request isc-projects/bind9!3037

6 years agoConvert all atomic operations in isc_rwlock to sequentially-consistent ordering
Ondřej Surý [Sat, 1 Feb 2020 09:48:20 +0000 (10:48 +0100)] 
Convert all atomic operations in isc_rwlock to sequentially-consistent ordering

The memory ordering in the rwlock was all wrong, I am copying excerpts
from the https://en.cppreference.com/w/c/atomic/memory_order#Relaxed_ordering
for the convenience of the reader:

  Relaxed ordering

  Atomic operations tagged memory_order_relaxed are not synchronization
  operations; they do not impose an order among concurrent memory
  accesses. They only guarantee atomicity and modification order
  consistency.

  Sequentially-consistent ordering

  Atomic operations tagged memory_order_seq_cst not only order memory
  the same way as release/acquire ordering (everything that
  happened-before a store in one thread becomes a visible side effect in
  the thread that did a load), but also establish a single total
  modification order of all atomic operations that are so tagged.

Which basically means that we had no or weak synchronization between
threads using the same variables in the rwlock structure.  There should
not be a significant performance drop because the critical sections were
already protected by:

  while(1) {
    if (relaxed_atomic_operation) {
      break;
    }
    LOCK(lock);
    if (!relaxed_atomic_operation) {
      WAIT(sem, lock);
    }
    UNLOCK(lock)l
  }

I would add one more thing to "Don't do your own crypto, folks.":

  - Also don't do your own locking, folks.

As part of this commit, I have also cleaned up the #ifdef spaghetti,
and fixed the isc_atomic API usage.

6 years agoMake isc_rwlock.c thread-safe
Ondřej Surý [Mon, 13 May 2019 17:19:11 +0000 (00:19 +0700)] 
Make isc_rwlock.c thread-safe

The ThreadSanitizer found several possible data races in our rwlock
implementation.  This commit convert .spins and .write_granted fields
to atomic.

(cherry picked from commit 1da0994ea4dd09dbf8b503bfa08a6f874e24978c)

6 years agoMerge branch 'marka-coverity-v9_11' into 'v9_11'
Mark Andrews [Tue, 11 Feb 2020 14:07:12 +0000 (14:07 +0000)] 
Merge branch 'marka-coverity-v9_11' into 'v9_11'

Address Coverity warnings in v9 11

See merge request isc-projects/bind9!3032

6 years agoSilence Coverity FORWARD_NULL warning
Mark Andrews [Mon, 10 Feb 2020 20:52:24 +0000 (07:52 +1100)] 
Silence Coverity FORWARD_NULL warning

CID 1458400 (#1 of 1): Dereference after null check
(FORWARD_NULL) 14. var_deref_model: Passing null pointer
nxt->typebits to mem_tobuffer, which dereferences it. [show
details]

219        return (mem_tobuffer(target, nxt->typebits, nxt->len));

6 years agoSilence Coverity CHECKED_RETURN warnings
Mark Andrews [Mon, 10 Feb 2020 20:44:21 +0000 (07:44 +1100)] 
Silence Coverity CHECKED_RETURN warnings

CID 1458403 (#1 of 1): Unchecked return value (CHECKED_RETURN)
8. check_return: Calling isc_socket_recv without checking
return value (as is done elsewhere 14 out of 17 times).

121        isc_socket_recv(sock, &dev->region, 1, task, my_recv, event->ev_arg);

CID 1458402 (#1 of 1): Unchecked return value (CHECKED_RETURN)
2. check_return: Calling isc_socket_recv without checking
return value (as is done elsewhere 14 out of 17 times).

149        isc_socket_recv(sock, &dev->region, 1, task, my_recv, event->ev_arg);

CID 1458401 (#1 of 1): Unchecked return value (CHECKED_RETURN)
6. check_return: Calling isc_socket_recv without checking
return value (as is done elsewhere 14 out of 17 times).

226                isc_socket_recv(dev->newsocket, &region, 1,
227                                newtask, my_recv, event->ev_arg);

6 years agoMerge branch 'ondrej/remove-OpenSSL-engine-specification-in-label-v9_11' into 'v9_11'
Ondřej Surý [Tue, 11 Feb 2020 10:51:42 +0000 (10:51 +0000)] 
Merge branch 'ondrej/remove-OpenSSL-engine-specification-in-label-v9_11' into 'v9_11'

[v9_11] Cleanup support for specifying PKCS#11 engine as part of the label

See merge request isc-projects/bind9!3034

6 years agoRemove reference to prepending label with engine in manpage
Ondřej Surý [Mon, 10 Feb 2020 15:29:43 +0000 (07:29 -0800)] 
Remove reference to prepending label with engine in manpage

(cherry picked from commit 33fa3d5eb1fb196739702c9b5131cd9ff4eefe1e)

6 years agoCleanup support for specifying PKCS#11 engine as part of the label
Ondřej Surý [Wed, 22 Jan 2020 09:16:22 +0000 (10:16 +0100)] 
Cleanup support for specifying PKCS#11 engine as part of the label

The code for specifying OpenSSL PKCS#11 engine as part of the label
(e.g. -l "pkcs11:token=..." instead of -E pkcs11 -l "token=...")
was non-functional.  This commit just cleans the related code.

(cherry picked from commit a5c87d9d186e155553be0ae153bb50180f54fffd)

6 years agoMerge branch '932-doc-query-error-logging-v9_11' into 'v9_11'
Evan Hunt [Sun, 9 Feb 2020 00:09:03 +0000 (00:09 +0000)] 
Merge branch '932-doc-query-error-logging-v9_11' into 'v9_11'

improve documentation of query logging

See merge request isc-projects/bind9!3028

6 years agoimprove documentation of query logging
Evan Hunt [Wed, 29 Jan 2020 23:24:43 +0000 (15:24 -0800)] 
improve documentation of query logging

(cherry picked from commit 21bb9fa77f7999ad4b64eb3245b38cd4927096cc)

6 years agoMerge branch '1560-isc_httpd-and-isc_httpdmgr-structures-are-not-reference-counted...
Ondřej Surý [Sat, 8 Feb 2020 20:21:29 +0000 (20:21 +0000)] 
Merge branch '1560-isc_httpd-and-isc_httpdmgr-structures-are-not-reference-counted-and-magic-v9_11' into 'v9_11'

Resolve "isc_httpd and isc_httpdmgr structures are not reference counted and magic"

See merge request isc-projects/bind9!2940

6 years agoClean the ENTER/EXIT/NOTICE debugging from production code
Ondřej Surý [Tue, 21 Jan 2020 07:25:30 +0000 (08:25 +0100)] 
Clean the ENTER/EXIT/NOTICE debugging from production code

(cherry picked from commit 5b448996e51609b2ed9c9a8c3a952f70e695694f)

6 years agoRefactor parts of isc_httpd and isc_httpd for better readability and safety
Ondřej Surý [Mon, 20 Jan 2020 11:37:57 +0000 (12:37 +0100)] 
Refactor parts of isc_httpd and isc_httpd for better readability and safety

(cherry picked from commit 9643a62dd53129208e534e95cbf89f2571ea6122)

6 years agoadd ISC_MAGIC and reference counting to httpd and httpdmgr
Mark Andrews [Fri, 17 Jan 2020 07:24:24 +0000 (18:24 +1100)] 
add ISC_MAGIC and reference counting to httpd and httpdmgr

(cherry picked from commit 7c3f419d6628b2ebfcd86fdd3116b35001950819)

6 years agoMerge branch 'cppcheck-1.90-warnings-v9_11' into 'v9_11'
Ondřej Surý [Sat, 8 Feb 2020 14:48:40 +0000 (14:48 +0000)] 
Merge branch 'cppcheck-1.90-warnings-v9_11' into 'v9_11'

Cppcheck 1.90 warnings v9 11

See merge request isc-projects/bind9!3001

6 years agomem.c: delay assignment until after REQUIRE
Matthijs Mekking [Wed, 5 Feb 2020 16:00:12 +0000 (17:00 +0100)] 
mem.c: delay assignment until after REQUIRE

6 years agoCheck for basic blocks not NULL
Matthijs Mekking [Wed, 5 Feb 2020 15:50:40 +0000 (16:50 +0100)] 
Check for basic blocks not NULL

6 years agordata: delay assignment until after REQUIRE
Matthijs Mekking [Wed, 5 Feb 2020 10:40:42 +0000 (11:40 +0100)] 
rdata: delay assignment until after REQUIRE

6 years agoSuppress cppcheck false positive nullPointerRedundantCheck
Matthijs Mekking [Wed, 5 Feb 2020 10:33:15 +0000 (11:33 +0100)] 
Suppress cppcheck false positive nullPointerRedundantCheck

6 years agoSuppress unknownMacro directive which is currently broken with OpenSSL
Ondřej Surý [Sat, 1 Feb 2020 18:37:54 +0000 (19:37 +0100)] 
Suppress unknownMacro directive which is currently broken with OpenSSL

(cherry picked from commit 2868eafc4612deaa6f45f79afc425f05063ecb04)

6 years agoskip if first is NULL
Mark Andrews [Wed, 5 Feb 2020 09:40:33 +0000 (10:40 +0100)] 
skip if first is NULL

(manually picked from 704b9ee9d08c47740fe2401900b65f188ef07fe2)

6 years agodelay assignment until after REQUIRE
Mark Andrews [Thu, 30 Jan 2020 07:19:11 +0000 (18:19 +1100)] 
delay assignment until after REQUIRE

(cherry picked from commit c65c06301c56860b5b75bbbc42c00f6459a646f8)

6 years agosimplify ISC_LIKELY/ISC_UNLIKELY for CPPCHECK
Mark Andrews [Thu, 30 Jan 2020 06:27:08 +0000 (17:27 +1100)] 
simplify ISC_LIKELY/ISC_UNLIKELY for CPPCHECK

(cherry picked from commit 6c2e138d7aac0e7487b2ba2df6796ba64ccfc26b)

6 years agosimplify RUNTIME_CHECK for cppcheck
Mark Andrews [Thu, 30 Jan 2020 06:14:42 +0000 (17:14 +1100)] 
simplify RUNTIME_CHECK for cppcheck

(cherry picked from commit 668a972d1e71ccc7282601906dff4bc4bb3a7d1c)

6 years agoMerge branch '1596-echo_ic-should-be-used-for-continuations-v9_11' into 'v9_11'
Mark Andrews [Fri, 7 Feb 2020 22:06:05 +0000 (22:06 +0000)] 
Merge branch '1596-echo_ic-should-be-used-for-continuations-v9_11' into 'v9_11'

Resolve "echo_ic should be used for continuations."

See merge request isc-projects/bind9!3022

6 years agoindent failed: descriptions
Mark Andrews [Thu, 6 Feb 2020 03:18:15 +0000 (14:18 +1100)] 
indent failed: descriptions

(cherry picked from commit 1e4773f121689a917efcb340dd23de4a16f7c30c)

6 years agoindent some test descriptions/continuation
Mark Andrews [Thu, 6 Feb 2020 03:16:30 +0000 (14:16 +1100)] 
indent some test descriptions/continuation

(cherry picked from commit ec95bc6f2c8e0d4c211f9c7feb761a100681d098)

6 years agoremove space before 'failed'
Mark Andrews [Thu, 6 Feb 2020 03:13:02 +0000 (14:13 +1100)] 
remove space before 'failed'

(cherry picked from commit 0d5ec0c7dc68541b8688039acbcaddf4f22f4ae3)

6 years agoident continuation of test descriptions
Mark Andrews [Thu, 6 Feb 2020 03:12:31 +0000 (14:12 +1100)] 
ident continuation of test descriptions

(cherry picked from commit 059b16b9910fa1843f2d837ac6cafee1030fc81d)

6 years agoremove space from before 'failed'; count errors
Mark Andrews [Thu, 6 Feb 2020 03:10:15 +0000 (14:10 +1100)] 
remove space from before 'failed'; count errors

(cherry picked from commit 879c63b5739e8d3423da69e28bddc7b07b04441c)

6 years agoMerge branch '1559-dnssec-system-test-failed-reload-of-root-server-not-completed...
Mark Andrews [Fri, 7 Feb 2020 21:09:02 +0000 (21:09 +0000)] 
Merge branch '1559-dnssec-system-test-failed-reload-of-root-server-not-completed-in-time-v9_11' into 'v9_11'

wait for root server to complete reloading

See merge request isc-projects/bind9!3019

6 years agowait for root server to complete reloading
Mark Andrews [Tue, 14 Jan 2020 06:08:25 +0000 (17:08 +1100)] 
wait for root server to complete reloading

(cherry picked from commit 784e64f238482e4e58ea57ebe84e0e7c96680130)

6 years agoMerge branch '1599-autosign-conversion-from-nsec3-to-nsec-can-take-more-than-2-second...
Mark Andrews [Fri, 7 Feb 2020 14:08:40 +0000 (14:08 +0000)] 
Merge branch '1599-autosign-conversion-from-nsec3-to-nsec-can-take-more-than-2-seconds-v9_11' into 'v9_11'

wait a short while for no NSEC3PARAM

See merge request isc-projects/bind9!3017

6 years agowait a short while for no NSEC3PARAM
Mark Andrews [Wed, 5 Feb 2020 08:42:47 +0000 (19:42 +1100)] 
wait a short while for no NSEC3PARAM

(cherry picked from commit e378241324c7441c8d0b0a251e746d107afcea35)

6 years agoMerge branch 'marka-coverity-dns-db-find-v9_11' into 'v9_11'
Michał Kępień [Fri, 7 Feb 2020 11:18:40 +0000 (11:18 +0000)] 
Merge branch 'marka-coverity-dns-db-find-v9_11' into 'v9_11'

Marka coverity dns db find v9 11

See merge request isc-projects/bind9!3015

6 years agoFix indenting.
Mark Andrews [Thu, 6 Feb 2020 00:02:38 +0000 (11:02 +1100)] 
Fix indenting.

(cherry picked from commit 98d5109e82b6b1d64776fe64153a9ff49f68826c)

6 years agoCorrect logged function name.
Mark Andrews [Thu, 6 Feb 2020 00:02:17 +0000 (11:02 +1100)] 
Correct logged function name.

(cherry picked from commit 550bbee42762d8b23a58fe2c995d4593dc4043aa)

6 years agoMerge branch 'michal/fix-the-dnssec-system-test-on-windows-v9_11' into 'v9_11'
Michał Kępień [Thu, 6 Feb 2020 14:20:58 +0000 (14:20 +0000)] 
Merge branch 'michal/fix-the-dnssec-system-test-on-windows-v9_11' into 'v9_11'

[v9_11] Fix the "dnssec" system test on Windows

See merge request isc-projects/bind9!3013

6 years agoFix the "dnssec" system test on Windows
Michał Kępień [Thu, 6 Feb 2020 14:17:38 +0000 (15:17 +0100)] 
Fix the "dnssec" system test on Windows

Make sure carriage return characters are stripped from awk input to
enable the "dnssec" system test to pass on Windows.

(cherry picked from commit 2f694f0b779a50918cdd24f05de04ab6bad043e9)

6 years agoMerge branch '914-forwarders-port-documentation-v9_11' into 'v9_11'
Matthijs Mekking [Thu, 6 Feb 2020 09:40:00 +0000 (09:40 +0000)] 
Merge branch '914-forwarders-port-documentation-v9_11' into 'v9_11'

Document forwarders config port and dscp param

See merge request isc-projects/bind9!3009