* Sat Dec 21 2024 Jean-Philippe Pialasse <jpp@koozali.org> 11.0.0-15.sme
- fix use of passwd command when ldap auth enabled [SME: 6453] - delete spool file only if exists to avoid error [SME: 12763]
This commit is contained in:
@@ -60,6 +60,6 @@ $result = $ldap->ldapdelgroup($groupName);
|
||||
$result && ( $x = $ldapauth ne 'enabled' ? $x : 255, warn "Failed to delete (ldap) group $groupName.\n" );
|
||||
|
||||
# delete mail spool file
|
||||
unless ($x == 255) { unlink("/var/spool/mail/$groupName") or ( $x = 255, warn "Failed to delete /var/spool/mail/$groupName.\n" );}
|
||||
unless ($x == 255) { (if -e "/var/spool/mail/$groupName" ) {unlink("/var/spool/mail/$groupName") or ( $x = 255, warn "Failed to delete /var/spool/mail/$groupName.\n" );} }
|
||||
|
||||
exit ($x);
|
||||
|
@@ -2,7 +2,7 @@ password sufficient pam_unix.so nullok md5 shadow
|
||||
{
|
||||
my $status = $ldap{Authentication} || 'disabled';
|
||||
return unless $status eq 'enabled';
|
||||
$OUT .= "password sufficient pam_ldap.so use_authtok";
|
||||
$OUT .= "password sufficient pam_ldap.so";
|
||||
}
|
||||
password required pam_deny.so
|
||||
|
||||
|
Reference in New Issue
Block a user