delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2026/03/05/01:37:02

DMARC-Filter: OpenDMARC Filter v1.4.2 delorie.com 6256b1oU2431151
Authentication-Results: delorie.com; dmarc=pass (p=none dis=none) header.from=cygwin.com
Authentication-Results: delorie.com; spf=pass smtp.mailfrom=cygwin.com
DKIM-Filter: OpenDKIM Filter v2.11.0 delorie.com 6256b1oU2431151
Authentication-Results: delorie.com;
dkim=pass (1024-bit key, unprotected) header.d=cygwin.com header.i=@cygwin.com header.a=rsa-sha256 header.s=default header.b=Vxj5O9Ub
X-Recipient: archive-cygwin AT delorie DOT com
DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org D92924BA23CF
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com;
s=default; t=1772692620;
bh=FaYmcdYfAYAbfc2+Afng96ZEf0ahYpfgsGWfHHdyEOE=;
h=Subject:To:References:Date:In-Reply-To:List-Id:List-Unsubscribe:
List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:
From;
b=Vxj5O9UbiwDTcVEJAdAiTm5u/suseHR+PjPfQlQ9UVGJBn3l6vLCdnml/KvJLUXfd
civws2grXoKxiUA5HZOMu7f4Bfb2y892i/ODmiQ07i2Xnj7ARRh4AeyuyUh5QUh38h
/rLDfeFCmmUGdaFHOU9Mm/R6jCmhinrIkdw2ziqg=
X-Original-To: cygwin AT cygwin DOT com
Delivered-To: cygwin AT cygwin DOT com
DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 0AF334BA2E14
ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 0AF334BA2E14
ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1772692507; cv=none;
b=SvBE6nGr0r9xuker8K4v2xrvPJKLo5+g1TdAOOefzs9X0EhkplDd6IVc69hGRRGPEsvlSQBi6zbceFRWt2krlATSBpcoj4dCUqijxwPXHc5MKPV+a6zHJmm9tNMNVjrMn31nyV2pqEAKbbP9z+NOOSRHjH2q1Nd6QSebSP6C4/w=
ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key;
t=1772692507; c=relaxed/simple;
bh=YWh1nwQsU0SdCEpJujtnqlOYzSxSHwEvbD8ydXOn7C8=;
h=DKIM-Signature:Subject:To:From:Message-ID:Date:MIME-Version;
b=pUgO7hfwVg0dkfxLurKkQuZoBulRCJoqT6bjHaVxcLs03jhkVM08XHualxKAuvYTDS4k9F8wxvuGbWq0gFs6aMkV2mHizjR012NKrO7QYuMBT/GxDSJAvcSyAf1uPKCTtw0F4UqwjIntbIAFpKg725qyW/7RajvA2mobOh19MkY=
ARC-Authentication-Results: i=1; server2.sourceware.org
DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 0AF334BA2E14
Subject: Re: HYPER-V VMs: Cygwin /bin/getent group 'Virtual Machines' cannot
find the group
To: cygwin AT cygwin DOT com
References: <CANH4o6P07DG5XcSooXkAE5ShWkkz1hVBSMn6k2iaLycSEEA_0A AT mail DOT gmail DOT com>
<CA+1jF5oHw71rv-OH893R+DdNpnRUQAtp=WS_fXvxe1WBsC0H6w AT mail DOT gmail DOT com>
<be10d1b2-234f-4980-a74d-2845220491bd AT SystematicSW DOT ab DOT ca>
Organization: WiseMo A/S
Message-ID: <71dba56e-832f-37c6-c03d-fab12d65f146@wisemo.com>
Date: Thu, 5 Mar 2026 07:35:00 +0100
X-Mailer: Epyrus/2.1.3
MIME-Version: 1.0
In-Reply-To: <be10d1b2-234f-4980-a74d-2845220491bd@SystematicSW.ab.ca>
X-Content-Filtered-By: Mailman/MimeDel 2.1.30
X-BeenThere: cygwin AT cygwin DOT com
X-Mailman-Version: 2.1.30
List-Id: General Cygwin discussions and problem reports <cygwin.cygwin.com>
List-Unsubscribe: <https://cygwin.com/mailman/options/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=unsubscribe>
List-Archive: <https://cygwin.com/pipermail/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-request AT cygwin DOT com?subject=help>
List-Subscribe: <https://cygwin.com/mailman/listinfo/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=subscribe>
From: Jakob Bohm via Cygwin <cygwin AT cygwin DOT com>
Reply-To: Jakob Bohm <jb AT wisemo DOT com>
Errors-To: cygwin-bounces~archive-cygwin=delorie DOT com AT cygwin DOT com
Sender: "Cygwin" <cygwin-bounces~archive-cygwin=delorie DOT com AT cygwin DOT com>
X-MIME-Autoconverted: from base64 to 8bit by delorie.com id 6256b1oU2431151

On 03/03/2026 10:49, Brian Inglis via Cygwin wrote:
> On 2026-03-03 01:26, Aurélien Couderc via Cygwin wrote:
>> On Mon, Mar 2, 2026 at 8:19 PM Martin Wege via Cygwin 
>> <cygwin AT cygwin DOT com> wrote:
>>>
>>> Hello,
>>>
>>> we use HYPER-V virtual machines on Windows 10 and Windows 11. It seems
>>> they use a "special" kind of group called 'Virtual Machines', which
>>> Cygwin (3.6.5) /bin/getent cannot lookup:
>>>
>>> getent group 'Virtual Machines'
>>> <nothing>
>>>
>>> Does anyone have ideas or clues how to get getent group to work with
>>> this kind of Windows group?
>>>
>>> We want the Cygwin gid for that group, and use Cygwin commands to work
>>> with those files...
>>
>> Déjà vu
>>
>> 1. Please read https://cygwin.com/pipermail/cygwin/2025-July/258505.html
>>
>> 2. Try this:
>> getent group "NT VIRTUAL MACHINE+Virtual Machines"
>> For me, with default (empty, except comments) /etc/nsswitch.conf, it
>> does not work. Which I consider a bug.
>
> The defaults are chosen so that required system components work.
> If you have additional requirements, such as interactive lookup, or 
> your own scripts, you may add to the defaults, which adds to the 
> overhead on every lookup, reduced if you run the `cygserver` cache.
>
> This is the default installed conf file:
> <snip large config file default>
OP isn't asking about enumeration, but direct lookup.  You answer is as 
inept
as responding with hosts file settings when asked about why certain DNS
lookups fail.  If lookup of a system built in group fails, core cygwin 
tools such as
/bin/ls fail.

The CYGWIN library implementation of getent functions need to be agile
enough to handle any values handled by the similar Win32 functions. This in
turn requires hardcoded logic for any values of the enum first DWORD after
the uint48_t authority field in SID values, in this case "83". 
Alternatively, grow
the uid_t type to 560 bits, which seems to be the limit of current Win32
implementations (max 15 DWORDS after the authority and version byte fixed at
1).

-- 
Jakob Bohm, CIO, partner, WiseMo A/S. https://www.wisemo.com
Transformervej 29, 2860 Soborg, Denmark. direct: +45 31 13 16 10 
<tel:+4531131610>
This message is only for its intended recipient, delete if misaddressed.
WiseMo - Remote Service Management for PCs, Phones and Embedded


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

- Raw text -


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