delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2019/02/15/20:05:47

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:date:from:reply-to:message-id:to:subject
:in-reply-to:references:mime-version:content-type
:content-transfer-encoding; q=dns; s=default; b=K/Uu3XxaZN5n98WI
V4GDkGc6xzTxl6shFZ/M+f3ebpZsV7CmEVy09kGmpWyE+RecyNPymQpPSVlqlPAC
E0VzptHnzKDartazbNfOpXh9S7311EAXi1b9C+KoFSakYo3FGmPkFWSvMvuDWp2T
JDQKzrS7gxwfkLm51N/QSY/CPow=
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:date:from:reply-to:message-id:to:subject
:in-reply-to:references:mime-version:content-type
:content-transfer-encoding; s=default; bh=+fz7jaUYKRRajcAyjOgte5
AsPrI=; b=DOtoBH76RStsfEjx20LqzkTvo05/iVKnUQ5czJPmJ27OjgFqHOocUe
HZJROnzn2bljZdXEVc4D2kIxtGervThKU5yPpbyFJNvp4OK7iUJbSx4RGN1IA35Q
2jmqipaQ5jasqEeORK3XdE4wONgUvyB+J2DynZZWc0pYcCaELqkXc=
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.7 required=5.0 tests=BAYES_00,FREEMAIL_FROM,GIT_PATCH_2,KAM_THEBAT,MIME_BASE64_BLANKS,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 spammy=sk:unsubsc, english, HX-Priority:Normal, H*M:yandex
X-HELO: forward103o.mail.yandex.net
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1550279102; bh=jLAFr7mKorya+cxiEANdqcSdv7uQlDyyFui9JdJna6c=; h=Date:From:Reply-To:Message-ID:To:Subject:In-Reply-To:References; b=wzltLV6h6gCedxj9X4BjZd24BXDmbTZLL8n8F2sRXlRiRRghPHhEWzI4cOaWqM6Ht oEdQirPNxq7eAnK6HVrGFAOFMEJRNszBimbq52u2sKz/tUpeNzZotCz+OTPfe64JF7 ixFuQ9Y6Ge8wjGgXIuo7nMLvG2kUlvHBe8C2yULQ=
Authentication-Results: mxback4o.mail.yandex.net; dkim=pass header.i=@yandex.ru
Date: Sat, 16 Feb 2019 03:57:18 +0300
From: Andrey Repin <anrdaemon AT yandex DOT ru>
Reply-To: cygwin AT cygwin DOT com
Message-ID: <477950328.20190216035718@yandex.ru>
To: Bill Stewart <bstewart AT iname DOT com>, cygwin AT cygwin DOT com
Subject: Re: Windows to Cygwin username mapping: Domain before local account when duplicate name?
In-Reply-To: <CANV9t=QEz=L-ftqr06QZPxZSkhqGzrFS3s93s6ztBeKJk5WnjA@mail.gmail.com>
References: <CANV9t=SNfgP-CA32yfPwLv2=d0F8xtpdCT4o_wwGFGE+F3SEuA AT mail DOT gmail DOT com> <50cba8d1-4794-8db9-d1f3-ab9476421db7 AT gmx DOT com> <CANV9t=QQ1higAt1qeDF4fckkz_6eqQJtdhau8+uhrAvGtWUK_A AT mail DOT gmail DOT com> <20190215163817 DOT GI2702 AT calimero DOT vinschen DOT de> <CANV9t=Rm+su=qDqdFN-LqiMLEAHJD7WxW_OSqqSpqgeb6ir++w AT mail DOT gmail DOT com> <20190215202936 DOT GL2702 AT calimero DOT vinschen DOT de> <CANV9t=SdQPZw_VF95HwDrVRU1KzdHA61GJBRgA1weHryHUO6-w AT mail DOT gmail DOT com> <20190215204326 DOT GO2702 AT calimero DOT vinschen DOT de> <CANV9t=Q5M+V9TPEN-GaGzLtK_8AO5fUenajQ+T-VZX6+kbrMMw AT mail DOT gmail DOT com> <20190215213159 DOT GQ2702 AT calimero DOT vinschen DOT de> <CANV9t=QEz=L-ftqr06QZPxZSkhqGzrFS3s93s6ztBeKJk5WnjA AT mail DOT gmail DOT com>
MIME-Version: 1.0
X-IsSubscribed: yes
X-MIME-Autoconverted: from base64 to 8bit by delorie.com id x1G15j4E029061

Greetings, Bill Stewart!

>> What is a "typical" order?!?
>>
>> If you login locally to a domain member machine the default domain is
>> the logon domain of this machine.  If that's not what you want you have
>> to choose the logon domain of your account explicitely, even if it's the
>> local machine SAM.  Windows will not try to find the user name locally
>> if you didn't chose it explicitely.  You get "The user name or password
>> is incorrect. Try again" instead.
>>
>> The only exception I'm aware of is the "Administrator" account, at least
>> in Windows 10.

> Here's a real-world scenario you might not have considered...

What is your nsswitch configuration, yet again?…

> I have a local account named "Admin" on my computer I use for
> administrative tasks.

> My computer is a member of a medium-side domain (about 25000 users),
> and at some point in the past an admin created a group named "Admin"
> that I didn't even know existed.

> This means that when I test getent using the name "Admin", Cygwin
> finds the domain group:

> PS C:\> getent -w passwd admin
> admin:nnnnnnnn:DOMAINNAME\admin:S-1-5-21-nnnnnnnnnn-nnnnnnnnn-nnnnnnnnn-nnnnnn

> I get that this is by design, but .NET finds the local account first,
> which is what I was expecting:

> PS C:\> $name = [Security.Principal.NTAccount] "admin"
> PS C:\> $sid = $name.Translate([Security.Principal.SecurityIdentifier])
> PS C:\> $sid.Translate([Security.Principal.NTAccount])

> Value
> -----
> COMPUTERNAME\Admin

> Hence the question.

> Regards,

> Bill

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



-- 
With best regards,
Andrey Repin
Saturday, February 16, 2019 3:56:41

Sorry for my terrible english...
--
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