Commit Graph
33982 Commits
Author SHA1 Message Date
Petr Špaček d351f78709 Convert "Building BIND" section from README.md to reStructuredText
Converted using pandoc 2.14.2-14 on Arch Linux:

    $ pandoc --shift-heading-level-by=-1 -f markdown -t rst README.md > doc/arm/build.rst

Plus hand-edit to remove sections other than Building BIND 9, remove
misindentation in section headers, and add a standard copyright header.
2022-01-26 12:03:35 +01:00
Petr Špaček 5058817f5a Link to ISC KB for most up-to-date platform support statuses
(cherry-picked from commit 3bd4318fcc)
2022-01-26 12:03:35 +01:00
Petr Špaček 27cfa574dc Replace all occurences of PLATFORMS file with reference to the ARM
The conf.py exclude_patterns now includes platforms.rst to avoid
problems with redefining labels:
https://github.com/sphinx-doc/sphinx/issues/1668#issuecomment-71376208

Plain-text README file was regenerated using commands from v9.16
Makefile.

(cherry-picked from commit 920a2e730b)
2022-01-26 12:03:35 +01:00
Petr Špaček dd901b5c42 Replace duplicate Supported Operating Systems in the ARM by PLATFORMS.rst
(cherry-picked from commit f693c9b1a7)
2022-01-26 12:03:35 +01:00
Petr Špaček b13592f650 Convert PLATFORMS file from Markdown to reStructuredText
Converted using pandoc 2.14.2-14 on Arch Linux:

    $ pandoc -f markdown -t rst PLATFORMS.md > PLATFORMS.rst

The pandoc-generated copyright header was subsequently replaced with
usual one for .rst files.
2022-01-26 12:03:30 +01:00
Arаm Sаrgsyаn 5fba218bf4 Merge branch '3060-revert-view-on-failed-reconfig-v9_16' into 'v9_16'
[v9_16] Improve the view configuration error handling and reverting logic

