X-Spam-Check-By: sourceware.org
Date: Mon, 24 Apr 2006 17:11:45 +0100
From: Owen Rees <owen.rees@hp.com>
To: cygwin@cygwin.com
Subject: Re: useradd & user ids
Message-ID: <92CAA5F86D359B76AD557FAB@rees-o-3.labs.hpl.hp.com>
In-Reply-To: <20060424145044.GE28583@calimero.vinschen.de>
References: <4447CD75.9030505@elementcxi.com>  <Pine.GSO.4.63.0604201523160.10467@access1.cims.nyu.edu>  <44481791.6000902@elementcxi.com>  <Pine.GSO.4.63.0604210111260.7174@access1.cims.nyu.edu>  <20060421094115.GB12661@calimero.vinschen.de>  <Pine.GSO.4.63.0604211109320.26305@access1.cims.nyu.edu>  <20060421151856.GB23157@calimero.vinschen.de>  <D93009657DB6C48C2A8E6BF7@rees-o-3.labs.hpl.hp.com>  <20060424145044.GE28583@calimero.vinschen.de>
X-Mailer: Mulberry/4.0.4 (Win32)
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
X-IsSubscribed: yes
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
Precedence: bulk
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie.com@cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com

--On 24 April 2006 16:50 +0200 Corinna Vinschen wrote:

>> but 'mkpasswd -l -c' offers me an
>> entry with a uid that is my 6-digit RID plus 10000.
>
> The -c option always adds the default offset.  It's not intended for
> local accounts anyway.

It's not just -c that adds the 10000:

  mkpasswd.exe -d $USERDOMAIN -u $USERNAME

also gives a uid that is RID+10000.

The ntsec page mentions using mkpasswd and mkgroup but does not explain how 
the uid or gid is chosen. I think my comment was prompted by the mention of 
numbers of 4 digits earlier in this thread. Having a 6-digit RID for my 
domain account I can see that the uid generation does straightforward 
arithmetic and not some sort of string processing. (Is it really 19106 this 
year? Some people wrote code that thinks so.)


-- 
Owen Rees
Hewlett Packard Laboratories, Bristol, UK



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

