2013年8月5日月曜日

sshでchrootされたsftp専用アカウントの作り方

sshd_configを編集する

  Match User sftpuser
      AllowTcpForwarding no
      ChrootDirectory /home/chroot
      ForceCommand internal-sftp
      PasswordAuthentication yes
      X11Forwarding no

注意点としてはsftpuserは/home/chrootに書き込み権限を持たせないこと
そうしないとうまくいかない

0 件のコメント: