Hi, I'm using Sockets classes from this web site:
http://www.adp-gmbh.ch/win/misc/sockets.html
to create a very simple server
Is it possible to limit connections to my server to localhost only? (so not
accept any remote connections)
What would I have to do?
Frank Hickman - 12 Jan 2008 14:18 GMT
> Hi, I'm using Sockets classes from this web site:
> http://www.adp-gmbh.ch/win/misc/sockets.html
[quoted text clipped - 6 lines]
>
> What would I have to do?
Find the code that handles incoming connections and make sure the IP address
is 127.0.0.1. If it is, refuse the connection. You may possibly need to
also check the A name in some cases which would be anything other than
localhost.

Signature
============
Frank Hickman
NobleSoft, Inc.
============
Replace the _nosp@m_ with @ to reply.
Steve Alpert - 12 Jan 2008 21:41 GMT
> Hi, I'm using Sockets classes from this web site:
> http://www.adp-gmbh.ch/win/misc/sockets.html
[quoted text clipped - 5 lines]
>
> What would I have to do?
alternatively, when you create the server socket, bind it to 127.0.0.1 rather
than INADDR_ANY. That way, it isn't even seen by the outside!
/steveA