Bug 158334 - WinSync Console: Handling of logonHours and accountExpires incorrect.
WinSync Console: Handling of logonHours and accountExpires incorrect.
Status: CLOSED CURRENTRELEASE
Product: Red Hat Directory Server
Classification: Red Hat
Component: UI - Configuration (Show other bugs)
7.1
All Linux
low Severity medium
: DS8.1
: ---
Assigned To: Rich Megginson
Chandrasekar Kannan
:
Depends On:
Blocks: 249650 FDS1.2.0
  Show dependency treegraph
 
Reported: 2005-05-20 12:53 EDT by Thomas E Lackey
Modified: 2015-01-04 18:18 EST (History)
5 users (show)

See Also:
Fixed In Version: 8.1
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-04-29 18:57:48 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
diffs (4.98 KB, patch)
2008-12-10 21:03 EST, Rich Megginson
no flags Details | Diff
never expires (40.97 KB, image/jpeg)
2008-12-10 21:04 EST, Rich Megginson
no flags Details
expires with date (41.91 KB, image/jpeg)
2008-12-10 21:04 EST, Rich Megginson
no flags Details
ADUtil.java (2.50 KB, text/plain)
2008-12-10 21:08 EST, Rich Megginson
no flags Details
fixed diffs (4.30 KB, patch)
2008-12-16 15:46 EST, Rich Megginson
no flags Details | Diff
more fixed diffs (4.39 KB, patch)
2008-12-16 18:18 EST, Rich Megginson
no flags Details | Diff
new ADUtil.java (2.69 KB, text/plain)
2008-12-16 18:18 EST, Rich Megginson
no flags Details
cvs commit log (784 bytes, text/plain)
2008-12-16 18:32 EST, Rich Megginson
no flags Details

  None (edit)
Description Thomas E Lackey 2005-05-20 12:53:56 EDT
Description of problem:

The handling of the logonHours and accountExpires attributes by the console is
incorrect.  David took a look, and assuming I relay this accurately, the console
is basing its time calculations off time_t while AD and the NT4 sync service
expect dates referenced off FILETIME.

How reproducible:
Always.

Steps to Reproduce:
1. Configure WinSync
2. Create a user and adjust their logon hours and account expiration on the
Windows side.
3. Open the DS console and use the wizards to view the values.  They will be
incorrect.
4. Change the values in the DS console.
5. Open the users in the Windows side and view those values.  They will be now
be incorrect.
  
Actual results:
The times input using the console are not accurate.

Expected results:
The times should match.

Additional info:
This is a problem in the way the console calculates the value and not a problem
in the DS's handling of the attributes.
Comment 1 Rich Megginson 2005-05-20 13:57:55 EDT
FILETIME is in 100's of nanoseconds since 1/1/1601.
Comment 7 Rich Megginson 2008-12-10 21:03:57 EST
Created attachment 326572 [details]
diffs
Comment 8 Rich Megginson 2008-12-10 21:04:31 EST
Created attachment 326573 [details]
never expires
Comment 9 Rich Megginson 2008-12-10 21:04:54 EST
Created attachment 326574 [details]
expires with date
Comment 10 Rich Megginson 2008-12-10 21:08:10 EST
Created attachment 326575 [details]
ADUtil.java
Comment 11 Rich Megginson 2008-12-16 15:46:04 EST
Created attachment 327161 [details]
fixed diffs
Comment 12 Rich Megginson 2008-12-16 18:18:15 EST
Created attachment 327182 [details]
more fixed diffs
Comment 13 Rich Megginson 2008-12-16 18:18:45 EST
Created attachment 327183 [details]
new ADUtil.java
Comment 14 Rich Megginson 2008-12-16 18:32:40 EST
Created attachment 327184 [details]
cvs commit log

Reviewed by: nhosoi (Thanks!)
Files: new file ADUtil.java
Fix Description: Added code to convert from Windows FILETIME to Java
time.  Added special handling for the "Never Expires" value, which can
be the very large value or 0.  The console now displays "Never Expires"
or the actual human readable value for the time.
As far as Logon Hours, it's just really messed up.  I will open another
bug for that.
https://bugzilla.redhat.com/attachment.cgi?id=326573 - never expires
https://bugzilla.redhat.com/attachment.cgi?id=326574 - expires with date
Platforms tested: RHEL5
Flag Day: no
Doc impact: yes
Comment 15 Jenny Galipeau 2009-02-27 10:19:27 EST
I'm not sure what was really fixed here.  Can you be more specific?  It still seems pretty screwed up.  Thanks Jenny
Comment 16 Rich Megginson 2009-02-27 12:02:59 EST
(In reply to comment #15)
> I'm not sure what was really fixed here.  Can you be more specific?  It still
> seems pretty screwed up.  Thanks Jenny

Account Expires handling should be correct now.  Logon Hours is still messed up - there is another bug for that (for a later release, not for this one).  So I guess for this bug, just verify that Account Expires is handled correctly.
Comment 17 Jenny Galipeau 2009-03-12 10:31:38 EDT
Account Expires -
Fix Verified DS 8.1 RHEL5 - Windows Synchronization 1.1.0
Comment 18 Chandrasekar Kannan 2009-04-29 18:57:48 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHEA-2009-0455.html

Note You need to log in before you can comment on or make changes to this bug.