delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2019/06/04/17:27:50

X-Recipient: archive-cygwin AT delorie DOT com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:reply-to:subject:to:references:from:message-id
:date:mime-version:in-reply-to:content-type
:content-transfer-encoding; q=dns; s=default; b=oSL+uB8BXgpuW8cu
ILy7MIKKm4pwqppDkGqawbRYDUgKDlWGCRwRVgfgAOjYT44u+9k4DDVrnZkFvKLP
pX9uIOh+vJSFZyAN5rMVpjLNbD+55Rr0U2KVKqc2lu6+NjcO/skYFDJO4k0u9xJA
Of4WB3qVo3COeCOWIs4KzezMiZk=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:reply-to:subject:to:references:from:message-id
:date:mime-version:in-reply-to:content-type
:content-transfer-encoding; s=default; bh=3lE4HEWyuN1KuO6IK/Yewx
jM5HM=; b=oa152JXHrV+oK474lTwx2LUlfOWgbjyhI0NEYwDFyWqa+qgIuXt8PX
rBTXydB+4KDLGj+nsvcudGs92vevFc5S5acRCb64D6JjXQQNPFAwgJ+BuZIBpyYV
6DRPPZomEcXk8R5ZRVzsdnLYn4t/DUay+O/XnbChknmmSQOJPw7mQ=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Authentication-Results: sourceware.org; auth=none
X-Spam-SWARE-Status: No, score=-5.5 required=5.0 tests=AWL,BAYES_00,GIT_PATCH_2,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 spammy=OWNER
X-HELO: smtp-out-so.shaw.ca
Reply-To: Brian DOT Inglis AT SystematicSw DOT ab DOT ca
Subject: Re: Trying to create default ACL entries to match file ACL entries
To: cygwin AT cygwin DOT com
References: <5CF6C7A8 DOT 6090902 AT tlinx DOT org> <ab8ce19f-5c2a-63f4-1685-d3174a1db216 AT cs DOT umass DOT edu> <5CF6CD87 DOT 8000204 AT tlinx DOT org>
From: Brian Inglis <Brian DOT Inglis AT SystematicSw DOT ab DOT ca>
Openpgp: preference=signencrypt
Message-ID: <4df43ab7-abc9-e0ae-e9c1-ace2c07da9d9@SystematicSw.ab.ca>
Date: Tue, 4 Jun 2019 15:26:51 -0600
User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.7.0
MIME-Version: 1.0
In-Reply-To: <5CF6CD87.8000204@tlinx.org>
X-IsSubscribed: yes

On 2019-06-04 13:59, L A Walsh wrote:
> lets see if this is more clear:
> On 2019/06/04 12:44, Eliot Moss wrote:
>> On 6/4/2019 3:34 PM, L A Walsh wrote:
>>> I am trying to create an entry for '/' (or '.' w/me sitting in '/')
>>> where the default entries are the same as the file entries.
>>>           ^^^^^^^
>>> so tried doing:
>>>    getfacl . | setfacl -d - .
> Sorry, but am trying to get the 'file' entries (w/o the -d)
> copied into the default.

Not seeing -d, --default documented or supported in the code as an option flag
under Cygwin: it is available under Debian/Ubuntu at least, and probably other
Linux; neither are the file input option flags -M, --modify-file, -X,
--remove-file, or symbolic link -L, --logical, -P, --physical, or -R,
--recursive option flags.

Cygwin equivalent based on setfacl(1) would be something like:
$ getfacl -a source_file | sed 's/.*/&\nd:&/' | setfacl -f - target_file
where you are getting and duplicating the file accesses and also creating the
DACLs.

> On 2019/06/04 12:44, Eliot Moss wrote:
>> Ooooo ... not sure _I'd_ mess what / on a Windows system!
> -----
>     Ya, not idea, but too late for that.  Thanks for your
> vote of confidence though!  :waaaaa: :-(

I have had success using only setfacl -m and specifying everything I want
changed or set in that argument e.g.

	$ setfacl -m u::rwx,g::r-x,o::r-x,d:u::rwx,d:g::r-x,d:o::r-x /

probably using an admin account running with elevated permissions in this case.

For Cygwin root /, I have only:

$ lsp / | cygcheck-hrsv.sed
drwxr-xr-x+ 1 $USER Administrators 0 May 31 05:19 /
# file: /
# owner: $USER
# group: Administrators
user::rwx
group::r-x
other::r-x
default:user::rwx
default:group::r-x
default:other::r-x

C:/.../cygwin64 $HOSTNAME\$USER:(F)
                      BUILTIN\Administrators:(RX)
                      Everyone:(RX)
                      CREATOR OWNER:(OI)(CI)(IO)(F)
                      CREATOR GROUP:(OI)(CI)(IO)(RX)
                      Everyone:(OI)(CI)(IO)(RX)

Successfully processed 1 files; Failed processing 0 files

-- 
Take care. Thanks, Brian Inglis, Calgary, Alberta, Canada

This email may be disturbing to some readers as it contains
too much technical detail. Reader discretion is advised.

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019