Solved

vsFTPd

Posted on 2004-03-27
3
497 Views
Last Modified: 2010-03-18
Let me Start by saying Im very new to linux I was hosting a FTP server in Windows using
3rd party software (Ability Server) also has SMTP,HTTP servers. Now I would like to let my
Linux box host these services.  So one server at a time Starting with FTP.
I have the anonymous option working and the Accunts on my local box to work now I need
to have a user that does not have a local login to be able to accss the server .

I'm running RedHat 9 with vsFTPd
What I need is

say a username of: username
when they log in I want them to go to  /var/somefolder

how do I create a user that can not log on localy but can on ftp ?
will they then have access to a shell ?
and has the home of /var/somefolder
0
Comment
Question by:mbosco
3 Comments
 

Author Comment

by:mbosco
ID: 10696562
what login script should i use ?
0
 
LVL 44

Accepted Solution

by:
Karl Heinz Kremer earned 250 total points
ID: 10696634
Yes, you can do this. The keyword is "virtual users". If you have the vsftpd sources, there is a directory EXAMPLE/VIRTUAL_USERS that has a sample configuration for this.

This page also has an explanation about how this works: http://www.vsftpdrocks.org/faq/ (about half way down the page).

These virtual users will not be able to log into the system, because they don't have an entry in the /etc/password file.
0
 
LVL 2

Expert Comment

by:PaulS_III
ID: 10723568
I have had success in adding users this way:

useradd -g somegroup -d /home/username -s /bin/false username

This will create the user's home directory but not allow them to actually login to a shell. The -s /bin/false can vary depending on the flavor of linux you are using. In fact, for RedHat I fairly certain you can use /bin/false or /sbin/nologin.

Hope that helps :)

Paul
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
Note: for this to work properly you need to use a Cross-Over network cable. 1. Connect both servers S1 and S2 on the second network slots respectively. Note that you can use the 1st slots but usually these would be occupied by the Service Provide…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

827 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question