This is the mail archive of the cygwin-xfree@cygwin.com mailing list for the Cygwin XFree86 project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

how to get source ip of a telnet session


Greetings:

We need a method of learning the ip address of the client in a telnet
session to a Win2k Server SP3 host; the information will be used in
the user's ~/.profile to set the DISPLAY variable prior to starting
an X session.

On Unix one may use 'lsof' (if available) and grep on the shell pid and
file descriptor 0 to find the line containing the source ip addr. In
some flavors of Unix the /proc filesystem can also be of help.

We're currently using the native Windows Telnet Server; 'tlntadmn.exe'
can interactively show connections and provide a SESSION ID crossed
to the ip address; one could conceivably cross the SESSION ID to
the bash pid but the 'tlntadmn' tool isn't well documented and doesn't
seem to accept arguments so it is useless in scripts.

All suggestions much appreciated.

Michael Grigoni
Cybertheque Museum


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]