LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 05-18-2005, 10:44 PM   #1
aje
Member
 
Registered: Oct 2004
Location: Internet
Distribution: Slackware 10.1
Posts: 177

Rep: Reputation: 30
Allowing user access to one directory only


How can I create an account (let's call the account "guest") that only has access to a single folder? I have just set up an ftp server, and I want to be able to give certain people a password so they can log in via ftp://guest: passwd@hostname.domain.org. I have created the account, and accessed ftp with firefox (crude, I know, but most of my friends are basic windows users). This took me to the home folder for guest, but when I clicked on "up to higher directory" I realized that I could browse almost all of my filesystem. This is obviously not very secure ... even if only trusted friends had access to the account.

How can I restrict the guest acces to a single folder?


edit: auto smileys
 
Old 05-18-2005, 11:01 PM   #2
wpyh
Member
 
Registered: Jun 2004
Location: Beijing
Distribution: Slackware 9.1 but FUBAR with packages I compile myself, and OpenBSD (not exactly a distro) on QEMU
Posts: 153

Rep: Reputation: 35
What ftp server are you using?

edit: I can't reproduce it here with vsftpd.

Last edited by wpyh; 05-18-2005 at 11:03 PM.
 
Old 05-19-2005, 01:51 PM   #3
Dr. Psy
Member
 
Registered: May 2005
Distribution: Slackware 10.1
Posts: 49

Rep: Reputation: 15
If you are using proftpd, just add

DefaultRoot ~

to your /etc/proftpd.conf file, in the global section
 
Old 05-19-2005, 07:45 PM   #4
aje
Member
 
Registered: Oct 2004
Location: Internet
Distribution: Slackware 10.1
Posts: 177

Original Poster
Rep: Reputation: 30
I followed shilo's slackware guide in setting up FTP, and according to the line I uncommented in /etc/inetd.conf, it looks like I'm using proftpd.

I cannot find the global section ih proftpd.conf
 
Old 05-19-2005, 08:09 PM   #5
gbonvehi
Senior Member
 
Registered: Jun 2004
Location: Argentina (SR, LP)
Distribution: Slackware
Posts: 3,145

Rep: Reputation: 53
The global section is when you're outside a section delimited with some tag like <Directory> </Directory>.
A easy way, just add a line at the end of the file with DefaultRoot ~
 
Old 05-25-2005, 08:12 PM   #6
aje
Member
 
Registered: Oct 2004
Location: Internet
Distribution: Slackware 10.1
Posts: 177

Original Poster
Rep: Reputation: 30
Thank you. But does this mean all users can only access their home directory when using ftp?
 
  


Reply



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
allowing rsh access uerden Linux - Networking 5 11-08-2006 02:15 PM
can not access directory from user account - only root walterbyrd Linux - General 1 03-04-2005 11:23 PM
Directory access denied to root user: inode hack? netmar Linux - Security 2 07-31-2004 04:53 AM
GFTP allowing Root access to an FTP user scottpioso Red Hat 2 01-07-2004 06:20 PM
How to assign directory access to a user linuxfans Linux - General 7 04-16-2003 12:06 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 04:34 AM.

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