Who is logged on Win2003 Server?

B

Brett

In task manager of Win2003 Server, I can see who is logged on. I want to
programmatically access this information. Is there a log file or something
I can access to get it?

Thanks,
Brett
 
H

Herfried K. Wagner [MVP]

Brett said:
In task manager of Win2003 Server, I can see who is logged on. I want to
programmatically access this information. Is there a log file or
something I can access to get it?

You can do that using p/invoke:

List of sessions on a system:

Platform SDK: Authentication -- Enumerating Logon Sessions
<URL:http://msdn.microsoft.com/library/en-us/secauthn/security/enumerating_logon_sessions.asp>

Information about each session:

Platform SDK: Authentication -- Retrieving Logon Session Information
<URL:http://msdn.microsoft.com/library/en-us/secauthn/security/retrieving_logon_session_information.asp>
 
B

Brett

That's not it:
"Gets the user name of the person who started the current thread."

I want all users logged onto the Win2003 server box via FTP for example.

Brett
 
B

Brett

Herfried K. Wagner said:
You can do that using p/invoke:

List of sessions on a system:

Platform SDK: Authentication -- Enumerating Logon Sessions
<URL:http://msdn.microsoft.com/library/en-us/secauthn/security/enumerating_logon_sessions.asp>

Information about each session:

Platform SDK: Authentication -- Retrieving Logon Session Information
<URL:http://msdn.microsoft.com/library/en-us/secauthn/security/retrieving_logon_session_information.asp>

If some one logs onto the box via say Serv-U (non IIS) FTP server, while the
above hold the user value some how?

Thanks,
Brett
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top