Difference between SOCKS4 and SOCKS5

2013/06/04 15:14

1. Definition of SOCKS

Protocol for sessions traversal across firewall securely. SOCKet Secure (SOCKS) is an Internet protocol that routes network packets between a client and server through a proxy server. SOCKS5 additionally provides authentication so only authorized users may access a server. Practically, a SOCKS server proxies TCP connections to an arbitrary IP address, and provides a means for UDP packets to be forwarded.SOCKS performs at Layer 5 of the OSI model (the session layer, an intermediate layer between the presentation layer and the transport layer).

2. Difference between SOCKS4 and SOCKS5

SOCKS4 and SOCKS5 both belong to SOCKS protocol. It is the concrete supportive application that distinguishes them.

SOCKS4 only supports TCP application, while SOCKS5 supports TCP and UDP applications. However, because of the fact that SOCKS5 also supports various authentication mechanisms and domain name resolution (DNS), which does not go with SOCKS4, the outgoing SOCKS proxy is normally SOCKS4 proxy. As a result, UDP applications are not supported normally. That is to say, SOCKS5 could support anything that SOCKS4 supports, but it is not the same with SOCKS4.

3. Application Cases

3.1 Downloading FTP Files via Browser Proxy

To download files in FTP servers, you have to input the IP address and the FTP Port 808 of the server in the "FTP" edit box (Figure 1-1).

Configure FTP Proxy

Figure 1‑1

3.2 Uploading FTP Files via Browser Proxy

1) To upload files to the FTP server, the "FTP" edit box has to be left blank, because IE would use the SOCKS4 protocol (Figure 1-2).

Leave FTP Blank

Figure 1‑2

2) Open the "Local Area connection Properties" dialogue box, click "Internet Protocol Version 4 (TCP/IPv4)", then click the "Properties" button (Figure 1-3).

TCP/IPv4

Figure 1‑3

3) In the pop up "Internet Protocol Version 4 (TCP/IPv4) Properties" dialogue box, select the "User the following DNS server address" radio button, and then type the DNS address in the "Preferred DNS server" edit box (Figure 1-4).

Configure DNS Address

Figure 1‑4

4) After configured like that, you could use browsers to upload files to the FTP server.



Related: