From 63f6426fb6c9baf8ba823d4c9a31bfc61c23a1a9 Mon Sep 17 00:00:00 2001 From: Arthur de Jong Date: Tue, 17 Aug 2010 16:52:02 +0000 Subject: only offer to fix nsswitch.conf if PAM has been converted with pam-auth-update git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1177 ef36b2f9-881f-0410-afb5-c4e39611909c --- debian/libpam-ldapd.postinst | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'debian') diff --git a/debian/libpam-ldapd.postinst b/debian/libpam-ldapd.postinst index 026c2e9..9d62b4f 100644 --- a/debian/libpam-ldapd.postinst +++ b/debian/libpam-ldapd.postinst @@ -34,8 +34,10 @@ nss_enable() # if /etc/nsswitch.conf contains passwd: ..ldap but not shadow: ...ldap # warn the user that this will not work and offer to fix it +# (only do this if it seems we have switched to pam-auth-update) if grep -q '^passwd:.*ldap' /etc/nsswitch.conf && \ - ! grep -q '^shadow:.*ldap' /etc/nsswitch.conf + ! grep -q '^shadow:.*ldap' /etc/nsswitch.conf && \ + grep -q pam-auth-update /etc/pam.d/common-auth then if db_input critical libpam-ldapd/enable_shadow then -- cgit v1.2.3