set up problem on FreeBSD-10.3
Brought to you by:
xystrus
From: Adam J. <ha...@ri...> - 2016-10-05 02:58:51
|
My step-by-step process is posted here - https://forums.freebsd.org/threads/57935/ Basically, I do this: sudo pkg install rssh sudo pw groupadd -n rsshuser sudo chown root:rsshuser /usr/local/bin/rssh sudo chown root:rsshuser /usr/local/libexec/rssh_chroot_helper sudo chmod 4550 /usr/local/libexec/rssh_chroot_helper sudo pw useradd -n banks -d /usr/local/chroot/banks -g rsshuser \ -s /usr/local/bin/rssh sudo mkdir -p /usr/local/chroot/banks sudo chown banks:rsshuser /usr/local/chroot/banks sudo passwd banks sudo vi /usr/local/etc/rssh.conf logfacility=LOG_USER umask=022 chrootpath=/usr/local/chroot user=banks:022:10011:/usr/local/chroot/banks But when I test it with: scp blah ba...@mi...:/ Password for ba...@mi...: rssh_chroot_helper: wordexp() bad syntax lost connection The same thing also happen for: scp blah ba...@is...:/banks/ scp blah ba...@is...:~ scp blah ba...@is...:/usr/local/chroot/banks/ Curiously, with this modification to /usr/local/etc/rssh.conf logfacility=LOG_USER umask=022 chrootpath=/usr/local/chroot user=banks:022:10011: #user=banks:022:10011:/usr/local/chroot/banks Then, scp blah ba...@is...:/banks/ Password for ba...@mi...: scp: /banks/: Permission denied scp blah ba...@is...:/usr/local/chroot/banks/ Password for ba...@mi...: blah 100% 17 0.0KB/s 00:00 That copied the file but the chroot facility isn't working. If Filezilla is used to sftp into ba...@mi..., the entire file system can be viewed. Any ideas? |