LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 02-12-2012, 11:51 AM   #1
thor2
LQ Newbie
 
Registered: Feb 2012
Posts: 3

Rep: Reputation: Disabled
SFTP server


Hello,
I need to set a server up for users to be able to upload files with sftp and with certificate based authentication.
The users shouldnt be able to open terminals, browse the directory structure or anything like that, only upload files to a folder and rename them to another folder when upload is complete.

how can the server be set up for this purpuse without allowing ssh and ideally with account management separate from the OS?

was looking at vsftpd but I cant figure out whether this is supported and how.

Help appreciated!
 
Old 02-12-2012, 12:04 PM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
well you need to work out if you want ftp or sftp. sftp is a subsystem of ssh, and is not compatible with ftp at all. vsftpd with a chroot jail can definitely do exactly what you want, and sftp can also do what you want, but they are not the same thing. Actually, I'm not sure how easy it is to use virtual users in ssh, but it's a very standard thing with servers like vsftpd.
 
1 members found this post helpful.
Old 02-12-2012, 12:50 PM   #3
thor2
LQ Newbie
 
Registered: Feb 2012
Posts: 3

Original Poster
Rep: Reputation: Disabled
I want sftp.

Which rules out vsftpd is what you are saying, right?
 
Old 02-12-2012, 12:57 PM   #4
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
yes, sftp would just about exclusively provided by OpenSSH. You could authenticate from a secondary source with ssh, however it would, as I understand the architectures, it would have to be the same authentication as SSH in general, which would probably be an issue. a separate instance of ssh might suffice, but you've need to change the pam service name, which I've never looked into to know if it's feasible at all.
 
1 members found this post helpful.
Old 02-12-2012, 01:17 PM   #5
wpeckham
LQ Guru
 
Registered: Apr 2010
Location: Continental USA
Distribution: Debian, Ubuntu, RedHat, DSL, Puppy, CentOS, Knoppix, Mint-DE, Sparky, VSIDO, tinycore, Q4OS,Manjaro
Posts: 5,591

Rep: Reputation: 2689Reputation: 2689Reputation: 2689Reputation: 2689Reputation: 2689Reputation: 2689Reputation: 2689Reputation: 2689Reputation: 2689Reputation: 2689Reputation: 2689
sftp only with jails

You need to google a bit to find them, but there are a TON of pages on how to do exactly this with different versions of OpenSSH. You do NOT need any other software, OpenSSH has all you need.

Example:
http://adamsworld.name/chrootjailv5.php
http://www.debian-administration.org/articles/590
http://www.howtoforge.com/chrooted-s...l-debian-lenny
 
1 members found this post helpful.
Old 02-13-2012, 02:42 PM   #6
thor2
LQ Newbie
 
Registered: Feb 2012
Posts: 3

Original Poster
Rep: Reputation: Disabled
Thanks for guiding me in the right direction, Got it running with certificates and all.
 
Old 02-14-2012, 02:35 AM   #7
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
oh, nice. Where is your user base kept?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Sftp connection between Windows server and linux server vikash.thbs Linux - Server 2 01-02-2012 10:25 AM
Sftp server saran_redhat Linux - Newbie 2 12-03-2010 07:43 AM
cannot login into SFTP server using Net::SFTP cccc Programming 1 10-31-2007 06:23 AM
sftp-server sopiaz57 Linux - Networking 10 01-05-2004 10:34 AM
Files truncated by sftp/sftp-server at 65kb gato Linux - Networking 1 12-18-2003 10:29 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 07:48 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration