GNU bug report logs - #18748
cp doesn't behaves as mkdir and touch when a default acl exists.

Previous Next

Package: coreutils;

Reported by: f0rhum <f0rhum <at> free.fr>

Date: Thu, 16 Oct 2014 19:15:02 UTC

Severity: normal

Done: Bob Proulx <bob <at> proulx.com>

Bug is archived. No further changes may be made.

Full log


Message #39 received at 18748 <at> debbugs.gnu.org (full text, mbox):

From: Pádraig Brady <P <at> draigBrady.com>
To: Andreas Grünbacher
 <andreas.gruenbacher <at> gmail.com>, 18748 <at> debbugs.gnu.org
Subject: Re: bug#18748: cp doesn't behaves as mkdir and touch when a default
 acl exists
Date: Mon, 13 Apr 2015 09:42:18 +0100
On 13/04/15 00:10, Andreas Grünbacher wrote:
> When a file is copied with cp, the default is to create the new file
> in the target directory, with the file mode of the original file as
> the create mode. This default can be overridden with cp's -p or
> --preserve=mode options.
> 
> This has the following effect:
> 
>  * In the absence of a default acl, the new file will have the original
>    file's permission bits minus the umask.
> 
>  * In the presence of a default acl, the default acl replaces the umask.
>    The new file will inherit the default acl, which results in an imaginary
>    file mode. The actual file mode is set to the intersection of the original
>    file's permission bits and this imaginary file mode.
> 
> This is not a bug, it is the expected and documented behavior; see the
> POSIX standard, POSIX 1003.1e/2c draft standard [*], and also the
> coreutils info pages (info coreutils 'cp invocation') which could be
> improved.

Your improvement pull request is now pushed at
http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commitdiff;h=88e4910

thanks!
Pádraig.





This bug report was last modified 10 years and 45 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.