From 3bdcd5c8ce8ef9cc270e6dcf39ccf81484577bcd Mon Sep 17 00:00:00 2001 From: Jim McDonough Date: Wed, 3 Mar 2004 04:23:48 +0000 Subject: quick for for usrmgr. unknown_6 is really max dimension of logon hours array. need to update passdb for this. (This used to be commit 1d3079bf4c661939e291cca5e96157b5fa492340) --- source3/rpc_server/srv_samr_util.c | 42 +++++++++++--------------------------- 1 file changed, 12 insertions(+), 30 deletions(-) (limited to 'source3/rpc_server/srv_samr_util.c') diff --git a/source3/rpc_server/srv_samr_util.c b/source3/rpc_server/srv_samr_util.c index 706c893c92..ae0fe84e02 100644 --- a/source3/rpc_server/srv_samr_util.c +++ b/source3/rpc_server/srv_samr_util.c @@ -256,6 +256,12 @@ void copy_id21_to_sam_passwd(SAM_ACCOUNT *to, SAM_USER_INFO_21 *from) DEBUG(15,("INFO_21 LOGON_HRS.HOURS: %s -> %s\n",pdb_get_hours(to),from->logon_hrs.hours)); /* Fix me: only update if it changes --metze */ pdb_set_hours(to, from->logon_hrs.hours, PDB_CHANGED); + + /* This is max logon hours */ + DEBUG(10,("INFO_21 UNKNOWN_6: %08X -> %08X\n",pdb_get_unknown_6(to),from->unknown_6)); + if (from->unknown_6 != pdb_get_unknown_6(to)) { + pdb_set_unknown_6(to, from->unknown_6, PDB_CHANGED); + } } if (from->fields_present & ACCT_BAD_PWD_COUNT) { @@ -272,21 +278,6 @@ void copy_id21_to_sam_passwd(SAM_ACCOUNT *to, SAM_USER_INFO_21 *from) } } - /* if (from->fields_present & ACCT_??) { */ - DEBUG(10,("INFO_21 UNKNOWN_6: %08X -> %08X\n",pdb_get_unknown_6(to),from->unknown_6)); - if (from->unknown_6 != pdb_get_unknown_6(to)) { - pdb_set_unknown_6(to, from->unknown_6, PDB_CHANGED); - } - /* } */ - - DEBUG(10,("INFO_21 PADDING1 %02X %02X %02X %02X %02X %02X\n", - from->padding1[0], - from->padding1[1], - from->padding1[2], - from->padding1[3], - from->padding1[4], - from->padding1[5])); - DEBUG(10,("INFO_21 PASS_MUST_CHANGE_AT_NEXT_LOGON: %02X\n",from->passmustchange)); if (from->passmustchange==PASS_MUST_CHANGE_AT_NEXT_LOGON) { pdb_set_pass_must_change_time(to,0, PDB_CHANGED); @@ -512,6 +503,12 @@ void copy_id23_to_sam_passwd(SAM_ACCOUNT *to, SAM_USER_INFO_23 *from) DEBUG(15,("INFO_23 LOGON_HRS.HOURS: %s -> %s\n",pdb_get_hours(to),from->logon_hrs.hours)); /* Fix me: only update if it changes --metze */ pdb_set_hours(to, from->logon_hrs.hours, PDB_CHANGED); + + /* This is max logon hours */ + DEBUG(10,("INFO_23 UNKOWN_6: %08X -> %08X\n",pdb_get_unknown_6(to),from->unknown_6)); + if (from->unknown_6 != pdb_get_unknown_6(to)) { + pdb_set_unknown_6(to, from->unknown_6, PDB_CHANGED); + } } if (from->fields_present & ACCT_BAD_PWD_COUNT) { @@ -528,21 +525,6 @@ void copy_id23_to_sam_passwd(SAM_ACCOUNT *to, SAM_USER_INFO_23 *from) } } - /* if (from->fields_present & ACCT_??) { */ - DEBUG(10,("INFO_23 UNKOWN_6: %08X -> %08X\n",pdb_get_unknown_6(to),from->unknown_6)); - if (from->unknown_6 != pdb_get_unknown_6(to)) { - pdb_set_unknown_6(to, from->unknown_6, PDB_CHANGED); - } - /* } */ - - DEBUG(10,("INFO_23 PADDING1 %02X %02X %02X %02X %02X %02X\n", - from->padding1[0], - from->padding1[1], - from->padding1[2], - from->padding1[3], - from->padding1[4], - from->padding1[5])); - DEBUG(10,("INFO_23 PASS_MUST_CHANGE_AT_NEXT_LOGON: %02X\n",from->passmustchange)); if (from->passmustchange==PASS_MUST_CHANGE_AT_NEXT_LOGON) { pdb_set_pass_must_change_time(to,0, PDB_CHANGED); -- cgit