darkforcesjedi
Newcomer
- Joined
- Jun 12, 2003
- Messages
- 8
Ok...here's what I'm trying to do...
I'm trying to write a SOCKS4-type proxy with a console interface to display status information. (e.g. I would type connections at the prompt and get a list of connected clients). I've never written a network application before, but the logic seems simple enough. I found some sample code that listens for a TCP connection. The first packet I get from the client is to negotiate a connection. I get the target IP address and port number from the client.
I don't know what to do next. I presume I need to open a connection with the server. I tried this (I used reverse DNS to get the hostname from the IP address, which is probably bad because some reverse DNS lookups will probably fail):
'this always times out
target = New System.Net.Sockets.TcpClient(EndHost, EndPort)
I searched google and planet source code supposedly has a sample proxy server in VB.NET, but I can't get to the site.
I'm trying to write a SOCKS4-type proxy with a console interface to display status information. (e.g. I would type connections at the prompt and get a list of connected clients). I've never written a network application before, but the logic seems simple enough. I found some sample code that listens for a TCP connection. The first packet I get from the client is to negotiate a connection. I get the target IP address and port number from the client.
I don't know what to do next. I presume I need to open a connection with the server. I tried this (I used reverse DNS to get the hostname from the IP address, which is probably bad because some reverse DNS lookups will probably fail):
'this always times out
target = New System.Net.Sockets.TcpClient(EndHost, EndPort)
I searched google and planet source code supposedly has a sample proxy server in VB.NET, but I can't get to the site.