Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to install pureftpd under Debian

2025-03-28 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

This article mainly introduces how to install pureftpd under Debian, has a certain reference value, interested friends can refer to, I hope you can learn a lot after reading this article, the following let the editor take you to understand it.

1. Install (I am using unstable)

Apt-get install pure-ftpd pure-ftpd-common

two。 Establish a virtual user

I don't think it's a problem to set up ordinary users. It should be noted that now the configuration of pure-ftpd has changed, not to use pure-ftpd.conf to configure, but to use the way of pure-ftpd-wrapper, you can man pure-ftpd-wrapper to see, the main change is to turn each command in the original pure-ftpd.conf into a file with only one line of code, go to / etc/pure-ftpd/conf/ and see.

Now the configured pureftpd is started, but there are no available users to log in (anonymous login is not allowed by default). Therefore, with reference to README.Virtual-Users.gz, the virtual user is established as follows:

1) groupadd ftpgroup

Useradd-g ftpgroup-d / dev/null-s / etc ftpuser

This step is mainly to establish a system user for all virtual users.

2) then use the virtual user management command pure-pw to create a virtual user:

Pure-pw useradd joe-u ftpuser-d / home/ftpusers/joe A virtual user for joe is created here, and the home directory is under / home/ftpusers/joe. Changing-d to-D allows users to access the entire file system. There are a lot of things that can be set here, such as restricting access to ip,quota... You can then modify it with the pure-pw usermod command; delete the user pure-pw userdel joe.

3. Make virtual users effective

Create an authentication library with pure-pw mkdb and generate a pureftpd.pdb file under / etc/pure-ftpd/. The following steps need to be noted. I started out here for a long time: at this time, pure-ftpd does not know how to use pureftpd.pdb files for user authentication. Go to the / etc/pure-ftpd/auth directory and find that there are two files, 65unix and 70pam, inside. This is the authentication method used by pure-ftpd. You need to add a 60pdb link file to tell pure-ftpd to use pdb authentication, ln-s.. / conf/PureDB 60pdb. The 60 in front of 60pdb can also use other numbers less than 65, whatever you want. This number should be the order in which pure-ftpd chooses the authentication method, you can change it to 75pdb, and then look at:) you will find that logging in will be much slower. Without rebooting, you should be able to log in with joe. After each additional user, as long as add a-m can immediately take effect, pure-pw useradd newuser-m, there is no need to restart pure-ftpd.

4. A few questions

1) I changed / etc/pure-ftpd/conf/NoAnonymous to no, but not when logging in anonymously. Tell me "Unable to setup secure anonymous FTP". What's the reason? Are there any other settings?

2) how do virtual users set directory permissions? Because it is not a system user, it can not be set with chown,chmod?

I hope you will actively discuss and give us advice:)

The problem of not logging in anonymously has been solved.

You must create a user named ftp in the system, and of course change / etc/pure-ftpd/conf/NoAnonymous to no.

This is what I did: useradd ftp-g ftpgroup-d / yourftpdir-s / etc

Thank you for reading this article carefully. I hope the article "how to install pureftpd under Debian" shared by the editor will be helpful to everyone. At the same time, I also hope you will support us and pay attention to the industry information channel. More related knowledge is waiting for you to learn!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report