Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I need to write code (C# or Java) to retrieve user logon/logoff information from ADAM, but i'm not sure where to start or if it's even possible.

share|improve this question
add comment

2 Answers 2

up vote 4 down vote accepted

There is a lastLogonTimeStamp attribute in AD that will give you this information. However to have this attribute your domain must be at least Windows Server 2003 Domain Functional Level. Just because you have 2003 DC's, don't assume that your DFL has been raised to that level if you are having problems getting this attribute.

Sam

share|improve this answer
add comment

I think there are is a attribute called lastLogon, but i dont remember ever seeing one for logoff time

share|improve this answer
    
You may prefer to look at lastLogonTimeStamp as lastLogon is not replicated. –  jscott Jun 3 '11 at 9:56
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.