Last active
July 20, 2017 04:37
-
-
Save devifr/c42d2c1ab5b6660702cb8ff3e9f8df61 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FTP | |
sudo apt-get update | |
sudo apt-get install vsftpd | |
systemctl start vsftpd | |
systemctl enable vsftpd | |
sudo vim /etc/vsftpd.conf | |
add vcode in | |
anonymous_enable=NO # disable anonymous login | |
local_enable=YES # permit local logins | |
write_enable=YES # enable FTP commands which change the filesystem | |
file_open_mode=0777 | |
local_umask=022 # value of umask for file creation for local users | |
dirmessage_enable=YES # enable showing of messages when users first enter a new directory | |
xferlog_enable=YES # a log file will be maintained detailing uploads and downloads | |
connect_from_port_20=YES # use port 20 (ftp-data) on the server machine for PORT style connections | |
xferlog_std_format=YES # keep standard log file format | |
listen=NO # prevent vsftpd from running in standalone mode | |
listen_ipv6=YES # vsftpd will listen on an IPv6 socket instead of an IPv4 one | |
pam_service_name=ftp # name of the PAM service vsftpd will use | |
systemctl restart vsftpd | |
SFTP | |
sudo apt-get install openssh-server | |
add code in /etc/ssh/sshd_config | |
PasswordAuthentication yes | |
Subsystem sftp /usr/lib/openssh/sftp-server | |
then | |
sudo service ssh restart |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment