Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 16 Aug 2005 16:43:16 +0300
From:      Vasil Dimov <vd@datamax.bg>
To:        Joost Bekkers <joost@jodocus.org>, Dmitry Agaphonov <rzhe@agava.com>, freebsd-hackers@freebsd.org
Subject:   Re: Shared memory permissions question
Message-ID:  <20050816134316.GA29915@sinanica.bg.datamax>
In-Reply-To: <20050816131034.GA44545@bps.jodocus.org>
References:  <20050816165115.2387c14f@rzhe.agava-dubna.local> <20050816131034.GA44545@bps.jodocus.org>

index | next in thread | previous in thread | raw e-mail

[-- Attachment #1 --]
On Tue, Aug 16, 2005 at 03:10:34PM +0200, Joost Bekkers wrote:
> On Tue, Aug 16, 2005 at 04:51:15PM +0400, Dmitry Agaphonov wrote:
> > Hello,
> > 
> > 
> > I have user A from group G creating shared memory M with permissions
> > 0060.  After this, A fails to attach M due to permission denied.
> > However, another user B from the same group G successfully attaches M.
> > User A manages to attach only if permissions 0600 added for M.
> > 
> > Why the system disregards group permissions for user A?  Is it correct
> > behaviour?
> > 
> > This is happening on FreeBSD 4.11-STABLE.
> > 
> 
> This is normal&correct behaviour.
> 
> Access if granted on a best match basis:
> 
> if user==owner then only user rights are applied
> elseif user is member of group then only group rights are applied
> else only 'other' rights are applied.
> 

This also applies for the filesystem.

$ id
uid=1001(dd) gid=1001(dd) groups=1001(dd)
$ ls -l file
----r--r--  1 dd  dd  0 Aug 16 16:34 file
$ cat file
cat: file: Permission denied
$

[-- Attachment #2 --]
-----BEGIN PGP SIGNATURE-----

iD8DBQFDAe1zFw6SP/bBpCARAvjpAKCytkie+ODFExYBeE1EWM1VxqQCjQCg4OfM
ngiqF0I1nfzNghiNlXllguI=
=fKKX
-----END PGP SIGNATURE-----
help

Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050816134316.GA29915>