chroot patch for OpenSSH

| | Comments (0)

chroot patch for OpenSSH 可以讓 OpenSSH 有 chroot 功能
裝好後, 參考 Setting up chrooted sftp in linux 建造 user 的 chroot 環境, 再把 user 的 home 設為 /home/user/./home/user
範例: 把使用者 linux 設為 chroot
cd /home/linux
mkdir -p bin dev lib home/linux
cp /bin/bash /bin/ls /bin/mkdir /bin/mv /bin/rm /bin/rmdir bin
mknod dev/zero c 13 12
mknod dev/null c 13 2
cp -a /lib/libc* /lib/libdl* /lib/libtermcap* /lib/ld* lib
usermod -d /home/linux/./home/linux linux

Leave a comment

March 2009

Sun Mon Tue Wed Thu Fri Sat
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20 21
22 23 24 25 26 27 28
29 30 31        

About this Entry

This page contains a single entry by Pank published on September 28, 2005 4:56 PM.

sftp logging patch for OpenSSH was the previous entry in this blog.

Use strings to get Windows file properties is the next entry in this blog.

Find recent content on the main index or look in the archives to find all content.