How to Install ProFTPD on Debian 11 Server (Step by Step)

How to Install ProFTPD on Debian 11 Server (Step by Step). In this post, we show you what is ProFTPD, its advantages then explain how to install ProFTPD server on Debian 11.

What is ProFTPD?

The ProFTPD server is a free FTP server that is used as either standalone or as a module for other programs. The ProFTPD server is designed to be fast, secure, and extremely configurable.

Wu-ftpd was the most widely utilized server when the project got started but lacked various features and had a poor security history. Many individuals, including the ProFTPD developers, had invested a lot of time in wu-ftpd, resolving bugs, and adding capabilities. Sadly, it soon became apparent that a complete redesign was required in order to add the requisite configurability and functionalities.

ProFTPD is a standalone source tree that was built from the bottom up. It runs on various platforms, including SCO, OpenBSD, AIX, Linux, Mac OS X, NetBSD, Solaris, etc. In fact, Slackware, SourceForge, Duno, Linksys, and many high traffic sites trust ProFTPD.

In addition to supporting the RFC 959 defined FTP protocol, proFTPD servers also feature numerous advanced features, including Apache style configuration files, the ability to cloak files and directories, resume interrupted downloads, and file and directory aliases.

Compared with others that are focused, for instance, on simplicity, speed, or security, the main purpose of the design of ProFTPD is to be a very capable FTP server, which exposes the user to a wide range of configuration options. Some FTP servers, like Spiceworks and SolarWinds, are part of full featured network management tools. Some FTP servers, such as ProFTPd, require that you turn on the option NoSessionReuseRequired if you are using Transport Layer Security (TLS) mode, a successor to Secure Socket Layer (SSL).

Features of ProFTPD server

  • Any administrator who has used the Apache web server will recognize the single main configuration file’s directives and directive groups.
  • Offers Per directory “.ftpaccess” configuration
  • Host Unix system’s capabilities are necessary to run ProFTPD in stand alone mode.
  • Offers modularity and IPv6 support

Advantages of ProFTPD server

  • ProFTPD server does not support SITE EXEC command as it is a security nightmare in the modern internet environment.
  • Depending on the system load, users run either as a standalone server or from inetd/xinetd.
  • ProFTPD allows for hiding directories and files by using ownership by users/groups and Unix style permissions.
  • Setting up ProFTPD is easy, and sample configuration files are easy to find on the web.
  • Developers and administrators have full access to the source code for auditing.
  • To reduce attacks that could make use of its “root” capabilities, ProFTPD runs in stand alone mode as a programmable non privileged user.
  • Design that is easily extensible using modules.
  • Compatible with various platforms including SCO, OpenBSD, AIX, Linux, Mac OS X, NetBSD, Solaris, etc.
  • Users easily check how much bandwidth your FTP sessions are using via ProFTPD.

We have arrived to the installation phase of How to Install ProFTPD on Debian 11 Server.

How to Install ProFTPD on Debian 11 Server (Step by Step)

In this section, we show you how to install ProFTPD server with SSL/TLS support on Debian 11 server.

Prerequisites

  • A Debian server installed on your server.
  • A root user or a user with sudo privileges.

Step 1 - Getting Started

First, log in to your server and update all the system packages to the latest version using the following command.

				
					apt update -y
apt upgrade -y
				
			

After updating all the packages, you can proceed to install ProFTPD server.

Step 2 - Install ProFTPD Server

By default, the PoFTPD server is available in the Debian default repository. So, you install it easily by just running the following command.

				
					apt install proftpd -y
				
			

Once the ProFTPD server is installed, you can start the ProFTPD service with the following command.

				
					systemctl start proftpd
				
			

Now, verify the active status of the ProFTPD service with the following command.

				
					systemctl status proftpd
				
			

You should see the following output.

				
					● proftpd.service - ProFTPD FTP Server
     Loaded: loaded (/lib/systemd/system/proftpd.service; enabled; vendor preset: enabled)
     Active: active (running) since Thu 2022-12-29 13:07:47 UTC; 4s ago
   Main PID: 1062 (proftpd)
      Tasks: 1 (limit: 2337)
     Memory: 3.6M
        CPU: 52ms
     CGroup: /system.slice/proftpd.service
             └─1062 proftpd: (accepting connections)

