|
|
d7fdbd |
From fff93602a4b252be8d674e27083dde68a7acf038 Mon Sep 17 00:00:00 2001
|
|
|
d7fdbd |
From: Martin Sehnoutka <msehnout@redhat.com>
|
|
|
d7fdbd |
Date: Tue, 6 Sep 2016 13:46:03 +0200
|
|
|
d7fdbd |
Subject: [PATCH 04/59] Use /etc/vsftpd/ dir for config files instead of /etc.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
---
|
|
|
d7fdbd |
EXAMPLE/INTERNET_SITE/README | 6 +++---
|
|
|
d7fdbd |
EXAMPLE/INTERNET_SITE_NOINETD/README | 4 ++--
|
|
|
d7fdbd |
EXAMPLE/PER_IP_CONFIG/README | 4 ++--
|
|
|
d7fdbd |
EXAMPLE/VIRTUAL_USERS/README | 14 +++++++-------
|
|
|
d7fdbd |
FAQ | 8 ++++----
|
|
|
d7fdbd |
INSTALL | 10 +++++-----
|
|
|
d7fdbd |
README | 5 +++++
|
|
|
d7fdbd |
defs.h | 2 +-
|
|
|
d7fdbd |
tunables.c | 10 +++++-----
|
|
|
d7fdbd |
vsftpd.8 | 10 +++++-----
|
|
|
d7fdbd |
vsftpd.conf | 20 +++++++++++++-------
|
|
|
d7fdbd |
vsftpd.conf.5 | 22 +++++++++++-----------
|
|
|
d7fdbd |
12 files changed, 63 insertions(+), 52 deletions(-)
|
|
|
d7fdbd |
|
|
|
d7fdbd |
diff --git a/EXAMPLE/INTERNET_SITE/README b/EXAMPLE/INTERNET_SITE/README
|
|
|
d7fdbd |
index 12b10a5..fe3d7ca 100644
|
|
|
d7fdbd |
--- a/EXAMPLE/INTERNET_SITE/README
|
|
|
d7fdbd |
+++ b/EXAMPLE/INTERNET_SITE/README
|
|
|
d7fdbd |
@@ -41,13 +41,13 @@ no_access = 192.168.1.3
|
|
|
d7fdbd |
As an example of how to ban certain sites from connecting, 192.168.1.3 will
|
|
|
d7fdbd |
be denied access.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-banner_fail = /etc/vsftpd.busy_banner
|
|
|
d7fdbd |
+banner_fail = /etc/vsftpd/busy_banner
|
|
|
d7fdbd |
|
|
|
d7fdbd |
This is the file to display to users if the connection is refused for whatever
|
|
|
d7fdbd |
reason (too many users, IP banned).
|
|
|
d7fdbd |
|
|
|
d7fdbd |
Example of how to populate it:
|
|
|
d7fdbd |
-echo "421 Server busy, please try later." > /etc/vsftpd.busy_banner
|
|
|
d7fdbd |
+echo "421 Server busy, please try later." > /etc/vsftpd/busy_banner
|
|
|
d7fdbd |
|
|
|
d7fdbd |
log_on_success += PID HOST DURATION
|
|
|
d7fdbd |
log_on_failure += HOST
|
|
|
d7fdbd |
@@ -62,7 +62,7 @@ Step 2) Set up your vsftpd configuration file.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
An example file is supplied. Install it like this:
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-cp vsftpd.conf /etc
|
|
|
d7fdbd |
+cp vsftpd.conf /etc/vsftpd
|
|
|
d7fdbd |
|
|
|
d7fdbd |
Let's example the contents of the file:
|
|
|
d7fdbd |
|
|
|
d7fdbd |
diff --git a/EXAMPLE/INTERNET_SITE_NOINETD/README b/EXAMPLE/INTERNET_SITE_NOINETD/README
|
|
|
d7fdbd |
index ce17af2..9198c5f 100644
|
|
|
d7fdbd |
--- a/EXAMPLE/INTERNET_SITE_NOINETD/README
|
|
|
d7fdbd |
+++ b/EXAMPLE/INTERNET_SITE_NOINETD/README
|
|
|
d7fdbd |
@@ -17,7 +17,7 @@ even per-connect-IP configurability.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
To use this example config:
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-1) Copy the vsftpd.conf file in this directory to /etc/vsftpd.conf.
|
|
|
d7fdbd |
+1) Copy the vsftpd.conf file in this directory to /etc/vsftpd/vsftpd.conf.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
2) Start up vsftpd, e.g.
|
|
|
d7fdbd |
vsftpd &
|
|
|
d7fdbd |
@@ -51,5 +51,5 @@ in the vsftpd.conf:
|
|
|
d7fdbd |
listen_address=192.168.1.2
|
|
|
d7fdbd |
|
|
|
d7fdbd |
And launch vsftpd with a specific config file like this:
|
|
|
d7fdbd |
-vsftpd /etc/vsftpd.conf.site1 &
|
|
|
d7fdbd |
+vsftpd /etc/vsftpd/vsftpd.conf.site1 &
|
|
|
d7fdbd |
|
|
|
d7fdbd |
diff --git a/EXAMPLE/PER_IP_CONFIG/README b/EXAMPLE/PER_IP_CONFIG/README
|
|
|
d7fdbd |
index a9ef352..34924d5 100644
|
|
|
d7fdbd |
--- a/EXAMPLE/PER_IP_CONFIG/README
|
|
|
d7fdbd |
+++ b/EXAMPLE/PER_IP_CONFIG/README
|
|
|
d7fdbd |
@@ -20,12 +20,12 @@ directory: hosts.allow. It lives at /etc/hosts.allow.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
Let's have a look at the example:
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-vsftpd: 192.168.1.3: setenv VSFTPD_LOAD_CONF /etc/vsftpd_tcp_wrap.conf
|
|
|
d7fdbd |
+vsftpd: 192.168.1.3: setenv VSFTPD_LOAD_CONF /etc/vsftpd/tcp_wrap.conf
|
|
|
d7fdbd |
vsftpd: 192.168.1.4: DENY
|
|
|
d7fdbd |
|
|
|
d7fdbd |
The first line:
|
|
|
d7fdbd |
If a client connects from 192.168.1.3, then vsftpd will apply the vsftpd
|
|
|
d7fdbd |
-config file /etc/vsftpd_tcp_wrap.conf to the session! These settings are
|
|
|
d7fdbd |
+config file /etc/vsftpd/tcp_wrap.conf to the session! These settings are
|
|
|
d7fdbd |
applied ON TOP of the default vsftpd.conf.
|
|
|
d7fdbd |
This is obviously very powerful. You might use this to apply different
|
|
|
d7fdbd |
access restrictions for some IPs (e.g. the ability to upload).
|
|
|
d7fdbd |
diff --git a/EXAMPLE/VIRTUAL_USERS/README b/EXAMPLE/VIRTUAL_USERS/README
|
|
|
d7fdbd |
index b48995d..72972fa 100644
|
|
|
d7fdbd |
--- a/EXAMPLE/VIRTUAL_USERS/README
|
|
|
d7fdbd |
+++ b/EXAMPLE/VIRTUAL_USERS/README
|
|
|
d7fdbd |
@@ -15,7 +15,7 @@ See example file "logins.txt" - this specifies "tom" with password "foo" and
|
|
|
d7fdbd |
"fred" with password "bar".
|
|
|
d7fdbd |
Whilst logged in as root, create the actual database file like this:
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-db_load -T -t hash -f logins.txt /etc/vsftpd_login.db
|
|
|
d7fdbd |
+db_load -T -t hash -f logins.txt /etc/vsftpd/login.db
|
|
|
d7fdbd |
(Requires the Berkeley db program installed).
|
|
|
d7fdbd |
NOTE: Many systems have multiple versions of "db" installed, so you may
|
|
|
d7fdbd |
need to use e.g. db3_load for correct operation. This is known to affect
|
|
|
d7fdbd |
@@ -23,10 +23,10 @@ some Debian systems. The core issue is that pam_userdb expects its login
|
|
|
d7fdbd |
database to be a specific db version (often db3, whereas db4 may be installed
|
|
|
d7fdbd |
on your system).
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-This will create /etc/vsftpd_login.db. Obviously, you may want to make sure
|
|
|
d7fdbd |
+This will create /etc/vsftpd/login.db. Obviously, you may want to make sure
|
|
|
d7fdbd |
the permissions are restricted:
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-chmod 600 /etc/vsftpd_login.db
|
|
|
d7fdbd |
+chmod 600 /etc/vsftpd/login.db
|
|
|
d7fdbd |
|
|
|
d7fdbd |
For more information on maintaing your login database, look around for
|
|
|
d7fdbd |
documentation on "Berkeley DB", e.g.
|
|
|
d7fdbd |
@@ -37,8 +37,8 @@ Step 2) Create a PAM file which uses your new database.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
See the example file vsftpd.pam. It contains two lines:
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-auth required /lib/security/pam_userdb.so db=/etc/vsftpd_login
|
|
|
d7fdbd |
-account required /lib/security/pam_userdb.so db=/etc/vsftpd_login
|
|
|
d7fdbd |
+auth required /lib/security/pam_userdb.so db=/etc/vsftpd/login
|
|
|
d7fdbd |
+account required /lib/security/pam_userdb.so db=/etc/vsftpd/login
|
|
|
d7fdbd |
|
|
|
d7fdbd |
This tells PAM to authenticate users using our new database. Copy this PAM
|
|
|
d7fdbd |
file to the PAM directory - typically /etc/pam.d/
|
|
|
d7fdbd |
@@ -108,9 +108,9 @@ pasv_max_port=30999
|
|
|
d7fdbd |
These put a port range on passive FTP incoming requests - very useful if
|
|
|
d7fdbd |
you are configuring a firewall.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-Copy the example vsftpd.conf file to /etc:
|
|
|
d7fdbd |
+Copy the example vsftpd.conf file to /etc/vsftpd:
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-cp vsftpd.conf /etc/
|
|
|
d7fdbd |
+cp vsftpd.conf /etc/vsftpd/
|
|
|
d7fdbd |
|
|
|
d7fdbd |
|
|
|
d7fdbd |
Step 5) Start up vsftpd.
|
|
|
d7fdbd |
diff --git a/FAQ b/FAQ
|
|
|
d7fdbd |
index 59fe56b..0142a0d 100644
|
|
|
d7fdbd |
--- a/FAQ
|
|
|
d7fdbd |
+++ b/FAQ
|
|
|
d7fdbd |
@@ -35,7 +35,7 @@ needs this user to run bits of itself with no privilege.
|
|
|
d7fdbd |
Q) Help! Local users cannot log in.
|
|
|
d7fdbd |
A) There are various possible problems.
|
|
|
d7fdbd |
A1) By default, vsftpd disables any logins other than anonymous logins. Put
|
|
|
d7fdbd |
-local_enable=YES in your /etc/vsftpd.conf to allow local users to log in.
|
|
|
d7fdbd |
+local_enable=YES in your /etc/vsftpd/vsftpd.conf to allow local users to log in.
|
|
|
d7fdbd |
A2) vsftpd tries to link with PAM. (Run "ldd vsftpd" and look for libpam to
|
|
|
d7fdbd |
find out whether this has happened or not). If vsftpd links with PAM, then
|
|
|
d7fdbd |
you will need to have a PAM file installed for the vsftpd service. There is
|
|
|
d7fdbd |
@@ -47,12 +47,12 @@ system have a "shadow.h" file in the include path?
|
|
|
d7fdbd |
A4) If you are not using PAM, then vsftpd will do its own check for a valid
|
|
|
d7fdbd |
user shell in /etc/shells. You may need to disable this if you use an invalid
|
|
|
d7fdbd |
shell to disable logins other than FTP logins. Put check_shell=NO in your
|
|
|
d7fdbd |
-/etc/vsftpd.conf.
|
|
|
d7fdbd |
+/etc/vsftpd/vsftpd.conf.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
Q) Help! Uploads or other write commands give me "500 Unknown command.".
|
|
|
d7fdbd |
A) By default, write commands, including uploads and new directories, are
|
|
|
d7fdbd |
disabled. This is a security measure. To enable writes, put write_enable=YES
|
|
|
d7fdbd |
-in your /etc/vsftpd.conf.
|
|
|
d7fdbd |
+in your /etc/vsftpd/vsftpd.conf.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
Q) Help! What are the security implications referred to in the
|
|
|
d7fdbd |
"chroot_local_user" option?
|
|
|
d7fdbd |
@@ -88,7 +88,7 @@ A2) Alternatively, run as many copies as vsftpd as necessary, in standalone
|
|
|
d7fdbd |
mode. Use "listen_address=x.x.x.x" to set the virtual IP.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
Q) Help! Does vsftpd support virtual users?
|
|
|
d7fdbd |
-A) Yes, via PAM integration. Set "guest_enable=YES" in /etc/vsftpd.conf. This
|
|
|
d7fdbd |
+A) Yes, via PAM integration. Set "guest_enable=YES" in /etc/vsftpd/vsftpd.conf. This
|
|
|
d7fdbd |
has the effect of mapping every non-anonymous successful login to the local
|
|
|
d7fdbd |
username specified in "guest_username". Then, use PAM and (e.g.) its pam_userdb
|
|
|
d7fdbd |
module to provide authentication against an external (i.e. non-/etc/passwd)
|
|
|
d7fdbd |
diff --git a/INSTALL b/INSTALL
|
|
|
d7fdbd |
index 4f811aa..93a8a81 100644
|
|
|
d7fdbd |
--- a/INSTALL
|
|
|
d7fdbd |
+++ b/INSTALL
|
|
|
d7fdbd |
@@ -56,14 +56,14 @@ cp vsftpd.8 /usr/local/man/man8
|
|
|
d7fdbd |
|
|
|
d7fdbd |
"make install" doesn't copy the sample config file. It is recommended you
|
|
|
d7fdbd |
do this:
|
|
|
d7fdbd |
-cp vsftpd.conf /etc
|
|
|
d7fdbd |
+cp vsftpd.conf /etc/vsftpd
|
|
|
d7fdbd |
|
|
|
d7fdbd |
Step 4) Smoke test (without an inetd).
|
|
|
d7fdbd |
|
|
|
d7fdbd |
vsftpd can run standalone or via an inetd (such as inetd or xinetd). You will
|
|
|
d7fdbd |
typically get more control running vsftpd from an inetd. But first we will run
|
|
|
d7fdbd |
it without, so we can check things are going well so far.
|
|
|
d7fdbd |
-Edit /etc/vsftpd.conf, and add this line at the bottom:
|
|
|
d7fdbd |
+Edit /etc/vsftpd/vsftpd.conf, and add this line at the bottom:
|
|
|
d7fdbd |
|
|
|
d7fdbd |
listen=YES
|
|
|
d7fdbd |
|
|
|
d7fdbd |
@@ -135,11 +135,11 @@ cp RedHat/vsftpd.pam /etc/pam.d/ftp
|
|
|
d7fdbd |
Step 7) Customize your configuration
|
|
|
d7fdbd |
|
|
|
d7fdbd |
As well as the above three pre-requisites, you are recommended to install a
|
|
|
d7fdbd |
-config file. The default location for the config file is /etc/vsftpd.conf.
|
|
|
d7fdbd |
+config file. The default location for the config file is /etc/vsftpd/vsftpd.conf.
|
|
|
d7fdbd |
There is a sample vsftpd.conf in the distribution tarball. You probably want
|
|
|
d7fdbd |
-to copy that to /etc/vsftpd.conf as a basis for modification, i.e.:
|
|
|
d7fdbd |
+to copy that to /etc/vsftpd/vsftpd.conf as a basis for modification, i.e.:
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-cp vsftpd.conf /etc
|
|
|
d7fdbd |
+cp vsftpd.conf /etc/vsftpd
|
|
|
d7fdbd |
|
|
|
d7fdbd |
The default configuration allows neither local user logins nor anonymous
|
|
|
d7fdbd |
uploads. You may wish to change these defaults.
|
|
|
d7fdbd |
diff --git a/README b/README
|
|
|
d7fdbd |
index 86643c1..adc7f42 100644
|
|
|
d7fdbd |
--- a/README
|
|
|
d7fdbd |
+++ b/README
|
|
|
d7fdbd |
@@ -37,3 +37,8 @@ All configuration options are documented in the manual page vsftpd.conf.5.
|
|
|
d7fdbd |
Various example configurations are discussed in the EXAMPLE directory.
|
|
|
d7fdbd |
Frequently asked questions are tackled in the FAQ file.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
+Important Note
|
|
|
d7fdbd |
+==============
|
|
|
d7fdbd |
+The location of configuration files was changed to /etc/vsftpd/. If you want
|
|
|
d7fdbd |
+to migrate your old conf files from /etc (files vsftpd.xxxx.rpmsave) use
|
|
|
d7fdbd |
+/etc/vsfptd/vsftpd_conf_migrate.sh
|
|
|
d7fdbd |
diff --git a/defs.h b/defs.h
|
|
|
d7fdbd |
index 0ff5864..ca11eac 100644
|
|
|
d7fdbd |
--- a/defs.h
|
|
|
d7fdbd |
+++ b/defs.h
|
|
|
d7fdbd |
@@ -1,7 +1,7 @@
|
|
|
d7fdbd |
#ifndef VSF_DEFS_H
|
|
|
d7fdbd |
#define VSF_DEFS_H
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-#define VSFTP_DEFAULT_CONFIG "/etc/vsftpd.conf"
|
|
|
d7fdbd |
+#define VSFTP_DEFAULT_CONFIG "/etc/vsftpd/vsftpd.conf"
|
|
|
d7fdbd |
|
|
|
d7fdbd |
#define VSFTP_COMMAND_FD 0
|
|
|
d7fdbd |
|
|
|
d7fdbd |
diff --git a/tunables.c b/tunables.c
|
|
|
d7fdbd |
index 284a10d..0ac4c34 100644
|
|
|
d7fdbd |
--- a/tunables.c
|
|
|
d7fdbd |
+++ b/tunables.c
|
|
|
d7fdbd |
@@ -190,7 +190,7 @@ tunables_load_defaults()
|
|
|
d7fdbd |
tunable_listen_ipv6 = 0;
|
|
|
d7fdbd |
tunable_dual_log_enable = 0;
|
|
|
d7fdbd |
tunable_syslog_enable = 0;
|
|
|
d7fdbd |
- tunable_background = 0;
|
|
|
d7fdbd |
+ tunable_background = 1;
|
|
|
d7fdbd |
tunable_virtual_use_local_privs = 0;
|
|
|
d7fdbd |
tunable_session_support = 0;
|
|
|
d7fdbd |
tunable_download_enable = 1;
|
|
|
d7fdbd |
@@ -262,11 +262,11 @@ tunables_load_defaults()
|
|
|
d7fdbd |
install_str_setting(".message", &tunable_message_file);
|
|
|
d7fdbd |
install_str_setting("nobody", &tunable_nopriv_user);
|
|
|
d7fdbd |
install_str_setting(0, &tunable_ftpd_banner);
|
|
|
d7fdbd |
- install_str_setting("/etc/vsftpd.banned_emails", &tunable_banned_email_file);
|
|
|
d7fdbd |
- install_str_setting("/etc/vsftpd.chroot_list", &tunable_chroot_list_file);
|
|
|
d7fdbd |
+ install_str_setting("/etc/vsftpd/banned_emails", &tunable_banned_email_file);
|
|
|
d7fdbd |
+ install_str_setting("/etc/vsftpd/chroot_list", &tunable_chroot_list_file);
|
|
|
d7fdbd |
install_str_setting("ftp", &tunable_pam_service_name);
|
|
|
d7fdbd |
install_str_setting("ftp", &tunable_guest_username);
|
|
|
d7fdbd |
- install_str_setting("/etc/vsftpd.user_list", &tunable_userlist_file);
|
|
|
d7fdbd |
+ install_str_setting("/etc/vsftpd/user_list", &tunable_userlist_file);
|
|
|
d7fdbd |
install_str_setting(0, &tunable_anon_root);
|
|
|
d7fdbd |
install_str_setting(0, &tunable_local_root);
|
|
|
d7fdbd |
install_str_setting(0, &tunable_banner_file);
|
|
|
d7fdbd |
@@ -279,7 +279,7 @@ tunables_load_defaults()
|
|
|
d7fdbd |
install_str_setting(0, &tunable_hide_file);
|
|
|
d7fdbd |
install_str_setting(0, &tunable_deny_file);
|
|
|
d7fdbd |
install_str_setting(0, &tunable_user_sub_token);
|
|
|
d7fdbd |
- install_str_setting("/etc/vsftpd.email_passwords",
|
|
|
d7fdbd |
+ install_str_setting("/etc/vsftpd/email_passwords",
|
|
|
d7fdbd |
&tunable_email_password_file);
|
|
|
d7fdbd |
install_str_setting("/usr/share/ssl/certs/vsftpd.pem",
|
|
|
d7fdbd |
&tunable_rsa_cert_file);
|
|
|
d7fdbd |
diff --git a/vsftpd.8 b/vsftpd.8
|
|
|
d7fdbd |
index 6640b57..c920e7d 100644
|
|
|
d7fdbd |
--- a/vsftpd.8
|
|
|
d7fdbd |
+++ b/vsftpd.8
|
|
|
d7fdbd |
@@ -21,7 +21,7 @@ itself will listen on the network. This latter mode is easier to use, and
|
|
|
d7fdbd |
recommended. It is activated by setting
|
|
|
d7fdbd |
.Pa listen=YES
|
|
|
d7fdbd |
in
|
|
|
d7fdbd |
-.Pa /etc/vsftpd.conf .
|
|
|
d7fdbd |
+.Pa /etc/vsftpd/vsftpd.conf .
|
|
|
d7fdbd |
Direct execution of the
|
|
|
d7fdbd |
.Nm vsftpd
|
|
|
d7fdbd |
binary will then launch the FTP service ready for immediate client connections.
|
|
|
d7fdbd |
@@ -33,7 +33,7 @@ as root. Any command line option not starting with a "-" character is treated
|
|
|
d7fdbd |
as a config file that will be loaded. Note that config files are loaded in the
|
|
|
d7fdbd |
strict order that they are encountered on the command line.
|
|
|
d7fdbd |
If no config files are specified, the default configuration file of
|
|
|
d7fdbd |
-.Pa /etc/vsftpd.conf
|
|
|
d7fdbd |
+.Pa /etc/vsftpd/vsftpd.conf
|
|
|
d7fdbd |
will be loaded, after all other command line options are processed.
|
|
|
d7fdbd |
.Pp
|
|
|
d7fdbd |
Supported options are:
|
|
|
d7fdbd |
@@ -47,14 +47,14 @@ their appearance on the command line, including intermingling with loading of
|
|
|
d7fdbd |
config files.
|
|
|
d7fdbd |
.El
|
|
|
d7fdbd |
.Sh EXAMPLES
|
|
|
d7fdbd |
-vsftpd -olisten=NO /etc/vsftpd.conf -oftpd_banner=blah
|
|
|
d7fdbd |
+vsftpd -olisten=NO /etc/vsftpd/vsftpd.conf -oftpd_banner=blah
|
|
|
d7fdbd |
.Pp
|
|
|
d7fdbd |
That example overrides vsftpd's built-in default for the "listen" option to be
|
|
|
d7fdbd |
-NO, but then loads /etc/vsftpd.conf which may override that setting. Finally,
|
|
|
d7fdbd |
+NO, but then loads /etc/vsftpd/vsftpd.conf which may override that setting. Finally,
|
|
|
d7fdbd |
the "ftpd_banner" setting is set to "blah", which overrides any default vsftpd
|
|
|
d7fdbd |
setting and any identical setting that was in the config file.
|
|
|
d7fdbd |
.Sh FILES
|
|
|
d7fdbd |
-.Pa /etc/vsftpd.conf
|
|
|
d7fdbd |
+.Pa /etc/vsftpd/vsftpd.conf
|
|
|
d7fdbd |
.Sh SEE ALSO
|
|
|
d7fdbd |
.Xr vsftpd.conf 5
|
|
|
d7fdbd |
.end
|
|
|
d7fdbd |
diff --git a/vsftpd.conf b/vsftpd.conf
|
|
|
d7fdbd |
index cc1c607..db44170 100644
|
|
|
d7fdbd |
--- a/vsftpd.conf
|
|
|
d7fdbd |
+++ b/vsftpd.conf
|
|
|
d7fdbd |
@@ -1,4 +1,4 @@
|
|
|
d7fdbd |
-# Example config file /etc/vsftpd.conf
|
|
|
d7fdbd |
+# Example config file /etc/vsftpd/vsftpd.conf
|
|
|
d7fdbd |
#
|
|
|
d7fdbd |
# The default compiled in settings are fairly paranoid. This sample file
|
|
|
d7fdbd |
# loosens things up a bit, to make the ftp daemon more usable.
|
|
|
d7fdbd |
@@ -12,18 +12,20 @@
|
|
|
d7fdbd |
anonymous_enable=YES
|
|
|
d7fdbd |
#
|
|
|
d7fdbd |
# Uncomment this to allow local users to log in.
|
|
|
d7fdbd |
-#local_enable=YES
|
|
|
d7fdbd |
+# When SELinux is enforcing check for SE bool ftp_home_dir
|
|
|
d7fdbd |
+local_enable=YES
|
|
|
d7fdbd |
#
|
|
|
d7fdbd |
# Uncomment this to enable any form of FTP write command.
|
|
|
d7fdbd |
-#write_enable=YES
|
|
|
d7fdbd |
+write_enable=YES
|
|
|
d7fdbd |
#
|
|
|
d7fdbd |
# Default umask for local users is 077. You may wish to change this to 022,
|
|
|
d7fdbd |
# if your users expect that (022 is used by most other ftpd's)
|
|
|
d7fdbd |
-#local_umask=022
|
|
|
d7fdbd |
+local_umask=022
|
|
|
d7fdbd |
#
|
|
|
d7fdbd |
# Uncomment this to allow the anonymous FTP user to upload files. This only
|
|
|
d7fdbd |
# has an effect if the above global write enable is activated. Also, you will
|
|
|
d7fdbd |
# obviously need to create a directory writable by the FTP user.
|
|
|
d7fdbd |
+# When SELinux is enforcing check for SE bool allow_ftpd_anon_write, allow_ftpd_full_access
|
|
|
d7fdbd |
#anon_upload_enable=YES
|
|
|
d7fdbd |
#
|
|
|
d7fdbd |
# Uncomment this if you want the anonymous FTP user to be able to create
|
|
|
d7fdbd |
@@ -52,7 +54,7 @@ connect_from_port_20=YES
|
|
|
d7fdbd |
#
|
|
|
d7fdbd |
# If you want, you can have your log file in standard ftpd xferlog format.
|
|
|
d7fdbd |
# Note that the default log file location is /var/log/xferlog in this case.
|
|
|
d7fdbd |
-#xferlog_std_format=YES
|
|
|
d7fdbd |
+xferlog_std_format=YES
|
|
|
d7fdbd |
#
|
|
|
d7fdbd |
# You may change the default value for timing out an idle session.
|
|
|
d7fdbd |
#idle_session_timeout=600
|
|
|
d7fdbd |
@@ -87,7 +89,7 @@ connect_from_port_20=YES
|
|
|
d7fdbd |
# useful for combatting certain DoS attacks.
|
|
|
d7fdbd |
#deny_email_enable=YES
|
|
|
d7fdbd |
# (default follows)
|
|
|
d7fdbd |
-#banned_email_file=/etc/vsftpd.banned_emails
|
|
|
d7fdbd |
+#banned_email_file=/etc/vsftpd/banned_emails
|
|
|
d7fdbd |
#
|
|
|
d7fdbd |
# You may specify an explicit list of local users to chroot() to their home
|
|
|
d7fdbd |
# directory. If chroot_local_user is YES, then this list becomes a list of
|
|
|
d7fdbd |
@@ -98,7 +100,7 @@ connect_from_port_20=YES
|
|
|
d7fdbd |
#chroot_local_user=YES
|
|
|
d7fdbd |
#chroot_list_enable=YES
|
|
|
d7fdbd |
# (default follows)
|
|
|
d7fdbd |
-#chroot_list_file=/etc/vsftpd.chroot_list
|
|
|
d7fdbd |
+#chroot_list_file=/etc/vsftpd/chroot_list
|
|
|
d7fdbd |
#
|
|
|
d7fdbd |
# You may activate the "-R" option to the builtin ls. This is disabled by
|
|
|
d7fdbd |
# default to avoid remote users being able to cause excessive I/O on large
|
|
|
d7fdbd |
@@ -115,3 +117,7 @@ listen=YES
|
|
|
d7fdbd |
# sockets, you must run two copies of vsftpd with two configuration files.
|
|
|
d7fdbd |
# Make sure, that one of the listen options is commented !!
|
|
|
d7fdbd |
#listen_ipv6=YES
|
|
|
d7fdbd |
+
|
|
|
d7fdbd |
+pam_service_name=vsftpd
|
|
|
d7fdbd |
+userlist_enable=YES
|
|
|
d7fdbd |
+tcp_wrappers=YES
|
|
|
d7fdbd |
diff --git a/vsftpd.conf.5 b/vsftpd.conf.5
|
|
|
d7fdbd |
index fcc6022..5e46a2f 100644
|
|
|
d7fdbd |
--- a/vsftpd.conf.5
|
|
|
d7fdbd |
+++ b/vsftpd.conf.5
|
|
|
d7fdbd |
@@ -4,7 +4,7 @@ vsftpd.conf \- config file for vsftpd
|
|
|
d7fdbd |
.SH DESCRIPTION
|
|
|
d7fdbd |
vsftpd.conf may be used to control various aspects of vsftpd's behaviour. By
|
|
|
d7fdbd |
default, vsftpd looks for this file at the location
|
|
|
d7fdbd |
-.BR /etc/vsftpd.conf .
|
|
|
d7fdbd |
+.BR /etc/vsftpd/vsftpd.conf .
|
|
|
d7fdbd |
However, you may override this by specifying a command line argument to
|
|
|
d7fdbd |
vsftpd. The command line argument is the pathname of the configuration file
|
|
|
d7fdbd |
for vsftpd. This behaviour is useful because you may wish to use an advanced
|
|
|
d7fdbd |
@@ -110,7 +110,7 @@ When enabled, and vsftpd is started in "listen" mode, vsftpd will background
|
|
|
d7fdbd |
the listener process. i.e. control will immediately be returned to the shell
|
|
|
d7fdbd |
which launched vsftpd.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-Default: NO
|
|
|
d7fdbd |
+Default: YES
|
|
|
d7fdbd |
.TP
|
|
|
d7fdbd |
.B check_shell
|
|
|
d7fdbd |
Note! This option only has an effect for non-PAM builds of vsftpd. If disabled,
|
|
|
d7fdbd |
@@ -138,7 +138,7 @@ chroot() jail in their home directory upon login. The meaning is slightly
|
|
|
d7fdbd |
different if chroot_local_user is set to YES. In this case, the list becomes
|
|
|
d7fdbd |
a list of users which are NOT to be placed in a chroot() jail.
|
|
|
d7fdbd |
By default, the file containing this list is
|
|
|
d7fdbd |
-/etc/vsftpd.chroot_list, but you may override this with the
|
|
|
d7fdbd |
+/etc/vsftpd/chroot_list, but you may override this with the
|
|
|
d7fdbd |
.BR chroot_list_file
|
|
|
d7fdbd |
setting.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
@@ -177,7 +177,7 @@ Default: NO
|
|
|
d7fdbd |
.B deny_email_enable
|
|
|
d7fdbd |
If activated, you may provide a list of anonymous password e-mail responses
|
|
|
d7fdbd |
which cause login to be denied. By default, the file containing this list is
|
|
|
d7fdbd |
-/etc/vsftpd.banned_emails, but you may override this with the
|
|
|
d7fdbd |
+/etc/vsftpd/banned_emails, but you may override this with the
|
|
|
d7fdbd |
.BR banned_email_file
|
|
|
d7fdbd |
setting.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
@@ -433,7 +433,7 @@ anonymous logins are prevented unless the password provided is listed in the
|
|
|
d7fdbd |
file specified by the
|
|
|
d7fdbd |
.BR email_password_file
|
|
|
d7fdbd |
setting. The file format is one password per line, no extra whitespace. The
|
|
|
d7fdbd |
-default filename is /etc/vsftpd.email_passwords.
|
|
|
d7fdbd |
+default filename is /etc/vsftpd/email_passwords.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
Default: NO
|
|
|
d7fdbd |
.TP
|
|
|
d7fdbd |
@@ -764,7 +764,7 @@ passwords which are not permitted. This file is consulted if the option
|
|
|
d7fdbd |
.BR deny_email_enable
|
|
|
d7fdbd |
is enabled.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-Default: /etc/vsftpd.banned_emails
|
|
|
d7fdbd |
+Default: /etc/vsftpd/banned_emails
|
|
|
d7fdbd |
.TP
|
|
|
d7fdbd |
.B banner_file
|
|
|
d7fdbd |
This option is the name of a file containing text to display when someone
|
|
|
d7fdbd |
@@ -803,7 +803,7 @@ is enabled. If the option
|
|
|
d7fdbd |
is enabled, then the list file becomes a list of users to NOT place in a
|
|
|
d7fdbd |
chroot() jail.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-Default: /etc/vsftpd.chroot_list
|
|
|
d7fdbd |
+Default: /etvsftpd.confc/vsftpd.chroot_list
|
|
|
d7fdbd |
.TP
|
|
|
d7fdbd |
.B cmds_allowed
|
|
|
d7fdbd |
This options specifies a comma separated list of allowed FTP commands (post
|
|
|
d7fdbd |
@@ -864,7 +864,7 @@ This option can be used to provide an alternate file for usage by the
|
|
|
d7fdbd |
.BR secure_email_list_enable
|
|
|
d7fdbd |
setting.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-Default: /etc/vsftpd.email_passwords
|
|
|
d7fdbd |
+Default: /etc/vsftpd/email_passwords
|
|
|
d7fdbd |
.TP
|
|
|
d7fdbd |
.B ftp_username
|
|
|
d7fdbd |
This is the name of the user we use for handling anonymous FTP. The home
|
|
|
d7fdbd |
@@ -987,10 +987,10 @@ the manual page, on a per-user basis. Usage is simple, and is best illustrated
|
|
|
d7fdbd |
with an example. If you set
|
|
|
d7fdbd |
.BR user_config_dir
|
|
|
d7fdbd |
to be
|
|
|
d7fdbd |
-.BR /etc/vsftpd_user_conf
|
|
|
d7fdbd |
+.BR /etc/vsftpd/user_conf
|
|
|
d7fdbd |
and then log on as the user "chris", then vsftpd will apply the settings in
|
|
|
d7fdbd |
the file
|
|
|
d7fdbd |
-.BR /etc/vsftpd_user_conf/chris
|
|
|
d7fdbd |
+.BR /etc/vsftpd/user_conf/chris
|
|
|
d7fdbd |
for the duration of the session. The format of this file is as detailed in
|
|
|
d7fdbd |
this manual page! PLEASE NOTE that not all settings are effective on a
|
|
|
d7fdbd |
per-user basis. For example, many settings only prior to the user's session
|
|
|
d7fdbd |
@@ -1026,7 +1026,7 @@ This option is the name of the file loaded when the
|
|
|
d7fdbd |
.BR userlist_enable
|
|
|
d7fdbd |
option is active.
|
|
|
d7fdbd |
|
|
|
d7fdbd |
-Default: /etc/vsftpd.user_list
|
|
|
d7fdbd |
+Default: /etc/vsftpd/user_list
|
|
|
d7fdbd |
.TP
|
|
|
d7fdbd |
.B vsftpd_log_file
|
|
|
d7fdbd |
This option is the name of the file to which we write the vsftpd style
|
|
|
d7fdbd |
--
|
|
|
d7fdbd |
2.14.4
|
|
|
d7fdbd |
|