
Re: how would you find the host name for a remote computer based on logon id
"J" <anonymous@discussions.microsoft.com> wrote in message news:<16a7101c417c3$7ed052e0$a501280a@phx.gbl>...
> I need to know how you would find an ip address / host
> name for a remote computer within my domain based on the
> current user loged on. ie, what is the ip address for
> user "bob's" computer.
I am not in a place where I can check this. But it may be possible
by using WINS.
When a user logs on to a Windows computer, his/her user ID is
registered as a NetBIOS name on the computer's adapter using the
suffix <03> as the 16th character (it is blank filled between the
last character of the ID and the suffix). This is done for the
messenger service (so you can "net send" to the UserID)
NetBIOS names are registered in WINS. There is a "check name"
subcommand in Netsh for WINS:
netsh wins server check name
that looks like it will return the IP address of the adapter
the name is registered to. Unfortuately I am not in a place I
can test this.
Note: this is a unique name and only one will exist on the network.
So if the user is logged on several places, only one will show up.
Plan B. create/modify the logon script to write a file. Put it in
a known location with a name based on the userid. Write the IP address
and host name where the user is logging on from as the contents.
Plan C. AD keeps track of the last logon time and logoff times.
Perhaps the schema could be modified to keep track of the last
computer the ID logged on from as well.
--
Matt Hickman
His clothes looked like a cross between a Harlem Sunday and a
picnic. (Dan Davis describing a doctor's attire in the year 2000)
Robert A. Heinlein (1907 - 1988)
_The Door Into Summer_ 1956