Subject: bug#865: 23.0.60; The directory is unsafe today

From: Jason Rumney <[email-masked]>
Date: Fri, 05 Sep 2008 06:46:35 +0800

Francis Litterio wrote:
> Doesn't POSIX define both a user owner and group owner for each file?
> Could a Windows file owned by a group be mapped to POSIX by showing the
> Windows group as the POSIX group owner and a pseudo-user (e.g., nobody,
> root, emacs) as the user owner?
>   

Under POSIX, the user is the owner, and the group is there for assigning 
wider permissions for a file without opening it to the world. I've never 
heard it referred to as group owner, and it is different than the 
situation on Windows where an ACL may contain a group as the 
creator/owner of a file.

Making the owner `nobody' would not fix the problem that the current ACL 
mapping causes. I would surmise that the only use of these fields that 
lisp code has is to test if the current user owns a file. Lisp code does 
not know about the other users or groups that are configured on the 
system, so it isn't going to care about exactly who the other users are. 
Under Windows, where the owner can be a group, if the current user is a 
member of the group that owns a file, then they effectively own that 
file, and Emacs should report that to avoid problems with Lisp code that 
is trying to test ownership. In the case where they aren't a member of 
that group, I don't think it causes problems to report the group as the 
owner, since to Lisp code, any other owner means "not me".