Boston Linux & UNIX was originally founded in 1994 as part of The Boston Computer Society. We meet on the third Wednesday of each month at the Massachusetts Institute of Technology, in Building E51.

BLU Discuss list archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Discuss] Advanced file permisions

On Tue, Nov 25, 2014 at 09:38:52AM -0500, Jerry Feldman wrote:
> I have an auto mounted directory where I want to restrict access to only
> members of a specific group, lets call it foogroup for now. I didn't want
> to use netgroups for a number of reasons in that the NAS is run by a
> separate team, and they use a different LDAP server than we do.
> The way I set up the original top level directory is:
> chmod 2770: rwxrws--- foogroup
> But when I create a subdirectory I get:
> rwx--S---

How did you create the directory?  If you're using mkdir on the
command line, the umask seems like the only possible culprit,
excepting some weird filesystem mount options possibly.  The mkdir
command  has a -m option to set the mode but one can assume you're not
using that, or else you would know. =8^)  

If you're doing this from within a program, the mkdir() system call
takes a mode argument (and is, I believe, still modified by your
umask).  That's for C obviously but other languages should generally
have something similar, and in some of those languages it may be
optional, defaulting to something you don't want...

Derek D. Martin   GPG Key ID: 0xDFBEAD02
This message is posted from an invalid address.  Replying to it will result in
undeliverable mail due to spam prevention.  Sorry for the inconvenience.

BLU is a member of BostonUserGroups
BLU is a member of BostonUserGroups
We also thank MIT for the use of their facilities.

Valid HTML 4.01! Valid CSS!

Boston Linux & Unix /