Newsgroups : Borland : borland.public.delphi.internet.winsock : 2006 Apr : Re: tidcmdserver localname/hostname D7/indy 10.1.5
| Subject: | Re: tidcmdserver localname/hostname D7/indy 10.1.5 |
| Posted by: | "Remy Lebeau (TeamB)" (no.spam@no.spam.com) |
| Date: | Mon, 17 Apr 2006 11:07:55 |
"Jacques Noah" <jacques.noah@btinternet.com> wrote in message
news:44437d1f$1@newsgroups.borland.com...
> i seem to remember that you could get the names by
> doing something like 'AConnection.LocalName'
That is not correct. In order to get the name of a remote machine, you must
perform a reverse DNS query, for example:
var RemoteName: String;
with AContext.Connection.Socket.Binding do
RemoteName := GStack.HostByAddress(PeerIP, IPVersion);
In Indy 9, it was the following instead:
RemoteName :=
GStack.WSGetHostByAddr(AThread.Connection.Socket.Binding.PeerIP);
> since upgrading to indy10.1.5, i cannot find this property.
That property has not existed in any version of Indy 10. Nor did it ever do
what you are asking for to begin with. The LocalName property returned
exactly what its name suggests - the *local* name of the server itself, not
the name of any of the *remote* (aka *peer*) clients.
Gambit