System Engineering

Enable SFTP Logging on OpenSUSE

Posted on

1. Update rsyslog(syslog) configuration vi /etc/rsyslog.conf #sftp logging local5.* -/var/log/sftpd.log service rsyslog restart 2. SSHD Configuration file vi /etc/ssh/sshd_config Subsystem sftp /usr/lib/ssh/sftp-server -f LOCAL5 -l INFO service sshd restart  

System Engineering

Chroot for SFTP on OpenSUSE

Posted on

1. Add chroot to SSHD Configuration file vi /etc/ssh/sshd_config Match Group uploaders,!admin X11Forwarding no AllowTcpForwarding no ForceCommand internal-sftp ChrootDirectory /home/uploaders Match User cacti Address *,!10.10.1.0/24 ForceCommand /bin/false 2. Mount directory to home directory vi /etc/fstab /home/www/www.mysite.com /home/uploaders/www.mysite.com none bind 0 0