Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 26 Dec 1996 10:41:59 -0500 (EST)
From:      Charles Owens <owensc@enc.edu>
To:        Snob Art Genre <ben@narcissus.ml.org>
Cc:        hackers@freebsd.org, questions@freebsd.org
Subject:   Re: multi-group file access techniques
Message-ID:  <Pine.FBS.3.93.961226100737.24466B-100000@dingo.its.enc.edu>
In-Reply-To: <Pine.BSF.3.91.961218194515.1950C-100000@narcissus.ml.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 18 Dec 1996, Snob Art Genre wrote:

> On Wed, 18 Dec 1996, Charles Owens wrote:
> 
> > .../man_readable_c is a "control directory," a technique that seems
> > obvious to me now but was new to me when I read of it in "Techniques for
> > Simulating Multiple Group Ownership," by Doug Morris, from the October
> > issue of SysAdmin magazine. 
> 
> What's a control directory?

Basicly an extra directory thrown in to allow an additional type of access
via the group permissions (typically).  Any given directory or file can
belong to just one group, which is a royal pain.  The control directory
provides a means to simulate multiple group ownership in a limited
fashion.   

Back to the example from my posting (to which only you replied: grrrr...):

				    Owner	Group	Mode

                man_readable_c      eng2_member eng1    drwxr-x---
                   |
                   +- man_readable  eng2_member eng2    drwxrwxr-x
			|
			+- (files)  eng2_member eng2    -rwxrwxr-x

Here the goal is to allow one group (eng2, who also should belong to group
eng1) to have read+write access and another group (eng1) to have just read
access.  Members of eng1 access the contents of man_readable_c via that
directory's group permissions.  The, eng1 members can gain read-only
access to the contents of man_readable via man_readable's 'other'
permission field. 

> > In his article, Doug Morris also speaks of a technique of using hard links
> > of directories to achieve a similar effect.  This technique could be used
> > in tandem with the above to add more flexibility, but we all know the
> > GREAT EVIL that hard linked directories are.  :-) 
> 
> And why are hard-linked directories evil?
> 
> > Thanks in advance for any and all response,

I don't have a complete understanding of the technical issues, but from
what other have said I've gotten the general impression that using them
can often (if not always) lead to the corruption of the file system.  Do a
search of the hackers discussion list for the string "hard linked
directories."  There were quite a number of illuminating posts on this
particular topic a few months ago.

>From what I've gleaned from these postings, one of the biggest problems
with them is the potential for creating loops in the file tree, which fsck
is generally very unhappy about.  If one is very careful not to create
such loops _is_ it possible to safely employ hard-linked directories (and 
keep fsck happy) ?  I can certainly see that they're very dangerous, but
can they be used safely with FreeBSD?  Anyone?  

> Ha!  Bet you weren't expecting questions instead of answers.  :)

Hey.. why not?!  Discussion is always a nice thing!  :-)
---
-------------------------------------------------------------------------
  Charles Owens                                  Email:  owensc@enc.edu
                                       "I read somewhere to learn is to
  Information Technology Services     remember... and I've learned that
  Eastern Nazarene College            we've all forgot..."   - King's X
-------------------------------------------------------------------------





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.FBS.3.93.961226100737.24466B-100000>