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=wnGv8TpxCLUkMpTu VfiI2RignqVhecqq/kTK8Q9SSDLJ88oL41GFHAjqyzFzCud/cZGIWFP8pW5ZVsEi jg6R3X41CCrjt20im/Vf2TgeDsP1W6wGFP+e6UEb1lBtxU3pKl1NWqragnIlmh3U 5et3BuXmS4wthPm4lVDLsS0tF0I= 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=s5RwNkE7gxJLc8Nf9qfq31 FK7OA=; b=asbYIdGLgkY4X2ARA6uY//oS/Swy+A356zLaVwRXeR3xxuLvDEuW1g PVhyneLuGkB6x8GuFo6TFyciqRToHX5oXTYMY5xxDiQHHiBXGC++G32B1RZP8NOQ 3KH8jjHEmGXDSUqpE1rBWnYcDL8MC2216Nm8RpCRG5q6TDUfP7nwQ= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , 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=-2.9 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 spammy= X-HELO: smtp-out-so.shaw.ca Reply-To: Brian DOT Inglis AT SystematicSw DOT ab DOT ca Subject: Re: rename a user using setfacl -- possible? how? To: cygwin AT cygwin DOT com References: <5D1FA19D DOT 2020707 AT tlinx DOT org> <113642000 DOT 20190706120641 AT yandex DOT ru> <5D206C63 DOT 4000908 AT tlinx DOT org> <69388071 DOT 20190706190156 AT yandex DOT ru> From: Brian Inglis Openpgp: preference=signencrypt Message-ID: <2ac2d302-559c-b6ba-c7e2-5ec12e1683de@SystematicSw.ab.ca> Date: Sat, 6 Jul 2019 11:01:41 -0600 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.7.2 MIME-Version: 1.0 In-Reply-To: <69388071.20190706190156@yandex.ru> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes On 2019-07-06 10:01, Andrey Repin wrote: >> On 2019/07/06 02:06, Andrey Repin wrote: >>>> I guess I don't know how to modify an entry to either 1-rename it, or >>>> 2 add the new entry. >>> You don't. >>> If you want to change name for display purposes, look into nsswitch.conf and >>> associated documentation. >> My machine's GUID changed. This file has entry for userX >> on the old machine-GUID. UserX also exists on the new machine GUID. >> So I renamed the old entry to UserXold so I could find all the places >> where the old GUID is referenced then change it to the machine's new guid. >> I'm not having cygwin create new groups or whatever, but trying to replace >> references to this Userid in the machine's old GUID and replace them with >> reference to the Uid with the machine's new GUID. >> if it was the main group, I'd just use find to locate instances of old >> and do chgrp to change ownership to new. However, this is a group entry >> in an acl list -- so I need to change the name of 1 entry in the acl list. >>> It should, but I strongly suggest to avoid using it outside Cygwin directory >>> tree to maintain maximum interoperability with Windows programs. >> No problem. my cygwin directory is at 'C:\', where it >> has been since WinXP... (:^|) > THAT is a problem. A big problem. >>> getent passwd >>> getent group >> those don't display GUID/UUIDs, but *nix user+group ids. > Try it sometime. They do. Try: $ id user|group and see below for getent nsswitch changes suggested. >> I wanted to see the windows guid associated with an identity. >> Since the one I was looking for was a well-known-id I found it, but >> in non-well-known cases,...? > Set nsswitch.conf to: > passwd: db > group: db > db_enum: all > then check `getent passwd` In your work environment, you might want to try: # passwd: files db # group: files db db_enum: cache files local builtin primary alltrusted See docs in - paste into browser: /usr/share/doc/cygwin-doc/html/cygwin-ug-net/ntsec.html#ntsec-mapping-nsswitch or $ cygstart https://cygwin.com/cygwin-ug-net/ntsec.html#ntsec-mapping-nsswitch -- 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