Solved

Keep track of users logging on and off

Posted on 2004-10-19
2
530 Views
Last Modified: 2013-12-03
Hi,

I am trying to keep track of users logging on and off the system and also if they are idle for a certain of period of time.
Any idea?
Thanks.
0
Comment
Question by:ewong_111
2 Comments
 
LVL 86

Accepted Solution

by:
jkr earned 500 total points
ID: 12350877
You could simply write your own Winlogon Notification Package - see http://msdn.microsoft.com/library/default.asp?url=/library/en-us/secauthn/security/winlogon_notification_packages.asp ("Winlogon Notification Packages"). It basically boils down to creating a DLL that has the following functionality

//Event handler for the Winlogon Logon event
VOID WLEventLogon (PWLX_NOTIFICATION_INFO pInfo)
{
    //Print the name of the handler to debug output.
    //You can replace this with more useful functionality.
    OutputDebugString (TEXT("NOTIFY:  Entering WLEventLogon.\r\n"));
}

//Event handler for the Winlogon Logoff event.
VOID WLEventLogoff (PWLX_NOTIFICATION_INFO pInfo)
{
    //Print the name of the handler to debug output.
    //You can replace this with more useful functionality.
    OutputDebugString (TEXT("NOTIFY:  Entering WLEventLogff.\r\n"));
}

and is registered with the system under HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\Winlogon\Notify

DllName = mynotifdll.dll
Logon = "WLEventLogon"
Logoff = "WLEventLogoff"

NOTE that the function names are arbitrary.
0
 
LVL 2

Author Comment

by:ewong_111
ID: 12351071
Thanks a million.. you are always so quick and percise
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes how to add a user-defined command button to the Windows 7 Explorer toolbar.  In the previous article (http://www.experts-exchange.com/A_2172.html), we saw how to put the Delete button back there where it belongs.  "Delete" is …
In this article, I will show how to use the Ribbon IDs Tool Window to assign the built-in Office icons to a ribbon button.  This tool will help us to find the OfficeImageId that corresponds to our desired built-in Office icon. The tool is part of…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question