Is it possible to get the ip address for the login name?

  • Thread starter Thread starter rs
  • Start date Start date
R

rs

Hello everyone,

Is it possible to get the IP address of a machine on the network if we
know the windows login name. I am assuming NO. If anyone knows a work
around or how this can be done, please let me know
 
Can you ellaborate the need for that request? A user could logon on any
machine of your network.

- If the program is running on the machine where the user is logged, you can
know the IP address without needing the login name.

- If the program is running on a the server, maybe an event log entry is
generated on the server. For example an event log entry is certainly
generated on the client event log, Security group, with this info:

Inicio de sesión realizado:
Nombre de usuario: CarlosQ
Dominio: SOGECABLE
Id. de inicio de sesión: (0x0,0x193E7)
Tipo de inicio de sesión: 11
Proceso de inicio de sesión: User32
Paquete de autenticación: Negotiate
Nombre de estación de trabajo: WTC2I378OPDOSI
GUID de inicio de sesión: {00000000-0000-0000-0000-000000000000}

It is in Spanish but it says that CarlosQ logged on SOGECABLE domain using
machine WTC2I378OPDOSI. With the machine name you can get the IP address.

So, if that event is generated on the server too, you can monitor or query
its event log from your app.

--

Carlos J. Quintero

MZ-Tools 4.0: Productivity add-ins for Visual Studio .NET
You can code, design and document much faster.
http://www.mztools.com
 
Your best bet is to query the WINS server (assuming your network has one).
There is a free utility called NPING that does this. However, I have no
code.
 
Sorry for the confusion.
I am designing an internal chat program. I don't want to create another
program in the serverside to get the ip address of each user. I was
wondering if it is possible to know the ip address from the login name
of the user. I know that we can get the ip address from the computer
name but the user might sit on a different machine everyday.
 
Why not have the client machine send in the IP when the user logs into the
chat program? I can't think of an instance that the server needs to know
the user's IP if they don't have the chat program opened.

Just a thought
Chris
 
here is exactly what I am trying to do. I want clients to comunicate
with the IT department to give them support over chat in the company.
IT ppl do not have fixed computer and the users do not use the same
machine everyday. I was thinking if instead of having a program running
in the company server to get the ip address of everyone using that
program, i can find out the ip address of the user by the windows
loggin name.

Thanks
Ahmed
 
why not do this as a web page instead, then it becomes irrelevant which
computer they are using. Or better still, if you have citrix in your
company, put the app on that????

also, IIRC you can use a class to get the IP from the hostname? If not, it
is in the registry somewhere surely.
 
I forgot to mention that the ip address for the IT people is not static as
well.
 

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

Back
Top