See merge request isc-projects/bind9!5753
2022-01-26 08:43:31 +00:00
Aram Sargsyan 4ada743291 Don't use RTLD_DEEPBIND with sanitizers
dlopen(3) RTLD_DEEPBIND flag is incompatible with sanitizer runtime
(see https://github.com/google/sanitizers/issues/611 for details).
2022-01-26 08:19:02 +00:00
Aram Sargsyan 254cabb558 Fix a memory leak in dns_dlzcreate()
dns_dlzcreate() fails to free the memory allocated for dlzname
when an error occurs.

Free dlzname's memory (acquired earlier with isc_mem_strdup())
by calling isc_mem_free() before returning an error code.

(cherry picked from commit 4a6c66288f)
2022-01-26 08:19:02 +00:00
Aram Sargsyan b5735ec37a Fix invalid control port number in the catz system test
When failure is expected, the `rndc` command in the catz system test
is being called directly instead of using a function, i.e.:

    $RNDC -c ../common/rndc.conf -s 10.53.0.2 -p 9953 reconfig \
        > /dev/null 2>&1 && ret=1

... instead of:

    rndccmd 10.53.0.2 reconfig && ret=1

This is done to suppress messages like "lt-rndc: 'reconfig' failed:
failure" appearing in the message log of the test, because failure
is actually expected, and the appearance of that message can be
confusing.

The port value used in this case is not correct, making the
`rndc reload` command to fail.  This error was not detected earlier
only because the failure of the command is actually expected, but
the failure happens for a "wrong" reason, and the test still passes.

Fix the error by using the existing variable instead of the fixed
number.

(cherry picked from commit 5f9d4b5db4)
2022-01-26 08:19:02 +00:00
Aram Sargsyan 094e416fff Add a system test for view reverting after a failed reconfiguration
Test the view reverting code by introducing a faulty dlz configuration
in named.conf and using `rndc reconfig` to check if named handles the
situation correctly.

We use "dlz" because the dlz processing code is located in an ideal
place in the view configuration function for the test to cover the
view reverting code.

This test is specifically added to the catz system test to additionally
cover the catz reconfiguration during the mentioned failed
reconfiguration attempt.

(cherry picked from commit 62337d433f)
2022-01-26 08:19:02 +00:00
Aram Sargsyan acc774e4dd Add CHANGES and release notes for [GL #3060]
(cherry picked from commit d7dfa2dc4b)
2022-01-26 08:19:02 +00:00
Aram Sargsyan a663216c0e Improve the zones' view reverting logic when a zone is a catalog zone
When a zone is being configured with a new view, the catalog zones
structure will also be linked to that view. Later on, in case of some
error, should the zone be reverted to the previous view, the link
between the catalog zones structure and the view won't be reverted.

Change the dns_zone_setviewrevert() function so it calls
dns_zone_catz_enable() during a zone revert, which will reset the
link between `catzs` and view.

(cherry picked from commit 2fd967136a)
2022-01-26 08:19:02 +00:00
Aram Sargsyan 885e44650b Separate the locked parts of dns_zone_catz_enable/disable functions
Separate the locked parts of dns_zone_catz_enable() and
dns_zone_catz_disable() functions into static functions.  This will
let us perform those tasks from the other parts of the module while
the zone is locked, avoiding one pair of additional unlocking and
locking operations.

(cherry picked from commit 6b937ed5f6)
2022-01-26 08:19:02 +00:00
Aram Sargsyan f555f1d2eb Improve the view configuration error handling and reverting logic
If a view configuration error occurs during a named reconfiguration
procedure, BIND can end up having twin views (old and new), with some
zones and internal structures attached to the old one, and others
attached to the new one, which essentially creates chaos.

Implement some additional view reverting mechanisms to avoid the
situation described above:

 1. Revert rpz configuration.

 2. Revert catz configuration.

 3. Revert zones to view attachments.

(cherry picked from commit 3697560f04)
2022-01-26 08:19:02 +00:00
Evan Hunt 8e9e2d7608 Merge branch '3111-fix-dlz-pthreads' into 'v9_16'
restore missing lines in dlz_pthread.h

See merge request isc-projects/bind9!5757
2022-01-26 05:09:10 +00:00
Evan Hunt 5996c73516 restore missing lines in dlz_pthread.h
some lines were accidentally deleted during a backport that
made it imposisble to build DLZ modules.
2022-01-25 12:28:48 -08:00
Petr Špaček 7b50984350 Merge branch 'pspacek/fix-historical-relnotes' into 'v9_16'
[v9_16] Fix historical release notes

See merge request isc-projects/bind9!5722
2022-01-24 16:39:22 +00:00
Petr Špaček 675f6c6b57 Remove reference to (unavailable) nsdname-wait-recurse option from ARM
This option is available only in 9.16-S edition, but docs for it were
accidentally imported when documentation was migrated to Sphinx in
!3536.
2022-01-24 17:34:53 +01:00
Petr Špaček ea4a90a96a Fix inconsistent release note for #1807
This was an omission in !3495.
2022-01-24 17:34:53 +01:00
Petr Špaček c3a1287e1f Add missing release notes for CVE-2020-8616 and CVE-2020-8617
These release notes were lost when converting docs from XML to RST
formats. These two notes were removed by commit
5a855f6754.

Related: #1388, #1703, !3536
2022-01-24 17:34:48 +01:00
Ondřej Surý 5656609879 Merge branch 'ondrej/use-utc-for-reproducible-builds-v9_16' into 'v9_16'
Use UTC datetime for reproducible builds

See merge request isc-projects/bind9!5751
2022-01-24 15:35:09 +00:00
Ondřej Surý 7df5065c75 Use UTC datetime for reproducible builds
For reproducible builds, we use last modification time of the CHANGES
file.  This works pretty well, unless the builds are made in different
timezones.

Use UTC option to date command to make the builds reproducible.
2022-01-24 16:24:36 +01:00
Petr Špaček c4769937a5 Merge branch 'pspacek/remove-duplicate-named.conf.rst-v9_16' into 'v9_16'
Remove duplicate named.conf.rst file [v9_16]

See merge request isc-projects/bind9!5746
2022-01-21 14:43:21 +00:00
Petr Špaček da70d59f40 Remove duplicate named.conf.rst file
As far as I can tell, it is some leftover from the times when Sphinx
docs were introduced (commit 9fb6d11abb).
It seems like it is not referenced from anywhere.

(cherry picked from commit 0a5c2c23bb)
2022-01-21 15:33:40 +01:00
Michał Kępień fbb824c167 Merge branch 'v9_16_25-release' into 'v9_16'
Merge 9.16.25 release branch

See merge request isc-projects/bind9!5742
2022-01-20 10:43:21 +00:00
Michał Kępień 5111a76eb0 Prepare release notes for BIND 9.16.26 2022-01-20 11:38:18 +01:00
Tinderbox UserandMichał Kępień f4cdb2448c Merge branch 'prep-release' into v9_16_25-release 2022-01-20 11:37:08 +01:00
Michał Kępień 4a2f91272c Merge branch 'pspacek/prepare-documentation-for-bind-9.16.25' into 'v9_16_25-release'
Prepare documentation for BIND 9.16.25

See merge request isc-private/bind9!343
2022-01-20 11:37:08 +01:00
Tinderbox UserandMichał Kępień 4e0d55cdcd prep 9.16.25 2022-01-20 11:37:08 +01:00
Michał Kępień 9987ff1edf Prepare release notes for BIND 9.16.25 2022-01-20 11:37:08 +01:00
Michał Kępień c5f7ece3ad Reorder release notes 2022-01-20 11:37:08 +01:00
Petr ŠpačekandMichał Kępień 00aeba54c9 Tweak and reword release notes 2022-01-20 11:37:08 +01:00
Michał Kępień 3d1544726b Merge branch '3080-rndc-catch-canceled-v9_16' into 'v9_16'
rndc: add an extra task reference

See merge request isc-projects/bind9!5740
2022-01-20 08:06:21 +00:00
Evan Hunt 3aa529a9e0 CHANGES for [GL #3080] 2022-01-19 12:01:45 -08:00
Evan Hunt 075722f8a2 rndc: add an extra task reference
adding an extra task before launching the rndc app prevents
a use-after-free when task events fire after the app has been
shut down by a signal.
2022-01-19 11:05:00 -08:00
Ondřej Surý 65314e437f Merge branch 'each-fix-changes-v9_16' into 'v9_16'
fix CHANGES

See merge request isc-projects/bind9!5723
2022-01-17 10:59:39 +00:00
Evan HuntandOndřej Surý e437ef6d6b fix misplaced CHANGES note
Change #5676 was incorrectly placed under 9.16.24 when backporting,
but is actually in 9.16.25.
2022-01-17 11:55:46 +01:00
Ondřej Surý c7413e9f5d Merge branch 'djt-update-cookie-secret-doc-v9_16' into 'v9_16'
docs: Update ARM to reflect changes to acceptable cookie-secret values

See merge request isc-projects/bind9!5729
2022-01-17 10:53:57 +00:00
Dan TheisenandOndřej Surý 133b5c1a52 docs: Update ARM to reflect changes to acceptable cookie-secret values
(cherry picked from commit acf1d502d6)
2022-01-17 11:52:13 +01:00
Ondřej Surý 5beaf7638c Merge branch '3093-missing-libuv-code-v9_16' into 'v9_16'
add UV_ENOTSUP to isc___nm_uverr2result()

See merge request isc-projects/bind9!5728
2022-01-17 10:51:31 +00:00
Evan HuntandOndřej Surý 464b09a804 add UV_ENOTSUP to isc___nm_uverr2result()
This error code is now mapped to ISC_R_FAMILYNOSUPPORT.

(cherry picked from commit be0bc24c7f)
2022-01-17 11:47:12 +01:00
Ondřej Surý ea26c36d62 Merge branch 'ondrej/fix-missing-backtick-in-host.rst-v9_16' into 'v9_16'
Add missing backtick to host.rst

See merge request isc-projects/bind9!5725
2022-01-16 07:06:44 +00:00
Ondřej Surý 35aba6f078 Add missing backtick to host.rst
The missing backtick was causing formatting problems in the host
manpage.

(cherry picked from commit aaa31962d2)
2022-01-16 08:02:26 +01:00
Ondřej Surý c79a35294e Merge branch '3095-invalid-recvmmsg-detection-v9_16' into 'v9_16'
Fix the UDP recvmmsg support

See merge request isc-projects/bind9!5717
2022-01-13 22:26:42 +00:00
Ondřej Surý 4666cb4a4e Add CHANGES and release notes for [GL #3095]
(cherry picked from commit 8d778f758b)
2022-01-13 23:05:38 +01:00
Ondrej Sury 04eeb67d97 Instead of detecting MUSL libc, detect padding in struct msghdr
The detection of MUSL libc via autoconf $host turned out to be
not reliable.

Convert the autoconf check from $host detection to actually detect
the padding used in the struct msghdr.
2022-01-13 23:05:38 +01:00
Ondřej Surý 86f9b16fd7 Revert "Always enqueue isc__nm_tcp_resumeread()"
The commit itself is harmless, but at the same time it is also useless,
so we are reverting it.

This reverts commit 11c869a3d5.

(cherry picked from commit 0a4e91ee47)
2022-01-13 21:39:57 +01:00
Ondrej Sury de8dbcbfbc Disable udp recvmmsg support on systems with MUSL libc
The Linux kernel diverts from the POSIX specification for two members of
struct msghdr making them size_t sized (instead of int and socklen_t).
In glibc, the developers have decided to use that.  However, the MUSL
developers used padding for the struct and kept the members defined
according to the POSIX.

This creates a problem, because libuv doesn't use recvmmsg() library
call where the padding members are correctly zeroed and instead calls
the syscall directly, the struct msghdr is passed to the kernel with
enormous values in those two members (because of the random junk in the
padding members) and the syscall thus fail with EMSGSIZE.

Disable udp recvmmsg support on systems with MUSL libc until the libuv
starts zeroing the struct msghdr before passing it to the syscall.

(cherry picked from commit 287ea095f1)
2022-01-13 21:39:57 +01:00
Ondřej Surý 5b02f5a8a0 Fix the UDP recvmmsg support
Previously, the netmgr/udp.c tried to detect the recvmmsg detection in
libuv with #ifdef UV_UDP_<foo> preprocessor macros.  However, because
the UV_UDP_<foo> are not preprocessor macros, but enum members, the
detection didn't work.  Because the detection didn't work, the code
didn't have access to the information when we received the final chunk
of the recvmmsg and tried to free the uvbuf every time.  Fortunately,
the isc__nm_free_uvbuf() had a kludge that detected attempt to free in
the middle of the receive buffer, so the code worked.

However, libuv 1.37.0 changed the way the recvmmsg was enabled from
implicit to explicit, and we checked for yet another enum member
presence with preprocessor macro, so in fact libuv recvmmsg support was
never enabled with libuv >= 1.37.0.

This commit changes to the preprocessor macros to autoconf checks for
declaration, so the detection now works again.  On top of that, it's now
possible to cleanup the alloc_cb and free_uvbuf functions because now,
the information whether we can or cannot free the buffer is available to
us.

(cherry picked from commit 7370725008)
2022-01-13 21:38:43 +01:00
Ondřej Surý 570aae5b9b Merge branch 'ondrej/remove-util-copyrights-v9_16' into 'v9_16'
Remove the copyright handling via util/copyrights

See merge request isc-projects/bind9!5709
2022-01-11 12:06:11 +00:00