Dec 29 13:07:47 debian11 systemd[1]: Starting ProFTPD FTP Server...
Dec 29 13:07:47 debian11 proftpd[1060]: Checking syntax of configuration file
Dec 29 13:07:47 debian11 systemd[1]: proftpd.service: Can't open PID file /run/proftpd.pid (yet?) after start: Operation not permitted
Dec 29 13:07:47 debian11 systemd[1]: Started ProFTPD FTP Server.

				
			

Now, the ProFTPD server is installed and listens on port 21. You can check the listening port using the following command.

				
					ss -antpl | grep proftpd
				
			

You should see the ProFTPD listening port in the following output.

				
					LISTEN 0      128                *:21              *:*    users:(("proftpd",pid=1062,fd=0))
				
			

Step 3 - Create ProFTPD User

Now, you need to create a FTP user to test the ProFTPD server. To create a new user named ftpuser, run the following command.

				
					adduser ftpuser
				
			

Set your user’s password as shown below:

				
					Adding user `ftpuser' ...
Adding new group `ftpuser' (1001) ...
Adding new user `ftpuser' (1001) with group `ftpuser' ...
Creating home directory `/home/ftpuser' ...
Copying files from `/etc/skel' ...
New password: 
Retype new password: 
passwd: password updated successfully
Changing the user information for ftpuser
Enter the new value, or press ENTER for the default
	Full Name []: 
	Room Number []: 
	Work Phone []: 
	Home Phone []: 
	Other []: 
Is the information correct? [Y/n] 

				
			

After creating an FTP user, log in with ftpuser with the following command.

				
					su - ftpuser
				
			

Next, create some files and directories with the following command.

				
					mkdir folder1 folder2 
touch testing1 testing2
				
			

Then, exit from the ftpuser with the following command.

				
					exit
				
			

Step 4 - Configure ProFTPD Server

The /etc/proftpd/proftpd.conf is the only configuration file that ProFTPD typically utilizes. Each directive in this file typically consists of a single line with a name and a value. Each directive sets a single customizable parameter, such as the location of a welcome message or the name of a hidden file. Additionally, there are special container directives for bundling other directives that span numerous lines but only apply to one virtual server or directory.

Next, you will need to edit the ProFTPD default configuration file and change the default settings.

				
					nano /etc/proftpd/proftpd.conf
				
			

Change the following settings.

				
					ServerName Debian11
UseIPV6 on
Port 21
SystemLog /var/log/proftpd/proftpd.log
DefaultRoot ~
				
			

Next, add the following lines at the end of the file.

				
					<Directory /home/ftpuser>
  Umask 022 
  AllowOverwrite off
  <Limit LOGIN>
    AllowUser ftpuser
    DenyAll
  </Limit>
  <Limit ALL>
    AllowUser ftpuser
    DenyAll
  </Limit>
</Directory>
				
			

Save and close the file when you are done. Then, restart the ProFTPD service to apply the changes.

				
					systemctl restart proftpd
				
			

Step 5 - Access FTP Via Command Line

In this section, we show you how to connect the ProFTPD server via command line client. First, log in to the remote Linux machine, open your command line interface and run the following command to connect the ProFTPD server.

				
					ftp ftp-server-ip
				
			

You will be asked to provide your FTP username and password as shown below.

				
					Connected to ftp-server-ip.
220 ProFTPD Server (debian11) [::ffff:ftp-server-ip]
Name (ftp-server-ip:vyom): ftpuser
331 Password required for ftpuser
Password:

				
			

Once you are log in to the FTP server, you will get in to the FTP shell as shown below.

				
					230 User ftpuser logged in
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> 
				
			

Now, verify your files and directories which you have created in previous step using the following command.

				
					ftp> ls 
				
			

You should see the following output.

				
					drwxr-xr-x 2 ftpuser ftpuser 4096 Dec 29 13:08 folder1
