LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Enterprise Linux Forums > Linux - Enterprise
User Name
Password
Linux - Enterprise This forum is for all items relating to using Linux in the Enterprise.

Notices


Reply
  Search this Thread
Old 12-26-2007, 03:19 AM   #1
manoj.linux
Member
 
Registered: Aug 2007
Posts: 284

Rep: Reputation: 17
Question access control list


Hi,

I am facing problem setting access control list on folder,

My requirement is as follows I want that User B should access files in the directory /home/userA/"Test",but when new files are created in the /home/userA/Test user B is not able to access those files,Old files are accessed by UserB
 
Old 01-02-2008, 04:08 PM   #2
SonJelfn
Member
 
Registered: Aug 2003
Location: Sendai, Japan
Distribution: Slackware, Slackware64, Debian
Posts: 63

Rep: Reputation: 17
Hello,

I am assuming that there are only 2 users for your problem. If that is so then you can do a recursive setfacl for userB and then make sure that your userA has a restrictive umask.

Of course, it would help to know if both users are in the same group but if they aren't you could do something like the following:

Set the folder readable by userB:
Code:
setfacl -m u:userB:rx /home/userA/Test
Set the contents of /home/userA/Test readable to userB:
Code:
setfacl -Rm u:userB:r /home/userA/Test/*
If the umask of userA is 077 you'll have what you were asking for, assuming that all my assumptions are correct because anything created by userA will only be readable by him.

To make this work you have to have acls enabled in the running kernel and make sure that the filesystem on which you want to do this is has the acl option set when mounting.

I hope this helps.

Good luck!
 
  


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
Access Control List over Network File System not visible ORBiTrus Linux - Server 1 04-29-2007 09:32 PM
Access Control list sheetu Solaris / OpenSolaris 1 08-07-2006 05:18 AM
Using access control list tuananhbirm Linux - General 3 04-17-2006 12:33 AM
LXer: ACL(Access Control List) Configuration in Debian LXer Syndicated Linux News 0 03-31-2006 11:12 PM
win2k Printer Access control list problem zepplin611 General 0 01-29-2004 11:09 PM

LinuxQuestions.org > Forums > Enterprise Linux Forums > Linux - Enterprise

All times are GMT -5. The time now is 01:12 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