Proxies are handy tools you can use to perform many practical tasks. Proxies have an use on the business side to prevent access or intrusion into internal networks, but there are plenty of applications for them on the personal side too. For example, it is well-known that you could use a proxy on your computer to bypass geo-restrictions from websites and services or to mask your identity, boosting your privacy online.
As we all know, a proxy server acts as a middleman between your connection and the internet. SOCKS5, in particular, has the advantage of having authentication mechanisms for said connections, adding a nice extra layer of protection to any activity you wish to do online. In addition to this, bandwidth control and content filtering and blocking are some of the other advantages you can get after setting a proxy on your server.
How To Set Up a SOCKS5 Proxy in Ubuntu Using Squid
Whether on your home or office network, setting up a proxy can be helpful. In this article, we will be talking briefly about how you can easily configure one in an Ubuntu Linux installation.
Understanding the Basics
Linux is a family of open-source operating systems based on the Linux kernel. They are Unix-like operating systems and the most notable example of a successful and long-running free and open-source collaboration in the software world. One of their defining characteristics is that their source code is free to be used, modified, and distributed in both a commercial and non-commercial way. It is one of the most popular operating systems out there, alongside Windows and macOS.
Unlike the other two, though, Linux has a ton of variants and "flavors" out there. One of these flavors is the ever-popular Ubuntu, a Linux distribution based on Debian (another Linux distro) and one that hosts a variety of applications for everyday use. Ubuntu is quite probably the most popular and far-extended of the Linux distributions. It has a user base of millions worldwide, and when it comes to running web servers, it is hands-down the definitive choice due to its top performance and its array of security options.
Among the thousands of different applications that we can use on Ubuntu Linux, we have Squid. Squid is a caching proxy tool that supports HTTP, HTTPS, FTP, and several other protocols. It is an application designed to reduce bandwidth usage and improve the response time of servers by making use of caching and re-using.
Now that we know the basics. Let's move on to the two paths we can follow to set up our SOCKS5 proxy in this setup.
Set Up a SOCKS5 Proxy via GUI
GUI stands for Graphical User Interface. This is the form of interface preferred by most PC users as it entails interacting through graphical icons and sound cues instead of having to use text-based commands. Without a doubt, it's the easiest way to install our proxy server in Ubuntu. Here's how:
- Go to System Settings in your Ubuntu installation.
- Head over to Network and then into the Network proxy option.
- There will be a drop-down list, here you will choose Manual.
- After this, you will need to provide the details of your proxy, such as hostname, IP address, and port number.
- Once done, click on Apply system-wide to apply the changes.
And presto! Your proxy is now set.
Set Up a SOCKS5 Proxy via Command Line
Everybody loves command lines, or at least that is what the computer junkies will lead you to believe. Just kidding. Command lines are the go-to method for the most tech-savvy individuals to interact with their machines. It is the "old school" way of doing things but still a method that confers several advantages depending on who you ask. It requires a bit of learning that most entry-level users don't often want to try.
Once you have your console of choice, these are the steps you will have to follow to install Squid:
First, update your system by using the following command.
- ubuntu@ubuntu:~$ sudo apt update
Once everything is up to date, type the following command to get the Squid package.
- ubuntu@ubuntu:~$ sudo apt -y install squid
After the installation finishes, you can run and check on the status of your Squid proxy by using these two commands
- ubuntu@ubuntu:~$ sudo service squid start
- ubuntu@ubuntu:~$ sudo service squid status
As you can see, these are the two methods we can use to install Squid on Ubuntu Linux and make use of a SOCKS5 proxy. The process is very simple and hard to miss. Squid itself is a powerful tool that you can use to control web traffic and internet access, all while boosting browsing speeds thanks to its caching mechanism.