#24 chroot() in 5.0_r1

open
nobody
None
5
2009-01-29
2009-01-29
Doug Eckert
No

Trying to jail user(s) into their home directories. Seem to have everything set up properly, and can manually chroot from command line. In sshd_config I've got

Match user dj999999
ChrootDirectory /home/chroot

But when the user (dj999999) attempts an ssh login, 'sshd -dd' shows the following before the conenction is torn down:

debug2: User child is on pid 196688
debug1: PAM: establishing credentials
debug1: TMP*****************:/home/chroot
debug1: CHROOT_PATH*********:/home/chroot
debug1: pw->pw_name:dj999999::pw->pw_dir:/home/chroot/./home/dj999999/
chroot("/home/chroot"): Operation not permitted.
debug1: do_cleanup
debug1: do_cleanup
debug1: PAM: cleanup
debug1: PAM: deleting credentials
debug1: PAM: closing session
debug1: audit event euid 0 user dj999999 event 12 (SSH_connabndn)
debug1: Return Val-1 for auditproc:0

Is chroot not implemented (yet)? If not, when?

Discussion