Q: While looking for proxies on proxy sites (for example on SamAir.ru), I see both HTTP and SOCKS proxies. What is the difference between those two? What type of proxies should I choose?
A: SOCKS is a protocol that allows nearly every type of application to be tunneled through it while HTTP is specialized for HTTP but can sometimes be used for other stuff as well.
Also, HTTP proxies can be used to increase or decrease the anonymity and privacy you gain through them as they can change parts of the content that is transmitted, SOCKS is just plain data transfer without adding or removing anything of the content transmitted.
SOCKS uses a handshake protocol to inform the proxy software about the connection that the client is trying to make and may be used for any form of TCP or UDP socket connection, whereas an HTTP proxy analyzes the HTTP headers sent through it in order to deduce the address of the server and therefore may only be used for HTTP traffic.
The following examples demonstrate the difference between the SOCKS and HTTP proxy protocols: [Via Wikipedia]
Bill wishes to communicate with Jane over the internet, but a firewall exists on his network between them, and Bill is not authorized to communicate through it himself. Therefore, he connects to the SOCKS proxy on his network and sends information about the connection he wishes to make to Jane. The SOCKS proxy opens a connection through the firewall and facilitates the communication between Bill and Jane.
Bill wishes to download a web page from Jane, who runs a web server. Bill cannot directly connect to Jane’s server, as a firewall has been put in place on his network. To communicate with the server, Bill connects to his network’s HTTP proxy. His internet browser communicates with the proxy in the same way it would the target server—it sends a standard HTTP request header. The HTTP proxy reads the request and looks for the Host header. It then connects to the server specified in the header and transmits any data the server replies with back to Bill.
In most cases configuring applications to use a SOCKS proxy is done in much the same way as configuring them to use HTTP proxies. Applications that support SOCKS proxies will have a separate entry in the menu or configuration dialogue where HTTP proxies are configured which let you configure a SOCKS proxy. Some applications will ask you to choose between SOCKS 4 and SOCKS 5 proxy settings, and in most cases SOCKS 5 is the better option, although some SOCKS proxies may only work with SOCKS 4.
You can think of SOCKS proxies as a more advanced version of HTTP proxies, that allow many different kinds of Internet traffic from many different protocols to be sent through a tunnel, thereby bypassing blocks.
As both types of proxies will hide your IP address, you should choose the type that is accepted by the application you need to anonymize. If both HTTP and SOCKS are available, I advise you to use SOCKS as they are faster.