View previous topic :: View next topic |
Author |
Message |
cbock Tux's lil' helper
![Tux's lil' helper Tux's lil' helper](/images/ranks/rank_rect_1.gif)
Joined: 16 Apr 2004 Posts: 149 Location: san diego
|
Posted: Wed Jun 16, 2004 1:10 am Post subject: configuring sftp for users |
|
|
maybe i'm not asking the right questions. but, it seems simple enough. i don't want to have an ftp server running. i'd like a limited number of people to have the ability to upload and download to a given folder. sounds like sftp via ssh. however, after an account is created, the new user can log in using an ftp client. they start at /home/theiraccount, but, they can then go back to / and just about anywhere else. am i missing something in the user permission |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
sak102010 Tux's lil' helper
![Tux's lil' helper Tux's lil' helper](/images/ranks/rank_rect_1.gif)
![](images/avatars/154200113340b69d8d564ca.png)
Joined: 08 Jun 2003 Posts: 82
|
Posted: Wed Jun 16, 2004 2:45 am Post subject: |
|
|
Your post is a little confusing. Let me see if I can help.
First, sftp is just a subsystem for ssh. It allows one the same permissions their regular shell account would have, but with the ability to upload and download files. A regular FTP client shouldn't be able to access your machine, unless it has sftp - or scp - client capabilities. It would have to first make an ssh connection, and then start an sftp subsystem request for the user.
If, on the other hand, you're running another, traditional FTP server on your system, then any FTP client application will be able to access the server.
If you're not running any other, traditional FTP server, then what you're experiencing with sftp is normal. What you can look into doing, however, is setting up a secure FTP daemon, such as VSFTP, or you can configure your ssh daemon on the server to do chroot jails for the users that log in. VSFTP's daemon comes with chroot capability, so it's a little easier to setup. Basically what you get is that when users log in, they can only mess around in their own directory, and no other.
Hope that helps. _________________ Thanks,
Sak |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
splooge l33t
![l33t l33t](/images/ranks/rank_rect_4.gif)
Joined: 30 Aug 2002 Posts: 636
|
Posted: Wed Jun 16, 2004 3:02 am Post subject: |
|
|
ssh secures the connection, not the box itself.
creating a chroot 'jail' that a user can't leave is possible, but slightly difficult. Imagine: if a user isn't allowed to leave his home dir: how does he execute `/bin/ls` ?
The default file and directory permissions will prevent users from doing things they shouldn't. _________________ http://get.a.clue.de |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
jftuga Tux's lil' helper
![Tux's lil' helper Tux's lil' helper](/images/ranks/rank_rect_1.gif)
Joined: 21 Jan 2004 Posts: 139 Location: Athens, GA
|
Posted: Wed Jun 16, 2004 3:18 am Post subject: |
|
|
I do not know if this is applicable for your situation or not. If you want to allow just scp and/or sftp access w/o giving ssh shell access, then you might want to look into a program called rssh at http://www.pizzashack.org/rssh/index.shtml
I use this and it works very well. It has chroot capability, but I do not use it myself. Their documentation talks about how to set up a chroot environment, including programs like ls.
-John |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
cbock Tux's lil' helper
![Tux's lil' helper Tux's lil' helper](/images/ranks/rank_rect_1.gif)
Joined: 16 Apr 2004 Posts: 149 Location: san diego
|
Posted: Wed Jun 16, 2004 6:44 am Post subject: |
|
|
thanks for your thought out post sak. thanks also splooge and jftuga. i'll take another look at vsftp. it didn't seem like it was configurable enough. proftp seems to get enough complaints around here. so, i thought i could muck with sftp enough to get it to do what i wanted. i will, instead try to get vsftp working the way i want.
thanks again. |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
cbock Tux's lil' helper
![Tux's lil' helper Tux's lil' helper](/images/ranks/rank_rect_1.gif)
Joined: 16 Apr 2004 Posts: 149 Location: san diego
|
Posted: Thu Jun 17, 2004 3:59 pm Post subject: |
|
|
update:
i've gone back to sftp. i decided that i could live with it the way it is. i did try to get scponly working. but, i ran into problems there too. so, sftp it is. |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
etrek n00b
![n00b n00b](/images/ranks/rank_rect_0.gif)
Joined: 23 Jun 2002 Posts: 58
|
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
cbock Tux's lil' helper
![Tux's lil' helper Tux's lil' helper](/images/ranks/rank_rect_1.gif)
Joined: 16 Apr 2004 Posts: 149 Location: san diego
|
Posted: Thu Jun 17, 2004 6:20 pm Post subject: |
|
|
thanks etrek. i found that thread searching but didn't give it a try.
i just followed the directions and it does a nice enough job. ![Smile :)](images/smiles/icon_smile.gif) |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
|