・vsftpd のインストール
[root@alma]# dnf -y install vsftpd
・vsftpd の設定
[root@alma]# vi /etc/vsftpd/vsftpd.conf
≪ 途中省略 ≫
# By default the server will pretend to allow ASCII mode but in fact ignore
# the request. Turn on the below options to have the server actually do ASCII
# mangling on files when in ASCII mode. The vsftpd.conf(5) man page explains
# the behaviour when these options are disabled.
# Beware that on some FTP servers, ASCII support allows a denial of service
# attack (DoS) via the command "SIZE /big/file" in ASCII mode. vsftpd
# predicted this attack and has always been safe, reporting the size of the
# raw file.
# ASCII mangling is a horrible feature of the protocol.
#ascii_upload_enable=YES
↓※コメント解除 ascil アップロードを許可
ascii_upload_enable=YES
#ascii_download_enable=YES
↓※コメント解除 ascil ダウンロードを許可
ascii_download_enable=YES
≪ 途中省略 ≫
# You may specify an explicit list of local users to chroot() to their home
# directory. If chroot_local_user is YES, then this list becomes a list of
# users to NOT chroot().
# (Warning! chroot'ing can be very dangerous. If using chroot, make sure that
# the user does not have write access to the top level directory within the
# chroot)
#chroot_local_user=YES
↓※コメント解除 ホームディレクトリ以外へのアクセスを許可しな
chroot_local_user=YES
#chroot_list_enable=YES
↓※コメント解除 FTP 接続ユーザーを指定する
chroot_list_enable=YES
# (default follows)
#chroot_list_file=/etc/vsftpd/chroot_list
↓※コメント解除 FTP 接続ユーザーのリストの場所
chroot_list_file=/etc/vsftpd/chroot_list
#
# You may activate the "-R" option to the builtin ls. This is disabled by
# default to avoid remote users being able to cause excessive I/O on large
# sites. However, some broken FTP clients such as "ncftp" and "mirror" assume
# the presence of the "-R" option, so there is a strong case for enabling it.
#ls_recurse_enable=YES
↓※コメント解除 ディレクトリの作成・削除できるようにする
ls_recurse_enable=YES
≪ 途中省略 ≫
use_localtime=YES※文末に追記 ローカル時間で表示する
・FTP 接続ユーザーのリスト
[root@alma]# vi /etc/vsftpd/chroot_list
以下新規記述
xxxxxx※登録してあるユーザー名を記述する
******※そのユーザーのパスワードでログインする