unable to execute chroot cmd line
Brought to you by:
xystrus
From: Maxim A. <m.a...@eq...> - 2003-10-21 10:06:26
|
Hi, I've installed rssh typicaly, created test user test3 cat /etc/passwd ... test3:x:101:102::/home/test3:/bin/bash as was written in SECURITY, test3 user is not an owner of /home/test3 dir(nor .ssh dir in it) i've owned /home/test3 to root.test -R where test is a group that includes user test3, but test is allowed to read only for that dir. copied to /home/test3/.ssh/authorized_keys public key from remote client and tested if it is working... from client machine: /usr/local/openssh/bin/scp -S /usr/local/openssh/bin/ssh test3@SERVER_IP_ADDRESS:/test /tmp/ test 100% 4 0.0KB/s 00:00 file test is exist both in / and in future /chrootdir changed line in /etc/passwd test3:x:101:102::/home/test3:/usr/local/bin/rssh changed /usr/local/etc/rssh.conf user=test3:101:11:"/test3" created a chrootdir, caled /test3, as i've used prefix(=/usr/local/openssh-3.7p1) to configure openssh, i've copied: /test3/usr/local/openssh-3.7p1/bin/scp (and all libs to their folder relative to /test3) /test3/usr/local/openssh-3.7p1/libexec/sftp-server (and all libs to their folder relative to /test3) and /test3/usr/local/libexec/rssh_chroot_helper (default, linked staticaly) from client machine trying to copy file with the same command nothing... adding -v option for scp and see the debug: OpenSSH_3.7p1, SSH protocols 1.5/2.0, OpenSSL 0.9.7b 10 Apr 2003 ... (previous debug line is ok) debug1: Sending command: scp -v -f /test debug1: client_input_channel_req: channel 0 rtype exit-status reply 0 debug1: channel 0: free: client-session, nchannels 1 debug1: fd 0 clearing O_NONBLOCK debug1: fd 1 clearing O_NONBLOCK debug1: Transferred: stdin 0, stdout 0, stderr 0 bytes in 0.1 seconds debug1: Bytes per second: stdin 0.0, stdout 0.0, stderr 0.0 debug1: Exit status 1 at server cat /var/log/messages Oct 21 13:20:18 ares sshd[13727]: Accepted publickey for test3 from CLIENT_IP_ADDRESS port 2906 ssh2 Oct 21 13:20:18 ares rssh[13730]: setting log facility to LOG_USER Oct 21 13:20:18 ares rssh[13730]: setting umask to 022 Oct 21 13:20:18 ares rssh[13730]: line 37: configuring user test3 Oct 21 13:20:18 ares rssh[13730]: setting test3's umask to 0101 Oct 21 13:20:18 ares rssh[13730]: allowing scp to user test3 Oct 21 13:20:18 ares rssh[13730]: allowing sftp to user test3 Oct 21 13:20:18 ares rssh[13730]: chrooting test3 to /test3 Oct 21 13:20:18 ares rssh[13730]: chroot cmd line: /usr/local/libexec/rssh_chroot_helper "/test3" 1 "/" scp -v -f /test here i don't know what to do.... -- Maxim N. Areschenko &Equant, Russia e-mail: m.a...@eq... Phone: +7-095-9299500 (int: 5476) |