From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 112546 invoked by alias); 28 Mar 2018 14:45:35 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 80083 invoked by uid 89); 28 Mar 2018 14:45:24 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-6.3 required=5.0 tests=AWL,BAYES_00,GIT_PATCH_2,SPF_PASS,T_RP_MATCHES_RCVD autolearn=ham version=3.3.2 spammy=SYSTEM, rx, Progress, documents X-HELO: mailsrv.cs.umass.edu Received: from mailsrv.cs.umass.edu (HELO mailsrv.cs.umass.edu) (128.119.240.136) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 28 Mar 2018 14:45:23 +0000 Received: from [192.168.0.5] (c-24-62-203-86.hsd1.ma.comcast.net [24.62.203.86]) by mailsrv.cs.umass.edu (Postfix) with ESMTPSA id EE7214023B99; Wed, 28 Mar 2018 10:45:21 -0400 (EDT) Reply-To: moss@cs.umass.edu Subject: Re: Filemode change by windows applications From: Eliot Moss To: cygwin@cygwin.com References: <518060803.20180328171118@yandex.ru> <9965f4cf-566c-6d20-61b7-ce43580935aa@cs.umass.edu> Message-ID: <7f3fe599-eda0-2c97-b344-687b606615eb@cs.umass.edu> Date: Wed, 28 Mar 2018 14:50:00 -0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: <9965f4cf-566c-6d20-61b7-ce43580935aa@cs.umass.edu> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-IsSubscribed: yes X-SW-Source: 2018-03/txt/msg00433.txt.bz2 On 3/28/2018 10:40 AM, Eliot Moss wrote: > On 3/28/2018 10:11 AM, Andrey Repin wrote: > >>> and is there anything I can do to prevent windows >>> applications from setting the execute bit on my files? >> >> No, and you will be unable to use Windows associations, if you clear execute bit >> on documents. > > Interesting that you think so, Andrey.  I just tested this on my Windows 10 > Surface Book.  I used Windows Explorer to navigate to a folder where I had > cleared the x bits from a .docx file (setting mode to 660 with chmod in > Cygwin), and clicking on the file opened Word on the file just fine.  Maybe > this behavior is dependent on some other things as well? Here is getfacl output for the file in question: # file: Progress Letters S16.docx # owner: moss # group: moss user::rw- group::--- group:SYSTEM:r-x #effective:r-- group:Cygwin:rwx #effective:rw- mask:rw- other:--- So there are underlying x bits of some kind, but Cygwin does display mode 660 via ls -l (for example). Still, we entirely agree that there is not really a way to prevent a Windows program from setting the x bits. Here is getfacl from another file in the same folder, reflecting how Word sets the permissions: # file: Progress Letters S17.docx # owner: moss # group: moss # flags: -s- user::rwx group::--- group:SYSTEM:r-x group:Cygwin:rwx mask:rwx other:r-x I think the key difference is "mask". Regards - Eliot -- 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