From e82a11f803e20e5c188cc28dc6e71751c997661a Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Wed, 27 Jun 2018 13:48:45 +0200 Subject: [PATCH] Update to Samba 4.8.3 --- .gitignore | 2 + samba-4.8.3-fix_krb5_plugins.patch | 270 +++++++++++++++++++++++++++++ samba.spec | 42 +++-- sources | 4 +- 4 files changed, 298 insertions(+), 20 deletions(-) create mode 100644 samba-4.8.3-fix_krb5_plugins.patch diff --git a/.gitignore b/.gitignore index b098dd1..d1ca2ab 100644 --- a/.gitignore +++ b/.gitignore @@ -125,3 +125,5 @@ samba-3.6.0pre1.tar.gz /samba-4.8.1.tar.asc /samba-4.8.2.tar.xz /samba-4.8.2.tar.asc +/samba-4.8.3.tar.asc +/samba-4.8.3.tar.xz diff --git a/samba-4.8.3-fix_krb5_plugins.patch b/samba-4.8.3-fix_krb5_plugins.patch new file mode 100644 index 0000000..86aeadb --- /dev/null +++ b/samba-4.8.3-fix_krb5_plugins.patch @@ -0,0 +1,270 @@ +From 341da4f38809d0efaa282d5281ee69c62a826f9a Mon Sep 17 00:00:00 2001 +From: Andreas Schneider +Date: Wed, 27 Jun 2018 14:06:39 +0200 +Subject: [PATCH 1/4] krb5_plugin: Install plugins to krb5 modules dir + +BUG: https://bugzilla.samba.org/show_bug.cgi?id=13489 + +Signed-off-by: Andreas Schneider +Reviewed-by: Alexander Bokovoy +--- + nsswitch/wscript_build | 12 +++++++----- + 1 file changed, 7 insertions(+), 5 deletions(-) + +diff --git a/nsswitch/wscript_build b/nsswitch/wscript_build +index 15e93db2f05..576855bb56c 100644 +--- a/nsswitch/wscript_build ++++ b/nsswitch/wscript_build +@@ -105,16 +105,18 @@ if bld.CONFIG_SET('WITH_PAM_MODULES') and bld.CONFIG_SET('HAVE_PAM_START'): + ) + + if bld.CONFIG_SET('HAVE_KRB5_LOCATE_PLUGIN_H'): +- bld.SAMBA_LIBRARY('winbind_krb5_locator', +- source='winbind_krb5_locator.c', +- deps='wbclient krb5 com_err', +- realname='winbind_krb5_locator.so') ++ bld.SAMBA_LIBRARY('winbind_krb5_locator', ++ source='winbind_krb5_locator.c', ++ deps='wbclient krb5 com_err', ++ realname='winbind_krb5_locator.so', ++ install_path='${MODULESDIR}/krb5') + + if bld.CONFIG_SET('HAVE_KRB5_LOCALAUTH_PLUGIN_H'): + bld.SAMBA_LIBRARY('winbind_krb5_localauth', + source='krb5_plugin/winbind_krb5_localauth.c', + deps='wbclient krb5 com_err', +- realname='winbind-krb5-localauth.so') ++ realname='winbind_krb5_localauth.so', ++ install_path='${MODULESDIR}/krb5') + + bld.SAMBA_SUBSYSTEM('WB_REQTRANS', + source='wb_reqtrans.c', +-- +2.17.1 + + +From a1e9527b207b4bb045012cf78649362b42351313 Mon Sep 17 00:00:00 2001 +From: Andreas Schneider +Date: Wed, 27 Jun 2018 14:08:56 +0200 +Subject: [PATCH 2/4] krb5_plugin: Move krb5 locator plugin to krb5_plugin + subdir + +BUG: https://bugzilla.samba.org/show_bug.cgi?id=13489 + +Signed-off-by: Andreas Schneider +Reviewed-by: Alexander Bokovoy +--- + nsswitch/{ => krb5_plugin}/winbind_krb5_locator.c | 0 + nsswitch/wscript_build | 2 +- + 2 files changed, 1 insertion(+), 1 deletion(-) + rename nsswitch/{ => krb5_plugin}/winbind_krb5_locator.c (100%) + +diff --git a/nsswitch/winbind_krb5_locator.c b/nsswitch/krb5_plugin/winbind_krb5_locator.c +similarity index 100% +rename from nsswitch/winbind_krb5_locator.c +rename to nsswitch/krb5_plugin/winbind_krb5_locator.c +diff --git a/nsswitch/wscript_build b/nsswitch/wscript_build +index 576855bb56c..dd1952b799b 100644 +--- a/nsswitch/wscript_build ++++ b/nsswitch/wscript_build +@@ -106,7 +106,7 @@ if bld.CONFIG_SET('WITH_PAM_MODULES') and bld.CONFIG_SET('HAVE_PAM_START'): + + if bld.CONFIG_SET('HAVE_KRB5_LOCATE_PLUGIN_H'): + bld.SAMBA_LIBRARY('winbind_krb5_locator', +- source='winbind_krb5_locator.c', ++ source='krb5_plugin/winbind_krb5_locator.c', + deps='wbclient krb5 com_err', + realname='winbind_krb5_locator.so', + install_path='${MODULESDIR}/krb5') +-- +2.17.1 + + +From b0fa360161aba9aa092bf4ecf0533a49d621a068 Mon Sep 17 00:00:00 2001 +From: Andreas Schneider +Date: Wed, 27 Jun 2018 15:14:15 +0200 +Subject: [PATCH 3/4] docs: Move winbind_krb5_locator manpage to volume 8 + +The vfs and idmap manpages are in volume 8 too. + +BUG: https://bugzilla.samba.org/show_bug.cgi?id=13489 + +Signed-off-by: Andreas Schneider +Reviewed-by: Alexander Bokovoy +--- + ...inbind_krb5_locator.7.xml => winbind_krb5_locator.8.xml} | 6 +++--- + docs-xml/wscript_build | 2 +- + 2 files changed, 4 insertions(+), 4 deletions(-) + rename docs-xml/manpages/{winbind_krb5_locator.7.xml => winbind_krb5_locator.8.xml} (96%) + +diff --git a/docs-xml/manpages/winbind_krb5_locator.7.xml b/docs-xml/manpages/winbind_krb5_locator.8.xml +similarity index 96% +rename from docs-xml/manpages/winbind_krb5_locator.7.xml +rename to docs-xml/manpages/winbind_krb5_locator.8.xml +index 17e401a9da0..0af0c2cc95f 100644 +--- a/docs-xml/manpages/winbind_krb5_locator.7.xml ++++ b/docs-xml/manpages/winbind_krb5_locator.8.xml +@@ -1,12 +1,12 @@ + + +- ++ + + + winbind_krb5_locator +- 7 ++ 8 + Samba +- 7 ++ 8 + &doc.version; + + +diff --git a/docs-xml/wscript_build b/docs-xml/wscript_build +index 954c62a29bc..2d686eb38b0 100644 +--- a/docs-xml/wscript_build ++++ b/docs-xml/wscript_build +@@ -103,7 +103,7 @@ pam_winbind_manpages = ''' + manpages/pam_winbind.conf.5 + ''' + +-krb5_locator_manpages = 'manpages/winbind_krb5_locator.7' ++krb5_locator_manpages = 'manpages/winbind_krb5_locator.8' + + def smbdotconf_generate_parameter_list(task): + parameter_all = task.outputs[0].bldpath(task.env) +-- +2.17.1 + + +From d16a8b65af5de19c1ccbb95e3542d01f77696be3 Mon Sep 17 00:00:00 2001 +From: Andreas Schneider +Date: Wed, 27 Jun 2018 15:06:07 +0200 +Subject: [PATCH 4/4] docs: Add manpage for winbind_krb5_localauth.8 + +BUG: https://bugzilla.samba.org/show_bug.cgi?id=13489 + +Signed-off-by: Andreas Schneider +Reviewed-by: Alexander Bokovoy +--- + .../manpages/winbind_krb5_localauth.8.xml | 86 +++++++++++++++++++ + docs-xml/wscript_build | 4 + + 2 files changed, 90 insertions(+) + create mode 100644 docs-xml/manpages/winbind_krb5_localauth.8.xml + +diff --git a/docs-xml/manpages/winbind_krb5_localauth.8.xml b/docs-xml/manpages/winbind_krb5_localauth.8.xml +new file mode 100644 +index 00000000000..a382e71ead3 +--- /dev/null ++++ b/docs-xml/manpages/winbind_krb5_localauth.8.xml +@@ -0,0 +1,86 @@ ++ ++ ++ ++ ++ ++ winbind_krb5_localauth ++ 8 ++ Samba ++ 8 ++ &doc.version; ++ ++ ++ ++ ++ winbind_krb5_localauth ++ A plugin for MIT Kerberos for mapping user accounts. ++ ++ ++ ++ ++ DESCRIPTION ++ ++ ++ This plugin is part of the ++ samba ++ 7 suite. ++ ++ ++ ++ winbind_krb5_localauth is a plugin that ++ permits the MIT Kerberos libraries that Kerberos principals can ++ be validated against local user accounts. ++ ++ ++ ++ PREREQUISITES ++ ++ MIT Kerberos (at least version 1.12) is required. ++ ++ ++ ++ The plugin queries the winbindd ++ 8 daemon which needs to be configured ++ and started separately. ++ ++ ++ ++ The following sections needs to be added to the ++ krb5.conf file. ++ ++ ++[plugins] ++ localauth = { ++ module = winbind:/usr/lib64/samba/krb5/winbind_krb5_localauth.so ++ enable_only = winbind ++ } ++ ++ ++ ++ ++ ++ VERSION ++ ++ ++ This man page is part of version &doc.version; of the Samba ++ suite. ++ ++ ++ ++ ++ AUTHOR ++ ++ ++ The original Samba software and related utilities were created ++ by Andrew Tridgell. Samba is now developed by the Samba Team as ++ an Open Source project similar to the way the Linux kernel is ++ developed. ++ ++ ++ ++ The winbind_krb5_localauth manpage was written by Andreas ++ Schneider. ++ ++ ++ ++ +diff --git a/docs-xml/wscript_build b/docs-xml/wscript_build +index 2d686eb38b0..ec5d28fc62a 100644 +--- a/docs-xml/wscript_build ++++ b/docs-xml/wscript_build +@@ -104,6 +104,7 @@ pam_winbind_manpages = ''' + ''' + + krb5_locator_manpages = 'manpages/winbind_krb5_locator.8' ++krb5_localauth_manpages = 'manpages/winbind_krb5_localauth.8' + + def smbdotconf_generate_parameter_list(task): + parameter_all = task.outputs[0].bldpath(task.env) +@@ -162,5 +163,8 @@ if ('XSLTPROC_MANPAGES' in bld.env and bld.env['XSLTPROC_MANPAGES']): + if bld.CONFIG_SET('HAVE_KRB5_LOCATE_PLUGIN_H'): + bld.SAMBAMANPAGES(krb5_locator_manpages) + ++ if bld.CONFIG_SET('HAVE_KRB5_LOCALAUTH_PLUGIN_H'): ++ bld.SAMBAMANPAGES(krb5_localauth_manpages) ++ + if bld.SAMBA3_IS_ENABLED_MODULE('vfs_zfsacl'): + bld.SAMBAMANPAGES('manpages/vfs_zfsacl.8') +-- +2.17.1 + diff --git a/samba.spec b/samba.spec index 5796465..8e303ce 100644 --- a/samba.spec +++ b/samba.spec @@ -8,7 +8,7 @@ %define main_release 1 -%define samba_version 4.8.2 +%define samba_version 4.8.3 %define talloc_version 2.1.11 %define tdb_version 1.3.15 %define tevent_version 0.9.36 @@ -89,7 +89,7 @@ Name: samba Version: %{samba_version} -Release: %{samba_release}.1 +Release: %{samba_release} %if 0%{?rhel} Epoch: 0 @@ -113,14 +113,16 @@ Source1: https://ftp.samba.org/pub/samba/samba-%{version}%{pre_release}.t Source2: gpgkey-52FBC0B86D954B0843324CDC6F33915B6568B7EA.gpg # Red Hat specific replacement-files -Source10: samba.log -Source11: smb.conf.vendor -Source12: smb.conf.example -Source13: pam_winbind.conf -Source14: samba.pamd +Source10: samba.log +Source11: smb.conf.vendor +Source12: smb.conf.example +Source13: pam_winbind.conf +Source14: samba.pamd -Source200: README.dc -Source201: README.downgrade +Source200: README.dc +Source201: README.downgrade + +Patch0: samba-4.8.3-fix_krb5_plugins.patch Requires(pre): /usr/sbin/groupadd Requires(post): systemd @@ -188,12 +190,10 @@ BuildRequires: python2-dns # Add python2-iso8601 to avoid that the # version in Samba is being packaged BuildRequires: python2-iso8601 -BuildRequires: python2-subunit BuildRequires: python3-devel # Add python3-iso8601 to avoid that the # version in Samba is being packaged BuildRequires: python3-iso8601 -BuildRequires: python3-subunit BuildRequires: quota-devel BuildRequires: readline-devel BuildRequires: rpcgen @@ -1049,7 +1049,7 @@ install -d -m 0755 %{buildroot}%{_sysconfdir}/NetworkManager/dispatcher.d/ install -m 0755 packaging/NetworkManager/30-winbind-systemd \ %{buildroot}%{_sysconfdir}/NetworkManager/dispatcher.d/30-winbind -# winbind krb5 locator +# winbind krb5 plugins install -d -m 0755 %{buildroot}%{_libdir}/krb5/plugins/libkrb5 touch %{buildroot}%{_libdir}/krb5/plugins/libkrb5/winbind_krb5_locator.so @@ -1268,18 +1268,18 @@ fi %postun winbind-krb5-locator if [ "$1" -ge "1" ]; then - if [ "`readlink %{_sysconfdir}/alternatives/winbind_krb5_locator.so`" == "%{_libdir}/winbind_krb5_locator.so" ]; then - %{_sbindir}/update-alternatives --set winbind_krb5_locator.so %{_libdir}/winbind_krb5_locator.so + if [ "`readlink %{_sysconfdir}/alternatives/winbind_krb5_locator.so`" == "%{_libdir}/samba/krb5/winbind_krb5_locator.so" ]; then + %{_sbindir}/update-alternatives --set winbind_krb5_locator.so %{_libdir}/samba/krb5/winbind_krb5_locator.so fi fi %post winbind-krb5-locator %{_sbindir}/update-alternatives --install %{_libdir}/krb5/plugins/libkrb5/winbind_krb5_locator.so \ - winbind_krb5_locator.so %{_libdir}/winbind_krb5_locator.so 10 + winbind_krb5_locator.so %{_libdir}/samba/krb5/winbind_krb5_locator.so 10 %preun winbind-krb5-locator if [ $1 -eq 0 ]; then - %{_sbindir}/update-alternatives --remove winbind_krb5_locator.so %{_libdir}/winbind_krb5_locator.so + %{_sbindir}/update-alternatives --remove winbind_krb5_locator.so %{_libdir}/samba/krb5/winbind_krb5_locator.so fi %post winbind-modules -p /sbin/ldconfig @@ -2707,15 +2707,17 @@ fi %defattr(-,root,root) %{_bindir}/ntlm_auth %{_bindir}/wbinfo +%{_libdir}/samba/krb5/winbind_krb5_localauth.so %{_mandir}/man1/ntlm_auth.1.gz %{_mandir}/man1/wbinfo.1* +%{_mandir}/man8/winbind_krb5_localauth.8* ### WINBIND-KRB5-LOCATOR %files winbind-krb5-locator %defattr(-,root,root) %ghost %{_libdir}/krb5/plugins/libkrb5/winbind_krb5_locator.so -%{_libdir}/winbind_krb5_locator.so -%{_mandir}/man7/winbind_krb5_locator.7* +%{_libdir}/samba/krb5/winbind_krb5_locator.so +%{_mandir}/man8/winbind_krb5_locator.8* ### WINBIND-MODULES %files winbind-modules @@ -3551,6 +3553,10 @@ fi %endif # with_clustering_support %changelog +* Tue Jun 26 2018 Andreas Schneider - 4.8.3-1 +- Update to Samba 4.8.3 +- Remove python(2|3)-subunit dependency + * Tue Jun 19 2018 Miro HronĨok - 2:4.8.2-1.1 - Rebuilt for Python 3.7 diff --git a/sources b/sources index 65cfbd4..4a33842 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -SHA512 (samba-4.8.2.tar.xz) = 4557d515789e2f5bfeb2f67d98c479ac26d2aebca286ed50d9103a6edb79a3a1d95049224cd77713e9f3084bc8ea4800629fb19d761ae96eb1bc4c77d7d5b10c -SHA512 (samba-4.8.2.tar.asc) = c78ced882897188c74380cc2ff4b2c575d59c28e9eab52330a7dfef029247a814c2df5f4a18920867e54ac49c4ad984093b0068bbc6e870f9fa061a0a6b80595 +SHA512 (samba-4.8.3.tar.asc) = bd56dd9e811b91abc98e0b7e09960a3fd4a988b3481af88193573b2582db035c46f5a8c803f8ffbcc4b6c85050e0b021e549512b807dcf6086e0322de8e920c5 +SHA512 (samba-4.8.3.tar.xz) = 0df56bebf00e2a3b54e5012d0888a637c1ff5d10f47907b15162cc786f6a2a4d77f78aa142c7ab532536110c0aee14ff662f0f23fe2e24bf3cfb169325c5a249