public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: Cedric Blancher <cedric.blancher@gmail.com>
To: cygwin@cygwin.com
Subject: Re: How can I get the group SID for a file in cmd.exe (powershell is not an option)?
Date: Mon, 4 Mar 2024 08:04:00 +0100	[thread overview]
Message-ID: <CALXu0UfXsrjxjg39z86egJwYDWWdfihQ19bbaQHynjUoMQCrCA@mail.gmail.com> (raw)
In-Reply-To: <Zd36SYPoblmPw4OX@calimero.vinschen.de>

On Tue, 27 Feb 2024 at 16:07, Corinna Vinschen via Cygwin
<cygwin@cygwin.com> wrote:
>
> On Feb 27 15:41, Cedric Blancher via Cygwin wrote:
> > Good afternoon!
> >
> > How can I get the group SID for a file in cmd.exe (powershell is not an option)?
> > Is it possible to add an option to ls -l to list the user/group SIDs too?
>
> No, but you can use Cygwin tools:
>
>  getent -w group $(ls -gn foo | awk '{print $3}') | awk -F: '{print $4}'

I need the exact Windows SID strings, without intermediate
translation. It's for a test suite written in cmd.exe (whoever had
that idea, but I do not have the resources to rewrite it).

Ced
-- 
Cedric Blancher <cedric.blancher@gmail.com>
[https://plus.google.com/u/0/+CedricBlancher/]
Institute Pasteur

  reply	other threads:[~2024-03-04  7:06 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-27 14:41 Cedric Blancher
2024-02-27 15:05 ` Corinna Vinschen
2024-03-04  7:04   ` Cedric Blancher [this message]
2024-02-27 22:26 ` Bill Stewart
2024-02-29 14:38   ` Andrey Repin
2024-02-29 20:54     ` Bill Stewart
2024-03-04  7:05   ` Cedric Blancher

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CALXu0UfXsrjxjg39z86egJwYDWWdfihQ19bbaQHynjUoMQCrCA@mail.gmail.com \
    --to=cedric.blancher@gmail.com \
    --cc=cygwin@cygwin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).