access permissions in 1003.1
Ed Gould
ed at mtxinu.COM
Mon Jun 3 16:55:21 AEST 1991
Submitted-by: ed at mtxinu.COM (Ed Gould)
>The problem, phrased in 1003.1's terms, is what happens if i am both
>the owner and group of a file with mode 040; can I read it?
The traditional UNIX implementation of file permissions has
been
if owned by user
check owner bits
else if owned by user's group
check group bits
else
check other bits
Hence, if one owns a file *only* the owner bits matter. The group
bits apply only to non-owners in the group; the other bits apply
only to non-owner non-group. I don't know what 1003.1 says, though.
Given its reliance on traditional UNIX, this is what I'd expect it
to say.
The other reasonable interpretation I can imagine is
if (owned by user and owner bits allow access) or
(owned by user's group and group bits allow access) or
(other bits allow access)
grant access
else
deny access
I'd bet small amounts of money that this latter interpretation
doesn't conform to 1003.1.
--
Ed Gould No longer formally affiliated with,
ed at mtxinu.COM and certainly not speaking for, mt Xinu.
"I'll fight them as a woman, not a lady. I'll fight them as an engineer."
Volume-Number: Volume 23, Number 83
More information about the Comp.std.unix
mailing list