summaryrefslogtreecommitdiff
path: root/source3/passdb
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2004-02-23 21:09:09 +0000
committerAndrew Bartlett <abartlet@samba.org>2004-02-23 21:09:09 +0000
commit06549b888621eb8ad05c25604e0c23c9930267b7 (patch)
tree8d84b42033c51a11355d51905704623e30cf2ab9 /source3/passdb
parentaa4abfb3b589bf5123b5d0d674c3c26ebdabe1a0 (diff)
downloadsamba-06549b888621eb8ad05c25604e0c23c9930267b7.tar.gz
samba-06549b888621eb8ad05c25604e0c23c9930267b7.tar.bz2
samba-06549b888621eb8ad05c25604e0c23c9930267b7.zip
Found by Fabien Chevalier <fabien.chevalier@supelec.fr> and
JustFillBug <mozbugbox@yahoo.com.au> on the Samba lists - a 'max password age' of zero should be considered as 'never expire'. For the timebeing we just set it like -1, but we might revisit this for closer-to-ms behaviour. Andrew Bartlett (This used to be commit 9ffc490fce215dcaed8ebfc1db85f5017a692ca4)
Diffstat (limited to 'source3/passdb')
-rw-r--r--source3/passdb/pdb_get_set.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source3/passdb/pdb_get_set.c b/source3/passdb/pdb_get_set.c
index c8f28db30f..e69dac524f 100644
--- a/source3/passdb/pdb_get_set.c
+++ b/source3/passdb/pdb_get_set.c
@@ -1103,7 +1103,7 @@ BOOL pdb_set_pass_changed_now (SAM_ACCOUNT *sampass)
return False;
if (!account_policy_get(AP_MAX_PASSWORD_AGE, &expire)
- || (expire==(uint32)-1)) {
+ || (expire==(uint32)-1) || (expire == 0)) {
if (!pdb_set_pass_must_change_time (sampass, get_time_t_max(), PDB_CHANGED))
return False;
} else {