From 9eaa5c690ec1d312c76e2fc3ad717daf921c04f3 Mon Sep 17 00:00:00 2001 From: Ian Kent Date: Mon, 19 Apr 2021 08:11:05 +0800 Subject: [PATCH] - add changes for bug 1942371. --- ...tion-if-nis-support-is-not-available.patch | 35 +++++++++++++++++++ autofs.spec | 13 +++++-- 2 files changed, 45 insertions(+), 3 deletions(-) create mode 100644 autofs-5.1.7-fix-dandling-symlink-creation-if-nis-support-is-not-available.patch diff --git a/autofs-5.1.7-fix-dandling-symlink-creation-if-nis-support-is-not-available.patch b/autofs-5.1.7-fix-dandling-symlink-creation-if-nis-support-is-not-available.patch new file mode 100644 index 0000000..05157b7 --- /dev/null +++ b/autofs-5.1.7-fix-dandling-symlink-creation-if-nis-support-is-not-available.patch @@ -0,0 +1,35 @@ +autofs-5.1.7 - fix dandling symlink creation if nis support is not available + +From: Ian Kent + +If NIS support is not available a dangling symlink is created pointing +from lookup_nis.so to (a non-existent) lookup_yp.so. + +Signed-off-by: Ian Kent +--- + CHANGELOG | 1 + + modules/Makefile | 2 ++ + 2 files changed, 3 insertions(+) + +--- autofs-5.1.7.orig/CHANGELOG ++++ autofs-5.1.7/CHANGELOG +@@ -66,6 +66,7 @@ + - refactor lookup_prune_one_cache() a bit. + - cater for empty mounts list in mnts_get_expire_list(). + - add ext_mount_hash_mutex lock helpers. ++- fix dandling symlink creation if nis support is not available. + + 25/01/2021 autofs-5.1.7 + - make bind mounts propagation slave by default. +--- autofs-5.1.7.orig/modules/Makefile ++++ autofs-5.1.7/modules/Makefile +@@ -77,7 +77,9 @@ install: all + install -c $(MODS) -m 755 $(INSTALLROOT)$(autofslibdir) + -rm -f $(INSTALLROOT)$(autofslibdir)/mount_smbfs.so + ln -fs lookup_file.so $(INSTALLROOT)$(autofslibdir)/lookup_files.so ++ifeq ($(YPCLNT), 1) + ln -fs lookup_yp.so $(INSTALLROOT)$(autofslibdir)/lookup_nis.so ++endif + ifeq ($(LDAP), 1) + ln -fs lookup_ldap.so $(INSTALLROOT)$(autofslibdir)/lookup_ldaps.so + endif diff --git a/autofs.spec b/autofs.spec index 8d8ee48..8661928 100644 --- a/autofs.spec +++ b/autofs.spec @@ -12,7 +12,7 @@ Summary: A tool for automatically mounting and unmounting filesystems Name: autofs Version: 5.1.7 -Release: 12%{?dist} +Release: 13%{?dist} Epoch: 1 License: GPLv2+ Source: https://www.kernel.org/pub/linux/daemons/autofs/v5/autofs-%{version}.tar.gz @@ -92,7 +92,7 @@ BuildRequires: systemd-devel BuildRequires: gcc BuildRequires: autoconf, openldap-devel, bison, flex, libxml2-devel BuildRequires: cyrus-sasl-devel, openssl-devel module-init-tools util-linux -BuildRequires: e2fsprogs libtirpc-devel libsss_autofs libnsl2-devel +BuildRequires: e2fsprogs libtirpc-devel libsss_autofs BuildRequires: rpcgen pkgconfig krb5-devel BuildRequires: make Conflicts: cyrus-sasl-lib < 2.1.23-9 @@ -323,7 +323,14 @@ fi %dir /etc/auto.master.d %changelog -* Tue Apr 13 2021 Ian Kent - 1:5.1.7-11 +* Mon Apr 19 2021 Ian Kent - 1:5.1.7-13 + - bz1942371 - Drop nis support from autofs + - fix dandling symlink creation if nis support is not available. + - remove BuildRequires libnsl2-devel. + - fix incorrect changelog revision. +- Resolves: rhbz#1942371 + +* Tue Apr 13 2021 Ian Kent - 1:5.1.7-12 - bz1948956 - Using -hosts option does not resolve host from /etc/hosts and mount failes - Coverity fixes (arising from RHEL-8 bug 1912106)