vsftpd.conf,vsftpd的配置文件。
配置文件描述
该配置文件用户控制vsftpd的行为。默认在/etc/vsftpd.conf查找该文件。可以在命令行中以参数的形式指定配置文件。此行为非常有用,因为你可能会使用高级的inetd(如xinetd)在每个虚拟主机的基础上启动具有不同配置文件的vsftpd。
配置文件格式
井号(#)开始的行为注释行,会被忽略。
指令的格式为:
警告:option,=,value这三者之间是不能由空格的。
每个设置都有默认值,可以在配置文件中进行修改。
布尔值选项
ascii_upload_enable
When enabled, ASCII mode data transfers will be honoured on
uploads.
默认值: NO
ascii_download_enable
When enabled, ASCII mode data transfers will be honoured on down‐
loads.
默认值: NO
async_abor_enable
When enabled, a special FTP command known as “async ABOR” will be
enabled. Only ill advised FTP clients will use this feature.
Additionally, this feature is awkward to handle, so it is disabled
by default. Unfortunately, some FTP clients will hang when can‐
celling a transfer unless this feature is available, so you may
wish to enable it.
默认值: NO
background
启用时,vsftpd以“监听”模式启动,即在后台运行。
默认值: NO
check_shell
Note! This option only has an effect for non-PAM builds of vsftpd.
If disabled, vsftpd will not check /etc/shells for a valid user
shell for local logins.
默认值: YES
chmod_enable
When enabled, allows use of the SITE CHMOD command. NOTE! This
only applies to local users. Anonymous users never get to use SITE
CHMOD.
默认值: YES
chown_uploads
If enabled, all anonymously uploaded files will have the ownership
changed to the user specified in the setting chown_username. This
is useful from an administrative, and perhaps security, stand‐
point.
默认值: NO
connect_from_port_20
This controls whether PORT style data connections use port 20
(ftp-data) on the server machine. For security reasons, some
clients may insist that this is the case. Conversely, disabling
this option enables vsftpd to run with slightly less privilege.
默认值: NO (but the sample config file enables it)
debug_ssl
If true, OpenSSL connection diagnostics are dumped to the vsftpd
log file. (Added in v2.0.6).
默认值: NO
delete_failed_uploads
If true, any failed upload files are deleted. (Added in v2.0.7).
默认值: NO
deny_email_enable
If activated, you may provide a list of anonymous password e-mail
responses which cause login to be denied. By default, the file
containing this list is /etc/vsftpd.banned_emails, but you may
override this with the banned_email_file setting.
默认值: NO
dirlist_enable
If set to NO, all directory list commands will give permission
denied.
默认值: YES
dirmessage_enable
If enabled, users of the FTP server can be shown messages when
they first enter a new directory. By default, a directory is
scanned for the file .message, but that may be overridden with the
configuration setting message_file.
默认值: NO (but the sample config file enables it)
download_enable
If set to NO, all download requests will give permission denied.
默认值: YES
dual_log_enable
If enabled, two log files are generated in parallel, going by
default to /var/log/xferlog and /var/log/vsftpd.log. The former
is a wu-ftpd style transfer log, parseable by standard tools. The
latter is vsftpd’s own style log.
默认值: NO
force_dot_files
If activated, files and directories starting with . will be shown
in directory listings even if the “a” flag was not used by the
client. This override excludes the “.” and “..” entries.
默认值: NO
force_anon_data_ssl
Only applies if ssl_enable is activated. If activated, all anony‐
mous logins are forced to use a secure SSL connection in order to
send and receive data on data connections.
默认值: NO
force_anon_logins_ssl
Only applies if ssl_enable is activated. If activated, all anony‐
mous logins are forced to use a secure SSL connection in order to
send the password.
默认值: NO
force_local_data_ssl
Only applies if ssl_enable is activated. If activated, all non-
anonymous logins are forced to use a secure SSL connection in
order to send and receive data on data connections.
默认值: YES
force_local_logins_ssl
Only applies if ssl_enable is activated. If activated, all non-
anonymous logins are forced to use a secure SSL connection in
order to send the password.
默认值: YES
guest_enable
If enabled, all non-anonymous logins are classed as “guest”
logins. A guest login is remapped to the user specified in the
guest_username setting.
默认值: NO
hide_ids
If enabled, all user and group information in directory listings
will be displayed as “ftp”.
默认值: NO
implicit_ssl
If enabled, an SSL handshake is the first thing expect on all con‐
nections (the FTPS protocol). To support explicit SSL and/or plain
text too, a separate vsftpd listener process should be run.
默认值: NO
listen
如果启动,vsftpd会以独立模式运行。这表示vsftpd不会从某种inetd中运行,而是vsftpd可执行文件直接运行, vsftpd本身将会监听和处理传入连接。
默认值: NO
listen_ipv6
Like the listen parameter, except vsftpd will listen on an IPv6
socket instead of an IPv4 one. This parameter and the listen
parameter are mutually exclusive.
默认值: NO
local_enable
是否允许本地用户登录。
如果启动(YES),/etc/passwd(或者PAM配置引用的任何地方)中的用户允许登录。
注意:如果想任何非匿名登录的功能可用(包括虚拟用户),必须启用该选项。
默认值: NO
lock_upload_files
When enabled, all uploads proceed with a write lock on the upload
file. All downloads proceed with a shared read lock on the down‐
load file. WARNING! Before enabling this, be aware that malicious
readers could starve a writer wanting to e.g. append a file.
默认值: YES
log_ftp_protocol
When enabled, all FTP requests and responses are logged, providing
the option xferlog_std_format is not enabled. Useful for debug‐
ging.
默认值: NO
ls_recurse_enable
When enabled, this setting will allow the use of “ls -R”. This is
a minor security risk, because a ls -R at the top level of a large
site may consume a lot of resources.
默认值: NO
mdtm_write
When enabled, this setting will allow MDTM to set file modifica‐
tion times (subject to the usual access checks).
默认值: YES
no_anon_password
When enabled, this prevents vsftpd from asking for an anonymous
password – the anonymous user will log straight in.
默认值: NO
no_log_lock
When enabled, this prevents vsftpd from taking a file lock when
writing to log files. This option should generally not be enabled.
It exists to workaround operating system bugs such as the Solaris
/ Veritas filesystem combination which has been observed to some‐
times exhibit hangs trying to lock log files.
默认值: NO
one_process_model
If you have a Linux 2.4 kernel, it is possible to use a different
security model which only uses one process per connection. It is a
less pure security model, but gains you performance. You really
don’t want to enable this unless you know what you are doing, and
your site supports huge numbers of simultaneously connected users.
默认值: NO
pasv_addr_resolve
Set to YES if you want to use a hostname (as opposed to IP
address) in the pasv_address option.
默认值: NO
pasv_enable
Set to NO if you want to disallow the PASV method of obtaining a
data connection.
默认值: YES
pasv_promiscuous
Set to YES if you want to disable the PASV security check that
ensures the data connection originates from the same IP address as
the control connection. Only enable if you know what you are
doing! The only legitimate use for this is in some form of secure
tunnelling scheme, or perhaps to facilitate FXP support.
默认值: NO
port_enable
Set to NO if you want to disallow the PORT method of obtaining a
data connection.
默认值: YES
port_promiscuous
Set to YES if you want to disable the PORT security check that
ensures that outgoing data connections can only connect to the
client. Only enable if you know what you are doing!
默认值: NO
require_cert
If set to yes, all SSL client connections are required to present
a client certificate. The degree of validation applied to this
certificate is controlled by validate_cert (Added in v2.0.6).
默认值: NO
require_ssl_reuse
If set to yes, all SSL data connections are required to exhibit
SSL session reuse (which proves that they know the same master
secret as the control channel). Although this is a secure default,
it may break many FTP clients, so you may want to disable it. For
a discussion of the consequences, see http://scarybeastsecu‐
rity.blogspot.com/2009/02/vsftpd-210-released.html (Added in
v2.1.0).
默认值: YES
run_as_launching_user
Set to YES if you want vsftpd to run as the user which launched
vsftpd. This is useful where root access is not available. MASSIVE
WARNING! Do NOT enable this option unless you totally know what
you are doing, as naive use of this option can create massive
security problems. Specifically, vsftpd does not / cannot use
chroot technology to restrict file access when this option is set
(even if launched by root). A poor substitute could be to use a
deny_file setting such as {/*,*..*}, but the reliability of this
cannot compare to chroot, and should not be relied on. If using
this option, many restrictions on other options apply. For exam‐
ple, options requiring privilege such as non-anonymous logins,
upload ownership changing, connecting from port 20 and listen
ports less than 1024 are not expected to work. Other options may
be impacted.
默认值: NO
secure_email_list_enable
Set to YES if you want only a specified list of e-mail passwords
for anonymous logins to be accepted. This is useful as a low-has‐
sle way of restricting access to low-security content without
needing virtual users. When enabled, anonymous logins are pre‐
vented unless the password provided is listed in the file speci‐
fied by the email_password_file setting. The file format is one
password per line, no extra whitespace. The default filename is
/etc/vsftpd.email_passwords.
默认值: NO
session_support
This controls whether vsftpd attempts to maintain sessions for
logins. If vsftpd is maintaining sessions, it will try and update
utmp and wtmp. It will also open a pam_session if using PAM to
authenticate, and only close this upon logout. You may wish to
disable this if you do not need session logging, and you wish to
give vsftpd more opportunity to run with less processes and / or
less privilege. NOTE – utmp and wtmp support is only provided with
PAM enabled builds.
默认值: NO
setproctitle_enable
If enabled, vsftpd will try and show session status information in
the system process listing. In other words, the reported name of
the process will change to reflect what a vsftpd session is doing
(idle, downloading etc). You probably want to leave this off for
security purposes.
默认值: NO
ssl_enable
If enabled, and vsftpd was compiled against OpenSSL, vsftpd will
support secure connections via SSL. This applies to the control
connection (including login) and also data connections. You’ll
need a client with SSL support too. NOTE!! Beware enabling this
option. Only enable it if you need it. vsftpd can make no guaran‐
tees about the security of the OpenSSL libraries. By enabling this
option, you are declaring that you trust the security of your
installed OpenSSL library.
默认值: NO
ssl_request_cert
If enabled, vsftpd will request (but not necessarily require; see
require_cert)acertificateonincomingSSLconnections.Normallythis
should not cause any trouble at all, but IBM zOS seems to have
issues. (New in v2.0.7).
默认值: YES
ssl_sslv2
Only applies if ssl_enable is activated. If enabled, this option
will permit SSL v2 protocol connections. TLS v1 connections are
preferred.
默认值: NO
ssl_sslv3
Only applies if ssl_enable is activated. If enabled, this option
will permit SSL v3 protocol connections. TLS v1 connections are
preferred.
默认值: NO
ssl_tlsv1
Only applies if ssl_enable is activated. If enabled, this option
will permit TLS v1 protocol connections. TLS v1 connections are
preferred.
默认值: YES
strict_ssl_read_eof
If enabled, SSL data uploads are required to terminate via SSL,
not an EOF on the socket. This option is required to be sure that
an attacker did not terminate an upload prematurely with a faked
TCP FIN. Unfortunately, it is not enabled by default because so
few clients get it right. (New in v2.0.7).
默认值: NO
strict_ssl_write_shutdown
If enabled, SSL data downloads are required to terminate via SSL,
not an EOF on the socket. This is off by default as I was unable
to find a single FTP client that does this. It is minor. All it
affects is our ability to tell whether the client confirmed full
receipt of the file. Even without this option, the client is able
to check the integrity of the download. (New in v2.0.7).
默认值: NO
syslog_enable
If enabled, then any log output which would have gone to
/var/log/vsftpd.log goes to the system log instead. Logging is
done under the FTPD facility.
默认值: NO
tcp_wrappers
If enabled, and vsftpd was compiled with tcp_wrappers support,
incoming connections will be fed through tcp_wrappers access con‐
trol. Furthermore, there is a mechanism for per-IP based configu‐
ration. If tcp_wrappers sets the VSFTPD_LOAD_CONF environment
variable, then the vsftpd session will try and load the vsftpd
configuration file specified in this variable.
默认值: NO
text_userdb_names
By default, numeric IDs are shown in the user and group fields of
directory listings. You can get textual names by enabling this
parameter. It is off by default for performance reasons.
默认值: NO
tilde_user_enable
If enabled, vsftpd will try and resolve pathnames such as
~chris/pics, i.e. a tilde followed by a username. Note that vsftpd
will always resolve the pathnames ~ and ~/something (in this case
the ~ resolves to the initial login directory). Note that ~user
paths will only resolve if the file /etc/passwd may be found
within the _current_ chroot() jail.
默认值: NO
use_localtime
If enabled, vsftpd will display directory listings with the time
in your local time zone. The default is to display GMT. The times
returned by the MDTM FTP command are also affected by this option.
默认值: NO
use_sendfile
An internal setting used for testing the relative benefit of using
the sendfile() system call on your platform.
默认值: YES
validate_cert
If set to yes, all SSL client certificates received must validate
OK. Self-signed certs do not constitute OK validation. (New in
v2.0.6).
默认值: NO
virtual_use_local_privs
If enabled, virtual users will use the same privileges as local
users. By default, virtual users will use the same privileges as
anonymous users, which tends to be more restrictive (especially in
terms of write access).
默认值: NO
write_enable
可以控制是否允许执行那些用于更改文件系统的FTP命令:STOR, DELE, RNFR, RNTO, MKD, RMD, APPE, SITE。
默认值: NO
数值选项
Below is a list of numeric options. A numeric option must be set to a non
negative integer. Octal numbers are supported, for convenience of the
umask options. To specify an octal number, use 0 as the first digit of
the number.
accept_timeout
The timeout, in seconds, for a remote client to establish connec‐
tion with a PASV style data connection.
默认值: 60
anon_max_rate
The maximum data transfer rate permitted, in bytes per second, for
anonymous clients.
默认值: 0 (unlimited)
anon_umask
The value that the umask for file creation is set to for anonymous
users. NOTE! If you want to specify octal values, remember the “0”
prefix otherwise the value will be treated as a base 10 integer!
默认值: 077
chown_upload_mode
The file mode to force for chown()ed anonymous uploads. (Added in
v2.0.6).
默认值: 0600
connect_timeout
The timeout, in seconds, for a remote client to respond to our
PORT style data connection.
默认值: 60
data_connection_timeout
The timeout, in seconds, which is roughly the maximum time we per‐
mit data transfers to stall for with no progress. If the timeout
triggers, the remote client is kicked off.
默认值: 300
delay_failed_login
The number of seconds to pause prior to reporting a failed login.
默认值: 1
delay_successful_login
The number of seconds to pause prior to allowing a successful
login.
默认值: 0
file_open_mode
The permissions with which uploaded files are created. Umasks are
applied on top of this value. You may wish to change to 0777 if
you want uploaded files to be executable.
默认值: 0666
ftp_data_port
The port from which PORT style connections originate (as long as
the poorly named connect_from_port_20 is enabled).
默认值: 20
idle_session_timeout
The timeout, in seconds, which is the maximum time a remote client
may spend between FTP commands. If the timeout triggers, the
remote client is kicked off.
默认值: 300
listen_port
If vsftpd is in standalone mode, this is the port it will listen
on for incoming FTP connections.
默认值: 21
local_max_rate
The maximum data transfer rate permitted, in bytes per second, for
local authenticated users.
默认值: 0 (unlimited)
local_umask
The value that the umask for file creation is set to for local
users. NOTE! If you want to specify octal values, remember the “0”
prefix otherwise the value will be treated as a base 10 integer!
默认值: 077
max_clients
If vsftpd is in standalone mode, this is the maximum number of
clients which may be connected. Any additional clients connecting
will get an error message.
默认值: 0 (unlimited)
max_login_fails
After this many login failures, the session is killed.
默认值: 3
max_per_ip
If vsftpd is in standalone mode, this is the maximum number of
clients which may be connected from the same source internet
address. A client will get an error message if they go over this
limit.
默认值: 0 (unlimited)
pasv_max_port
The maximum port to allocate for PASV style data connections. Can
be used to specify a narrow port range to assist firewalling.
默认值: 0 (use any port)
pasv_min_port
The minimum port to allocate for PASV style data connections. Can
be used to specify a narrow port range to assist firewalling.
默认值: 0 (use any port)
trans_chunk_size
You probably don’t want to change this, but try setting it to
something like 8192 for a much smoother bandwidth limiter.
默认值: 0 (let vsftpd pick a sensible setting)
字符串选项
Below is a list of string options.
anon_root
在匿名登录后,vsftpd将尝试进入此选项指定的目录。失败被静默地忽略。
默认值: (none)
banned_email_file
This option is the name of a file containing a list of anonymous
e-mail passwords which are not permitted. This file is consulted
if the option deny_email_enable is enabled.
默认值: /etc/vsftpd.banned_emails
ca_certs_file
This option is the name of a file to load Certificate Authority
certs from, for the purpose of validating client certs. The loaded
certs are also advertised to the client, to cater for TLSv1.0
clients such as the z/OS FTP client. Regrettably, the default SSL
CA cert paths are not used, because of vsftpd’s use of restricted
filesystem spaces (chroot). (Added in v2.0.6).
默认值: (none)
chown_username
This is the name of the user who is given ownership of anonymously
uploaded files. This option is only relevant if another option,
chown_uploads, is set.
默认值: root
cmds_allowed
This options specifies a comma separated list of allowed FTP com‐
mands (post login. USER, PASS and QUIT and others are always
allowed pre-login). Other commands are rejected. This is a power‐
ful method of really locking down an FTP server. Example:
cmds_allowed=PASV,RETR,QUIT
默认值: (none)
cmds_denied
This options specifies a comma separated list of denied FTP com‐
mands (post login. USER, PASS, QUIT and others are always allowed
pre-login). If a command appears on both this and cmds_allowed
then the denial takes precedence. (Added in v2.1.0).
默认值: (none)
deny_file
This option can be used to set a pattern for filenames (and direc‐
tory names etc.) which should not be accessible in any way. The
affected items are not hidden, but any attempt to do anything to
them (download, change into directory, affect something within
directory etc.) will be denied. This option is very simple, and
should not be used for serious access control – the filesystem’s
permissions should be used in preference. However, this option may
be useful in certain virtual user setups. In particular aware that
if a filename is accessible by a variety of names (perhaps due to
symbolic links or hard links), then care must be taken to deny
access to all the names. Access will be denied to items if their
name contains the string given by hide_file, or if they match the
regular expression specified by hide_file. Note that vsftpd’s
regular expression matching code is a simple implementation which
is a subset of full regular expression functionality. Because of
this, you will need to carefully and exhaustively test any appli‐
cation of this option. And you are recommended to use filesystem
permissions for any important security policies due to their
greater reliability. Supported regex syntax is any number of *, ?
and unnested {,} operators. Regex matching is only supported on
the last component of a path, e.g. a/b/? is supported but a/?/c is
not. Example: deny_file={*.mp3,*.mov,.private}
默认值: (none)
dsa_cert_file
This option specifies the location of the DSA certificate to use
for SSL encrypted connections.
默认值: (none – an RSA certificate suffices)
dsa_private_key_file
This option specifies the location of the DSA private key to use
for SSL encrypted connections. If this option is not set, the pri‐
vate key is expected to be in the same file as the certificate.
默认值: (none)
email_password_file
This option can be used to provide an alternate file for usage by
the secure_email_list_enable setting.
默认值: /etc/vsftpd.email_passwords
ftp_username
用于处理FTP匿名访问。由ftp_username指定的帐号的Home目录为匿名帐号的根目录。
默认值: ftp
guest_username
See the boolean setting guest_enable for a description of what
constitutes a guest login. This setting is the real username which
guest users are mapped to.
默认值: ftp
hide_file
This option can be used to set a pattern for filenames (and direc‐
tory names etc.) which should be hidden from directory listings.
Despite being hidden, the files / directories etc. are fully
accessible to clients who know what names to actually use. Items
will be hidden if their names contain the string given by
hide_file, or if they match the regular expression specified by
hide_file. Note that vsftpd’s regular expression matching code is
a simple implementation which is a subset of full regular expres‐
sion functionality. See deny_file for details of exactly what
regex syntax is supported. Example: hide_file={*.mp3,.hid‐
den,hide*,h?}
默认值: (none)
listen_address
If vsftpd is in standalone mode, the default listen address (of
all local interfaces) may be overridden by this setting. Provide a
numeric IP address.
默认值: (none)
listen_address6
Like listen_address, but specifies a default listen address for
the IPv6 listener (which is used if listen_ipv6 is set). Format is
standard IPv6 address format.
默认值: (none)
local_root
This option represents a directory which vsftpd will try to change
into after a local (i.e. non-anonymous) login. Failure is silently
ignored.
默认值: (none)
message_file
This option is the name of the file we look for when a new direc‐
tory is entered. The contents are displayed to the remote user.
This option is only relevant if the option dirmessage_enable is
enabled.
默认值: .message
nopriv_user
This is the name of the user that is used by vsftpd when it wants
to be totally unprivileged. Note that this should be a dedicated
user, rather than nobody. The user nobody tends to be used for
rather a lot of important things on most machines.
默认值: nobody
pam_service_name
This string is the name of the PAM service vsftpd will use.
默认值: ftp
pasv_address
Use this option to override the IP address that vsftpd will adver‐
tise in response to the PASV command. Provide a numeric IP
address, unless pasv_addr_resolve is enabled, in which case you
can provide a hostname which will be DNS resolved for you at
startup.
默认值: (none – the address is taken from the incoming connected
socket)
rsa_cert_file
This option specifies the location of the RSA certificate to use
for SSL encrypted connections.
默认值: /usr/share/ssl/certs/vsftpd.pem
rsa_private_key_file
This option specifies the location of the RSA private key to use
for SSL encrypted connections. If this option is not set, the pri‐
vate key is expected to be in the same file as the certificate.
默认值: (none)
ssl_ciphers
This option can be used to select which SSL ciphers vsftpd will
allow for encrypted SSL connections. See the ciphers man page for
further details. Note that restricting ciphers can be a useful
security precaution as it prevents malicious remote parties forc‐
ing a cipher which they have found problems with.
默认值: DES-CBC3-SHA
user_config_dir
This powerful option allows the override of any config option
specified in the manual page, on a per-user basis. Usage is sim‐
ple, and is best illustrated with an example. If you set user_con‐
fig_dir to be /etc/vsftpd_user_conf and then log on as the user
“chris”, then vsftpd will apply the settings in the file
/etc/vsftpd_user_conf/chris for the duration of the session. The
format of this file is as detailed in this manual page! PLEASE
NOTE that not all settings are effective on a per-user basis. For
example, many settings only prior to the user’s session being
started. Examples of settings which will not affect any behviour
on a per-user basis include listen_address, banner_file,
max_per_ip, max_clients, xferlog_file, etc.
默认值: (none)
user_sub_token
This option is useful is conjunction with virtual users. It is
used to automatically generate a home directory for each virtual
user, based on a template. For example, if the home directory of
the real user specified via guest_username is /home/virtual/$USER,
and user_sub_token is set to $USER, then when virtual user fred
logs in, he will end up (usually chroot()’ed) in the directory
/home/virtual/fred. This option also takes affect if local_root
contains user_sub_token.
默认值: (none)
与「匿名访问」有关的参数
allow_anon_ssl
Only applies if ssl_enable is active. If set to YES, anonymous
users will be allowed to use secured SSL connections.
默认值: NO
anon_mkdir_write_enable
YES: 某些特定的条件下,允许匿名用于创建文件夹。
为了使此功能能正常工作,需要设置write_enable=YES,并且匿名的ftp用户必须在父级目录具有写权限。
默认值: NO
anon_other_write_enable
If set to YES, anonymous users will be permitted to perform write
operations other than upload and create directory, such as dele‐
tion and renaming. This is generally not recommended but included
for completeness.
默认值: NO
anon_upload_enable
如果设置为YES,匿名用户将被允许在特定条件下上传文件。
为了使其正常,必须使write_enable=YES,并且匿名ftp用户必须具有所上传位置的写入权限。
虚拟用户进行上传也需要设置此选项;默认情况下,虚拟用户以匿名对待。
默认值: NO
anon_world_readable_only
When enabled, anonymous users will only be allowed to download
files which are world readable. This is recognising that the ftp
user may own files, especially in the presence of uploads.
默认值: YES
anonymous_enable
是否允许匿名帐号登录。
如果启用(YES),用户名ftp和anonymous将被识别为匿名登录。
默认值: YES
控制帐号是否可以登录
userlist_enable
如果启动,vsftpd将会读取userlist_file参数指定的文件。
默认值: NO
userlist_file
当userlist_enable=YES时,会读取该选项指定的文件名。文件中的内容为一个用户名列表。具体含义取决于userlist_deny的值。
这可能有助于防止正在发送的明文密码。
默认值: /etc/vsftpd.user_list
userlist_deny
userlist_enable=YES时,此选项才有效。该选项,取值不同含义不同:
- YES:拒绝所有userlist_file选项指定的文件中的用户登录。
- NO:拒绝所有用户登录,只有userlist_file指定的文件中的用户才可以登录。
默认值: YES
控制帐号登录之后的根目录
chroot_local_user
YES:用户登录之后,家目录为用户的根目录。
NO:登录的用户可以访问任何目录。
警告:此选项具有安全隐患,特别是如果用户具有上传权限或shell访问权限。要清楚自己在做什么。
注意:这些安全隐患不是vsftpd具体的。它们适用于提供将本地用户置于chroot() jail中的所有FTP守护程序。
默认值: NO
chroot_list_enable
如果为YES,需要提供一份用户列表文件(即chroot_list_file指定的文件),这些用户具有特殊含义,详情查看chroot_list_file选项。
默认值: NO
chroot_list_file
只有chroot_list_enable=YES之后,该选项才有效。
该选项指定的文件中包含的是一个用户列表,实际的含义取决于chroot_local_user的值:
- 如果chroot_local_user=NO:这些用户会被chroot()限制在家目录中。
- 如果chroot_local_user=YES,那么列表中的用户为不进入chroot()的用户。
默认值: /etc/vsftpd.chroot_list
passwd_chroot_enable
If enabled, along with chroot_local_user , then a chroot() jail
location may be specified on a per-user basis. Each user’s jail is
derived from their home directory string in /etc/passwd. The
occurrence of /./ in the home directory string denotes that the
jail is at that particular location in the path.
默认值: NO
secure_chroot_dir
该选项的值应该是一个空文件夹的名字,且对于FTP用户来讲,该文件夹是不可写入的。
在vsftpd不需要文件系统访问,此目录用作安全chroot()“监狱”。
默认值: /usr/share/empty
FTP登录问候语言
FTP登录时给出的问候语。
ftpd_banner
用于覆盖连接时由vsftpd显示的问候语。
默认值: (none – default vsftpd banner is displayed)
banner_file
参数值为一个文件名,该文件中包含了FTP登录成功后显示的欢迎信息。如果设置了该文件,将会覆盖ftpd_banner选项提供的字符串。
默认值: (none)
日志相关的参数
vsftpd_log_file
This option is the name of the file to which we write the vsftpd
style log file. This log is only written if the option xfer‐
log_enable is set, and xferlog_std_format is NOT set. Alterna‐
tively, it is written if you have set the option dual_log_enable.
One further complication – if you have set syslog_enable, then
this file is not written and output is sent to the system log
instead.
默认值: /var/log/vsftpd.log
xferlog_file
This option is the name of the file to which we write the wu-ftpd
style transfer log. The transfer log is only written if the option
xferlog_enable is set, along with xferlog_std_format. Alterna‐
tively, it is written if you have set the option dual_log_enable.
默认值: /var/log/xferlog
xferlog_enable
If enabled, a log file will be maintained detailling uploads and
downloads. By default, this file will be placed at
/var/log/vsftpd.log, but this location may be overridden using the
configuration setting vsftpd_log_file.
默认值: NO (but the sample config file enables it)
xferlog_std_format
If enabled, the transfer log file will be written in standard
xferlog format, as used by wu-ftpd. This is useful because you can
reuse existing transfer statistics generators. The default format
is more readable, however. The default location for this style of
log file is /var/log/xferlog, but you may change it with the set‐
ting xferlog_file.
默认值: NO
参考文献
man 5 vsftpd.conf