commit 69ffec9f3f73205c705d479b4f2af668eb87b934
Author: Nalin Dahyabhai <nalin(a)redhat.com>
Date: Tue Apr 30 13:27:22 2013 -0400
Try to handle the uniqueMember/member changeover
- in %%post, attempt to rewrite any instances of "map group uniqueMember
..."
to be "map group member ..." in nslcd.conf, as the attribute name changed
in 0.8.4 (via freeipa ticket #3589)
nss-pam-ldapd.spec | 17 ++++++++++++++++-
1 files changed, 16 insertions(+), 1 deletions(-)
---
diff --git a/nss-pam-ldapd.spec b/nss-pam-ldapd.spec
index 0024d07..d887d4d 100644
--- a/nss-pam-ldapd.spec
+++ b/nss-pam-ldapd.spec
@@ -34,7 +34,7 @@
Name: nss-pam-ldapd
Version: 0.8.12
-Release: 3%{?dist}
+Release: 4%{?dist}
Summary: An nsswitch module which uses directory servers
Group: System Environment/Base
License: LGPLv2+
@@ -263,6 +263,16 @@ if grep -q '^gid nslcd' $target ; then
sed -i -e 's,^gid nslcd$,# gid nslcd,g' $target
fi
fi
+# In 0.8.4, the name of the attribute which was expected to contain the DNs of
+# a group's members changed from "uniqueMember" to "member".
Change any
+# instances of "map group uniqueMember ..." to "map group member
...", unless
+# "member" is already being mapped, in which case attempting this would
+# probably just confuse things further.
+if grep -E -q
"^[[:blank:]]*map[[:blank:]]+group[[:blank:]]+uniqueMember[[:blank:]]" $target ;
then
+ if ! grep -E -q
"^[[:blank:]]*map[[:blank:]]+group[[:blank:]]+member[[:blank:]]" $target ; then
+ sed -i -r -e
"s,^[[:blank:]]*map[[:blank:]]+group[[:blank:]]+uniqueMember[[:blank:]](.*),map group
member \1,g" $target
+ fi
+fi
# Create the daemon's /var/run directory if it isn't there.
if ! test -d /var/run/nslcd ; then
mkdir -p -m 0755 /var/run/nslcd
@@ -319,6 +329,11 @@ exit 0
%endif
%changelog
+* Tue Apr 30 2013 Nalin Dahyabhai <nalin(a)redhat.com> 0.8.12-4
+- in %%post, attempt to rewrite any instances of "map group uniqueMember ..."
+ to be "map group member ..." in nslcd.conf, as the attribute name changed
+ in 0.8.4 (via freeipa ticket #3589)
+
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng(a)lists.fedoraproject.org> -
0.8.12-3
- Rebuilt for
https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild