Author: jra
Date: 2007-06-05 23:35:39 +0000 (Tue, 05 Jun 2007)
New Revision: 23358

WebSVN: 
http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=23358

Log:
Fix from Justin Maggard <[EMAIL PROTECTED]> - ensure we don't
expire a password if it's explicitly set as ACB_PWNOTREQ.
Jeremy.

Modified:
   branches/SAMBA_3_0/source/auth/auth_sam.c
   branches/SAMBA_3_0_25/source/auth/auth_sam.c
   branches/SAMBA_3_0_26/source/auth/auth_sam.c


Changeset:
Modified: branches/SAMBA_3_0/source/auth/auth_sam.c
===================================================================
--- branches/SAMBA_3_0/source/auth/auth_sam.c   2007-06-05 19:17:05 UTC (rev 
23357)
+++ branches/SAMBA_3_0/source/auth/auth_sam.c   2007-06-05 23:35:39 UTC (rev 
23358)
@@ -163,7 +163,7 @@
                return NT_STATUS_ACCOUNT_EXPIRED;
        }
 
-       if (!(pdb_get_acct_ctrl(sampass) & ACB_PWNOEXP)) {
+       if (!(pdb_get_acct_ctrl(sampass) & ACB_PWNOEXP) && 
!(pdb_get_acct_ctrl(sampass) & ACB_PWNOTREQ)) {
                time_t must_change_time = 
pdb_get_pass_must_change_time(sampass);
                time_t last_set_time = pdb_get_pass_last_set_time(sampass);
 

Modified: branches/SAMBA_3_0_25/source/auth/auth_sam.c
===================================================================
--- branches/SAMBA_3_0_25/source/auth/auth_sam.c        2007-06-05 19:17:05 UTC 
(rev 23357)
+++ branches/SAMBA_3_0_25/source/auth/auth_sam.c        2007-06-05 23:35:39 UTC 
(rev 23358)
@@ -163,7 +163,7 @@
                return NT_STATUS_ACCOUNT_EXPIRED;
        }
 
-       if (!(pdb_get_acct_ctrl(sampass) & ACB_PWNOEXP)) {
+       if (!(pdb_get_acct_ctrl(sampass) & ACB_PWNOEXP) && 
!(pdb_get_acct_ctrl(sampass) & ACB_PWNOTREQ)) {
                time_t must_change_time = 
pdb_get_pass_must_change_time(sampass);
                time_t last_set_time = pdb_get_pass_last_set_time(sampass);
 

Modified: branches/SAMBA_3_0_26/source/auth/auth_sam.c
===================================================================
--- branches/SAMBA_3_0_26/source/auth/auth_sam.c        2007-06-05 19:17:05 UTC 
(rev 23357)
+++ branches/SAMBA_3_0_26/source/auth/auth_sam.c        2007-06-05 23:35:39 UTC 
(rev 23358)
@@ -163,7 +163,7 @@
                return NT_STATUS_ACCOUNT_EXPIRED;
        }
 
-       if (!(pdb_get_acct_ctrl(sampass) & ACB_PWNOEXP)) {
+       if (!(pdb_get_acct_ctrl(sampass) & ACB_PWNOEXP) && 
!(pdb_get_acct_ctrl(sampass) & ACB_PWNOTREQ)) {
                time_t must_change_time = 
pdb_get_pass_must_change_time(sampass);
                time_t last_set_time = pdb_get_pass_last_set_time(sampass);
 

Reply via email to