Bug 15790 - Bind dlz 9.20
Summary: Bind dlz 9.20
Status: NEW
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: DNS plugin (BIND DLZ) (show other bugs)
Version: 4.21.3
Hardware: x64 Linux
: P5 normal (vote)
Target Milestone: ---
Assignee: Amitay Isaacs
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-01-28 11:19 UTC by bkammers
Modified: 2025-01-31 08:10 UTC (History)
0 users

See Also:


Attachments
Bind 9.20 support for samba (3.21 KB, patch)
2025-01-30 12:44 UTC, Caglar Ulkuderner
caglar: review-
caglar: review-
caglar: ci-passed-
caglar: ci-passed-
Details

Note You need to log in before you can comment on or make changes to this bug.
Description bkammers 2025-01-28 11:19:51 UTC
When do you release dlz module for bind 9.20?

I will upgrade my servers and clients to Debian 13 and this use bind 9.20.

In my lab, get worked with symbolic link from 9.18 to 9.20.
Service running.
Comment 1 Caglar Ulkuderner 2025-01-30 12:44:49 UTC
Created attachment 18546 [details]
Bind 9.20 support for samba

Attached patch is also on gitlab page:

https://gitlab.com/samba-team/samba/-/merge_requests/3932

patch is also backward compatable.
Comment 2 Caglar Ulkuderner 2025-01-31 08:10:04 UTC
Comment on attachment 18546 [details]
Bind 9.20 support for samba

>diff --git a/python/samba/provision/sambadns.py b/python/samba/provision/sambadns.py
>index 952e875c862331b5c03eb8de25ca8f5f728e672e..b3530328e9ab6cbad0d5df93ad4765f17b2734f5 100644
>--- a/python/samba/provision/sambadns.py
>+++ b/python/samba/provision/sambadns.py
>@@ -1032,6 +1032,8 @@ def create_named_conf(paths, realm, dnsdomain, dns_backend, logger):
>             bind9_16 = ''
>         elif bind_info.upper().find('BIND 9.18') != -1:
>             bind9_18 = ''
>+        elif bind_info.upper().find('BIND 9.20') != -1:
>+            bind9_20 = ''
>         elif bind_info.upper().find('BIND 9.7') != -1:
>             raise ProvisioningError("DLZ option incompatible with BIND 9.7.")
>         elif bind_info.upper().find('BIND_9.13') != -1:
>@@ -1052,7 +1054,8 @@ def create_named_conf(paths, realm, dnsdomain, dns_backend, logger):
>                     "BIND9_12": bind9_12,
>                     "BIND9_14": bind9_14,
>                     "BIND9_16": bind9_16,
>-                    "BIND9_18": bind9_18
>+                    "BIND9_18": bind9_18,
>+                    "BIND9_20": bind9_20
>                     })
> 
> 
>diff --git a/source4/dns_server/dlz_minimal.h b/source4/dns_server/dlz_minimal.h
>index b7e36e7f8e6571667895afbf8779f130d8e5c3c7..d4525b61b5a1de8bc2bd0b9ee953f18628da74fd 100644
>--- a/source4/dns_server/dlz_minimal.h
>+++ b/source4/dns_server/dlz_minimal.h
>@@ -51,6 +51,9 @@
> #elif defined (BIND_VERSION_9_18)
> # define DLZ_DLOPEN_VERSION 3
> # define DNS_CLIENTINFO_VERSION 2
>+#elif defined (BIND_VERSION_9_20)
>+# define DLZ_DLOPEN_VERSION 3
>+# define DNS_CLIENTINFO_VERSION 2
> #else
> # error Unsupported BIND version
> #endif
>diff --git a/source4/dns_server/wscript_build b/source4/dns_server/wscript_build
>index ab0a241b937df486f6d803bff18643babe48faaf..f705d1de97d9de32adf494e7ae286311f58f7ff6 100644
>--- a/source4/dns_server/wscript_build
>+++ b/source4/dns_server/wscript_build
>@@ -80,6 +80,16 @@ bld.SAMBA_LIBRARY('dlz_bind9_18',
>                   deps='samba-hostconfig samdb-common gensec popt dnsserver_common',
>                   enabled=bld.AD_DC_BUILD_IS_ENABLED())
> 
>+bld.SAMBA_LIBRARY('dlz_bind9_20',
>+                  source='dlz_bind9.c',
>+                  cflags='-DBIND_VERSION_9_20',
>+                  private_library=True,
>+                  link_name='modules/bind9/dlz_bind9_20.so',
>+                  realname='dlz_bind9_20.so',
>+                  install_path='${MODULESDIR}/bind9',
>+                  deps='samba-hostconfig samdb-common gensec popt dnsserver_common',
>+                  enabled=bld.AD_DC_BUILD_IS_ENABLED())
>+
> bld.SAMBA_LIBRARY('dlz_bind9_for_torture',
>                   source='dlz_bind9.c',
>                   cflags='-DBIND_VERSION_9_16',
>diff --git a/source4/setup/named.conf.dlz b/source4/setup/named.conf.dlz
>index cbe7d805f58007c132c78b5d83ef1c492a27344e..82b9848293a009e9349bfb46b7febe5af2eadff8 100644
>--- a/source4/setup/named.conf.dlz
>+++ b/source4/setup/named.conf.dlz
>@@ -30,8 +30,11 @@ dlz "AD DNS Zone" {
> 
>     # For BIND 9.16.x
>     ${BIND9_16} database "dlopen ${MODULESDIR}/bind9/dlz_bind9_16.so";
>-    #
>+
>     # For BIND 9.18.x
>     ${BIND9_18} database "dlopen ${MODULESDIR}/bind9/dlz_bind9_18.so";
>+
>+    # For BIND 9.20.x
>+    ${BIND9_20} database "dlopen ${MODULESDIR}/bind9/dlz_bind9_20.so";
> };
>