Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- sftp webadm@<ip>:
- webadm@<ip>'s password:
- Connected to <ip>.
- Changing to: /
- sftp> ls
- remote readdir("/"): Permission denied
- sftp>
- /etc/ssh/sshd_config
- Subsystem sftp internal-sftp
- Match Group sftponly
- ChrootDirectory %h
- ForceCommand internal-sftp
- AllowTcpForwarding no
- PermitTunnel no
- X11Forwarding no
- useradd webadm
- passwd webadm
- groupadd sftponly
- gpasswd -a webadm sftponly
- usermod -g sftponly webadm
- groups webadm
- webadm : sftponly
- ll /home/
- drwx------+ 5 root root 4096 May 31 23:49 webadm
- ll /home/webadm/
- -rw-r--r--. 1 webadm sftponly 5 May 31 23:34 test
- getfacl /home/webadm/
- getfacl: Removing leading '/' from absolute path names
- # file: home/webadm/
- # owner: root
- # group: root
- user::rwx
- group::---
- mask::---
- other::---
- setfacl -m u:webadm:rwx /home/webadm/
- Match User webadm
- ChrootDirectory /home/webadm
- AllowAgentForwarding no
- X11Forwarding no
- AllowTcpForwarding no
- #PermitTTY no
- ForceCommand internal-sftp
- PermitTunnel no
- Accepted password for webadm from <ip> port 19669 ssh2
- pam_unix(sshd:session): session opened for user webadm by (uid=0)
- sshd_selinux_copy_context: getcon failed with Permission denied [postauth]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement