www.delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2011/01/02/20:57:58

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-1.1 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE
X-Spam-Check-By: sourceware.org
X-Yahoo-SMTP: Uu383n6swBCEN1G9up0WSnxbvN8fCPmk
Message-ID: <4D212D16.5060902@cygwin.com>
Date: Sun, 02 Jan 2011 20:57:42 -0500
From: "Larry Hall \(Cygwin\)" <reply-to-list-only-lh AT cygwin DOT com>
Reply-To: cygwin AT cygwin DOT com
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.21) Gecko/20090320 Remi/2.0.0.21-1.fc8.remi Lightning/0.9 Thunderbird/2.0.0.21 Mnenhy/0.7.5.0
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: Owner/Group showing up as "??????????" on some Windows files despite mkpasswd/mkgroup
References: <19740 DOT 3764 DOT 509174 DOT 665204 AT consult DOT pretender> <4D1CA7C9 DOT 4020807 AT cygwin DOT com> <30570563 DOT post AT talk DOT nabble DOT com> <AANLkTincJp_sk9_Gg_3bfDo2sACFH_xgrgAH+VNphToa AT mail DOT gmail DOT com> <30571878 DOT post AT talk DOT nabble DOT com> <4D20CC45 DOT 8060304 AT cygwin DOT com> <30575008 DOT post AT talk DOT nabble DOT com>
In-Reply-To: <30575008.post@talk.nabble.com>
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

On 1/2/2011 7:08 PM, aputerguy wrote:
>
>
>
> Larry Hall (Cygwin) wrote:
>>
>> On 1/2/2011 9:09 AM, aputerguy wrote:
>>> Csaba Raduly-2 wrote:
>>>>
>>>> On Sun, Jan 2, 2011 at 7:59 AM, aputerguy wrote:
>>>>> If trustedinstaller is a valid file owner then I would like it to
>>>>> show up as the file owner in cygwin so that rsync transfers it over
>>>>> properly. Presumably this would mean adding it to my /etc/passwd file
>>>>> though I'm not sure what would be the best entry to use.
>>>>>
>>>>> On the other hand if trustedinstaller SHOULD NOT be owning any files
>>>>> and its just an error on my windows system then I would like to
>>>>> correct the file ownership in windows so that the files have the
>>>>> correct owners.
>>>>
>>>> On Windows 7 and Vista, "trustedinstaller" owns (and is supposed to
>>>> own) all the files of the OS:
>>>>
>>>> http://technet.microsoft.com/en-us/magazine/2007.06.acl.aspx
>>>> (quoted in
>>>> http://www.vistax64.com/vista-security/87679-trusted-installer.html#post528738
>>>> )
>>>>
>>>
>>> If so, wouldn't it make sense to add trustedinstaller to the passwd and
>>> group file to distinguish those files that have a legitimate ownership
>>> from others that truly may be owned by an unknown user?
>>
>> Sure.  But the point is that the SID isn't considered a Windows user so
>> that's why it doesn't show up by default.  As a work-around for now, you
>> can add a line like this to your '/etc/passwd' file:
>>
>> TrustedInstaller:unused:80:544:Trusted Installer,U-NT
>> SERVICE\TrustedInstaller,S-1-5-80-956008885-3418522649-1831038044-1853292631-2271478464::
>>
>> (The above is all on one line)
>>
>> This will make "TrustedInstaller" show up as the user, just like you will
>> see in Windows.  The group is still '????????' though.  I'll leave
>> tracking down the proper SID for the group as an exercise for the reader.
>> ;-)
>>
>>
>
> - Are you aware of any other "non-user" users&  groups on a typical
> Vista/Windows7 installation that I should be looking out for and making
> ad-hoc adjustments for as above?

No but that doesn't mean Windows doesn't have them. ;-)

> - Just so I can understand, can someone explain to me the rationale for not
> having cygwin by default be able to recognize such an incredibly common and
> seemingly standard owner of files as the TrustedInstaller ssid? I'm not sure
> I understand the benefit of mapping such a common and known owner to the
> '????????' notation which is supposed to be for unknown users and groups.
>
> I mean from a user perspective, I don't see the downside of not including
> any standard user who is likely to own files. I mean just like in regular
> *nix, we create users for services such as mail, apache, etc that are likely
> to be owning and/or requiring access to files, why wouldn't we do the same
> on Windows?

The reason is simple.  Virtual users aren't enumerated by the standard
Windows APIs that provide all the other user SIDs.  So, we don't get this
covered for free.  We need more code.  It's just a case of
<http://cygwin.com/acronyms/#SHTDI>.

You can be the first on your block to offer a patch to Cygwin to handle
this. :-)

-- 
Larry

_____________________________________________________________________

A: Yes.
> Q: Are you sure?
>> A: Because it reverses the logical flow of conversation.
>>> Q: Why is top posting annoying in email?

--
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