From 4f471180cc08e40c19d907892fc2102c43fecd49 Mon Sep 17 00:00:00 2001 From: Peter Palfrader Date: Mon, 24 Nov 2008 11:25:18 +0100 Subject: [PATCH] Properly show shadowlastchange and mail disabled message when locking an account, but not disabling email. It was written to ldap correctly, but we updated the data to display wrongly. --- debian/changelog | 8 ++++++++ ud-info | 4 ++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index 0f687c3..8d24a2e 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,11 @@ +userdir-ldap (0.3.XX) unstable; urgency=low + + * Properly show shadowlastchange and mail disabled message when + locking an account, but not disabling email. It was written to + ldap correctly, but we updated the data to display wrongly. + + -- Peter Palfrader Mon, 24 Nov 2008 11:24:16 +0100 + userdir-ldap (0.3.52) unstable; urgency=low * Remove cruft comment. diff --git a/ud-info b/ud-info index 1c91f1c..282d6a4 100755 --- a/ud-info +++ b/ud-info @@ -299,10 +299,10 @@ def Lock(UserDn, Attrs, DisableMail=True): (ldap.MOD_REPLACE,"shadowExpire","1")]; if DisableMail: recs.append( (ldap.MOD_REPLACE,"mailDisableMessage","account locked") ) - Attrs[0][1]["shadowLastChange"] = [shadowLast]; + Attrs[0][1]["mailDisableMessage"] = ["account locked"]; l.modify_s(UserDn,recs); Attrs[0][1]["userPassword"] = ["{crypt}*LK*"]; - Attrs[0][1]["mailDisableMessage"] = ["account locked"]; + Attrs[0][1]["shadowLastChange"] = [shadowLast]; Attrs[0][1]["shadowExpire"] = ["1"]; # Main program starts here -- 2.20.1