Subject: RE: [nfsv4] DELETE_CHILD and DELETE

From: "Noveck, Dave" <[email-masked]>
Date: Tue, 3 Feb 2004 11:45:40 -0800

> If and acl allows DELETE_CHILD is set on a directory and denies DELETE
> on a file in the directory, is it documented anywhere whether the file
> should be removeable? (and what if it denies DELETE_CHILD and allows
> DELETE on the file?)

Not that I could see.

> I'm assuming that removal is allowed if *either* DELETE_CHILD or DELETE
> is set, 

That doesn't seem right to me.  If the owner of the directory let's me
write in it, OK.  But if the owner of the file doesn't let me do anything
with it (read, write, execute), why would I be allowed to delete the
thing, especially since there is an explicit DELETE bit by which I may
prohibit people from doing a delete?

It would seem more natural to me if both were required, but I didn't
see any text that addressed the issue.

> in which case posix implementations should associate
> DELETE_CHILD with write permissions and should never set DELETE.

-----Original Message-----
From: J. Bruce Fields [mailto:[email-masked]]
Sent: Tuesday, February 03, 2004 12:57 PM
To: [email-masked]
Subject: [nfsv4] DELETE_CHILD and DELETE

If and acl allows DELETE_CHILD is set on a directory and denies DELETE
on a file in the directory, is it documented anywhere whether the file
should be removeable? (and what if it denies DELETE_CHILD and allows
DELETE on the file?)

I'm assuming that removal is allowed if *either* DELETE_CHILD or DELETE
is set, in which case posix implementations should associate
DELETE_CHILD with write permissions and should never set DELETE.

--Bruce Fields

_______________________________________________
nfsv4 mailing list
[email-masked]
https://www1.ietf.org/mailman/listinfo/nfsv4

_______________________________________________
nfsv4 mailing list
[email-masked]
https://www1.ietf.org/mailman/listinfo/nfsv4

---

From: "J. Bruce Fields" <[email-masked]>
Date: Tue, 3 Feb 2004 15:22:01 -0500

On Tue, Feb 03, 2004 at 11:45:40AM -0800, Noveck, Dave wrote:
> That doesn't seem right to me.

Ugh.  Well, we need to agree on this.  Can anyone point me to any
authoritative documentation on NT ACL's (since they seem to be the
inspiration for DELETE and DELETE_CHILD)?

> If the owner of the directory let's me write in it, OK.  But if the
> owner of the file doesn't let me do anything with it (read, write,
> execute), why would I be allowed to delete the thing,

That's standard unix-like behavior: unlinking a file is a directory
operation (it doesn't even necessarily destroy the file, which may be
referenced elsewhere), so only directory permissions matter.

> especially since there is an explicit DELETE bit by which I may

I'm operating in a total NT ACL vacuum here so one of the few tidbits I
have to go on is some random linux-kernel email turned up by google,
where someone refers to DELETE, "which lets you bypass directory write
permission to delete a specified file."

http://www.ussg.iu.edu/hypermail/linux/kernel/0007.3/0801.html

Otherwise it would seem awfully easy to get into a situation where you
could create a file you couldn't delete.

--Bruce Fields