delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2009/03/23/15:41:56

X-Recipient: archive-cygwin AT delorie DOT com
X-Spam-Check-By: sourceware.org
Date: Mon, 23 Mar 2009 21:41:18 +0100
From: Corinna Vinschen <corinna-cygwin AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: [1.7] passwd: useless if used with a logged on domain user
Message-ID: <20090323204118.GY9322@calimero.vinschen.de>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <af075b00903201143q1ce21219g3643c0e67e8994ac AT mail DOT gmail DOT com> <20090321101004 DOT GU9322 AT calimero DOT vinschen DOT de> <20090322100907 DOT GA9322 AT calimero DOT vinschen DOT de> <af075b00903221034v180e635aka114fcde43f6cf00 AT mail DOT gmail DOT com> <20090322192205 DOT GH9322 AT calimero DOT vinschen DOT de> <af075b00903230735i9c228b1s2b0928b698427cd4 AT mail DOT gmail DOT com> <20090323145958 DOT GS9322 AT calimero DOT vinschen DOT de> <af075b00903230833u44399b81jb73bb597cfa4261b AT mail DOT gmail DOT com> <20090323164003 DOT GX9322 AT calimero DOT vinschen DOT de> <af075b00903231126g66bd79eu7aef04b9c4b75efd AT mail DOT gmail DOT com>
MIME-Version: 1.0
In-Reply-To: <af075b00903231126g66bd79eu7aef04b9c4b75efd@mail.gmail.com>
User-Agent: Mutt/1.5.19 (2009-02-20)
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT 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 Mar 23 18:26, Julio Costa wrote:
> On Mon, Mar 23, 2009 at 16:40, Corinna Vinschen wrote:
> > On Mar 23 15:33, Julio Costa wrote:
> >> On Mon, Mar 23, 2009 at 14:59, Corinna Vinschen wrote:
> >> > Using CheckTokenMembership isn't quite the way to go.  If I understand
> >> > you right that the idea is just checking if the token contains the
> >> > well-known Administrators group, I'll check in something equivalent.
> >>
> >> Ok. I'll be waiting for the a new check-in, then.
> >
> > I've applied another patch to passwd which now checks admin membership
> > by inspecting the token groups of the calling user.  As you proposed,
> > the default is now the local machine, unless trying to change the
> > caller's password itself.
> >
> 
> After a minor typo-killing:
> 
> ~/passwd $ diff -u passwd_118.c passwd_118b.c
> --- passwd_118.c        2009-03-23 17:56:55.268054500 +0000
> +++ passwd_118b.c       2009-03-23 18:10:55.925848600 +0000
> @@ -571,7 +571,7 @@
>    strcpy (user, optind >= argc ? getlogin () : argv[optind]);
> 
>    /* Changing password for calling user?  Use logonserver for user as well. */
> -  if (!server && optind < argc)
> +  if (!server && optind >= argc)
>      {
>        myself = 1;
>        if ((logonserver = getenv ("LOGONSERVER")))

Urgh.  Thanks for catching.  I fixed that together with the usage text
and the missing documentation of the -d option in the User's Guide.


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

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

- Raw text -


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