Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

sftp and chroot

New to Debian (Or Linux in general)? Ask your questions here!
Post Reply
Message
Author
arjena
Posts: 1
Joined: 2020-02-23 14:29

sftp and chroot

#1 Post by arjena »

Hi there.
I am experimenting with a server running Debian. It should replace my aging Apple server (and since the new Apple server is not a server anymore that is no longer an option).
So far everything goes fine, but I have a problem placing a user in chroot jail for sftp access. I am following this guide: https://www.thegeekstuff.com/2012/03/chroot-sftp-setup/
This goes well, but when I connect with a ftp client (cyberduck in this case) I arrive in the folder /sftp/guestuser/. I am not able to do anything in this folder, therefore (still following the guide) there is a folder 'incoming' inside the /sftp/guestuser directory where I can put/get files etc. But I know this will be confusing to my clients. They just want to log in to a given sftp address and put/get the files they want.
I have played around a bit with permissions and ownerships but I cannot find a way to get directly to the directory where i can actually do something.
After following the guide the guestuser directory that I go to after sftp-ing to the server has root:root ownership, the 'incoming' directory is guestuser:sftpusers, where sftpusers is the chrooted group for sftp in sshd_config.
The guide is from 2012, but I guess the principles are still the same...

Post Reply