drwxr-xr-x 2 ftpuser ftpuser 4096 Dec 29 13:08 folder2
-rw-r--r-- 1 ftpuser ftpuser    0 Dec 29 13:08 testing1
-rw-r--r-- 1 ftpuser ftpuser    0 Dec 29 13:08 testing2
				
			

Step 6 - Configure ProFTPD with SSL/TLS Support

It is a good idea to secure the ProFTPD FTP server with SSL/TLS to encrypt the traffic. First, install the SSL tool with the following command.

				
					apt-get install openssl -y
				
			

Next, generate an SSL certificates with the following command.

				
					openssl req -x509 -newkey rsa:1024 -keyout /etc/ssl/private/proftpd.key -out /etc/ssl/certs/proftpd.crt -nodes -days 365
				
			

Provide all certificate information as shown below.

				
					Generating a RSA private key
............................+++++
................................................................+++++
writing new private key to 'https://net.cloudinfrastructureservices.co.uk/etc/ssl/private/proftpd.key'
-----
You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter '.', the field will be left blank.
-----

Country Name (2 letter code) [AU]:US
State or Province Name (full name) [Some-State]:NJ
Locality Name (eg, city) []:server
Organization Name (eg, company) [Internet Widgits Pty Ltd]:EDU
Organizational Unit Name (eg, section) []:IT
Common Name (e.g. server FQDN or YOUR name) []:server
Email Address []:admin@example.com

				
			

Then, set proper permission on the generated certificates with the following command.

				
					chmod 600 /etc/ssl/private/proftpd.key
chmod 600 /etc/ssl/certs/proftpd.crt
				
			

After that, edit the ProFTPD configuration file and define the path of the TLS configuration file.

				
					nano /etc/proftpd/proftpd.conf
				
			

Add the following line.

				
					Include /etc/proftpd/tls.conf
				
			

Save and close the file then edit the TLS configuration file.

				
					nano /etc/proftpd/tls.conf
				
			

Define your TLS certificates and other configuration as shown below:

				
					TLSRSACertificateFile /etc/ssl/certs/proftpd.crt
TLSRSACertificateKeyFile /etc/ssl/private/proftpd.key
TLSEngine on
TLSLog /var/log/proftpd/tls.log
TLSProtocol SSLv23
TLSRequired on
TLSOptions NoCertRequest EnableDiags NoSessionReuseRequired
TLSVerifyClient off

				
			

Save and close the file then restart the ProFTPD service to apply the changes.

				
					systemctl restart proftpd
				
			

Once you are done, you can proceed to access the ProFTPD via GUI.

Step 7 - Access ProFTPD via FileZilla FTP Client

There are lots of FTP client available that helps you to access your FTP server via GUI interface. Here, we will connect ProFTPD server via FileZilla graphical FTP client.

A). First, install the FileZilla client on your remote machine and open it as shown below.

B). Next, click on create new connection. You should see the FTP connection page.

C). Provide your FTP IP, username, password and click on the connect button. Once you are connected to the FTP server, you should see your files and directories on the following page.

Thank you for reading How to Install ProFTPD on Debian 11 Server. We shall conclude this article blog. 

How to Install ProFTPD on Debian 11 Server (Step by Step) Conclusion

Congratulations! You have successfully installed ProFTPD FTP server on Debian 11 server. ProFTPD is a flexible, secure, and extremely configurable server that has the ability to run in different modes. It has a similar configuration file format and user interface to Apache. It supports virtual FTP servers, IPv6, logging, utmp/wtmp, etc.

ProFTPD server has some features that make it more secure and efficient than other FTP servers. This software runs on Unix like systems such as Linux, FreeBSD, and Solaris, as well as Microsoft Windows NT 4.0 and later versions of Microsoft Windows including Windows XP, Vista, 7, 8, and 10.

Feel free to explore more of our FTP content by navigating to our blog over here

Avatar for Hitesh Jethva
Hitesh Jethva

I am a fan of open source technology and have more than 10 years of experience working with Linux and Open Source technologies. I am one of the Linux technical writers for Cloud Infrastructure Services.

0 0 votes
Article Rating
Subscribe
Notify of
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x