How to open socket thru proxy server in .Net C#?
So I opened up a socket on my machin. there are no nats between pe and proxy server. I connected to proxy server. Ho
You cannot open a socket 'thru' something, only 'to' something. With proxy server (I assume you're talking about HTTP proxy that supports 'CONNECT' command) it's the same: first open a connection to it, then use its protocol to make proxy forward your connection where you want to using 'CONNECT' command.
So you need to do the following steps:
CONNECT Host:Port HTTP/1.1<CR><LF>
<CR><LF>
HTTP/1.X 200
, the connection is successful.