SOCKS embodies two components, the SOCKS Server (implemented at the application layer), and the SOCKS Client (implemented between the application and transport layers).
In essence, the purpose of the SOCKS protocol is to allow a host on one side of a SOCKS Server to interact with a host on the other side of the Server, subject to authentication, without passing IP packets directly between the two.
The SOCKS proxy server connects to the application server on behalf of the application client and relays data between the client and an application server. From the application server’s perspective, the SOCKS proxy is the client.