LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 04-01-2006, 11:30 PM   #1
HGeneAnthony
Member
 
Registered: Mar 2003
Posts: 178

Rep: Reputation: 30
Posix ACLs are only working on directories


I started using posix ACL and one thing I've noticed is that the directories are overridding any permissions I set on individual files. For example /shared gives the user rwx rights, however inside the folder I set the file to only give the user rx permission. They were still able to delete it. I've tried a couple methods for this including giving the user rx permission to the parent but rwx permission on the file and this wouldn't let them delete. I tried setting permissions on the group for access to the file but specific user ACLs on the inividual files but no matter what I do this is using the parents ACL. Is there some way to ignore the parent permissions or at least use the ones on the file. I haven't seen any articles that address this.
 
Old 04-02-2006, 07:51 AM   #2
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
If you're going to describe problems with using POSIX ACL please post getfacl output for dirs/files you talk about. Easier to read.
 
Old 04-07-2006, 08:07 AM   #3
HGeneAnthony
Member
 
Registered: Mar 2003
Posts: 178

Original Poster
Rep: Reputation: 30
Problem with Posix ACL on files

I've been working with Posix ACL and the problem I'm having is that any files in a directory are inheriting the parent folder's ACL and ignoring the ACL I set specifically on it. For example say I have a user named geneanthony and I want him to have read/write/execute permission on the parent directory. I set it as so:

setfacl -m u:geneanthony:rwx foldername

When I getfacl on the folder I get:

file: foldername
owner: root
group: root
user:: rwx
user: geneanthony:rwx
group:: r--
mask:: rwx
other:: r--

Now the default permissions on the file should give me read/write/execute permissions.

Now I create a file called testfile and I once again change the permission but this time I set it to give geneanthony only read permission.

setfacl -m u:geneanthony:r testfile

When I getfacl on the testfile I get:

file: testfile
owner: root
group: root
user:: rwx
user: geneanthony:r--
group:: r--
mask:: r--
other:: r--

For all intensive purposes I should only have read access to the file. However I can remove it. The same works the other way where if I set the parent folder rx only and the file rwx I can't delete the file. No matter what I set on the file it's using the parent. How can I set it up so the file is using it's own permission and not the parents?
 
Old 04-07-2006, 11:39 AM   #4
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
//Moderator.note: since you made two threads for the same subject I've merged them.
 
  


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
SambaPDC and ACLs ziggy1621 Linux - Networking 4 12-21-2005 07:10 AM
Linux ACLs kcv Linux - Security 6 09-14-2005 03:50 PM
Fedora Core 3, Windows ACLs, POSIX ?? jabran Fedora 6 06-24-2005 10:01 PM
a ./configure doesnt see any working posix threads RokOne Linux - Software 0 04-06-2004 08:06 PM
working on directories and files caesarkim Linux - Newbie 1 11-15-2003 01:51 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

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