From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Lennart Borgman (gmail)" Newsgroups: gmane.emacs.devel,gmane.emacs.pretest.bugs Subject: Re: 23.0.60; uid problems on w32 Date: Mon, 31 Mar 2008 21:47:43 +0200 Message-ID: <47F13FDF.6010008@gmail.com> References: <47EEBE03.9030104@gmail.com> <47EEE4D9.9090600@gnu.org> <47EFA826.6070907@gnu.org> <47EFB17F.70903@gmail.com> <47EFF936.8080108@gmail.com> <47EFFE20.6030209@gmail.com> <47F0A3C6.6090006@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1206992924 22706 80.91.229.12 (31 Mar 2008 19:48:44 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 31 Mar 2008 19:48:44 +0000 (UTC) Cc: emacs-pretest-bug@gnu.org, monnier@iro.umontreal.ca, Jason Rumney To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Mar 31 21:49:15 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1JgQ0H-0003r7-NS for ged-emacs-devel@m.gmane.org; Mon, 31 Mar 2008 21:49:14 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JgPze-0001wo-F0 for ged-emacs-devel@m.gmane.org; Mon, 31 Mar 2008 15:48:34 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JgPz7-0001Yy-5h for emacs-devel@gnu.org; Mon, 31 Mar 2008 15:48:01 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JgPz5-0001YK-QB for emacs-devel@gnu.org; Mon, 31 Mar 2008 15:48:00 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JgPz5-0001YE-CD for emacs-devel@gnu.org; Mon, 31 Mar 2008 15:47:59 -0400 Original-Received: from fencepost.gnu.org ([140.186.70.10]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JgPz5-0001CI-06 for emacs-devel@gnu.org; Mon, 31 Mar 2008 15:47:59 -0400 Original-Received: from mx10.gnu.org ([199.232.76.166]) by fencepost.gnu.org with esmtp (Exim 4.67) (envelope-from ) id 1JgPz3-0003NL-V0 for emacs-pretest-bug@gnu.org; Mon, 31 Mar 2008 15:47:58 -0400 Original-Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1JgPz1-0001Bi-41 for emacs-pretest-bug@gnu.org; Mon, 31 Mar 2008 15:47:58 -0400 Original-Received: from ch-smtp02.sth.basefarm.net ([80.76.149.213]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1JgPyt-00019m-NS; Mon, 31 Mar 2008 15:47:48 -0400 Original-Received: from c83-254-150-27.bredband.comhem.se ([83.254.150.27]:63639 helo=[127.0.0.1]) by ch-smtp02.sth.basefarm.net with esmtp (Exim 4.68) (envelope-from ) id 1JgPyq-0004DF-9S; Mon, 31 Mar 2008 21:47:45 +0200 User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.9) Gecko/20071031 Thunderbird/2.0.0.9 Mnenhy/0.7.5.666 In-Reply-To: X-Antivirus: avast! (VPS 080330-0, 2008-03-30), Outbound message X-Antivirus-Status: Clean X-Originating-IP: 83.254.150.27 X-ACL-Warn: Too high rate of unknown addresses received from you X-Scan-Result: No virus found in message 1JgPyq-0004DF-9S. X-Scan-Signature: ch-smtp02.sth.basefarm.net 1JgPyq-0004DF-9S c376cbb22392ab0d965319d974bb778f X-detected-kernel: by monty-python.gnu.org: Linux 2.6? (barebone, rare!) X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:94063 gmane.emacs.pretest.bugs:21826 Archived-At: Eli Zaretskii wrote: >> Date: Mon, 31 Mar 2008 09:41:42 +0100 >> From: Jason Rumney >> CC: "Lennart Borgman (gmail)" , >> monnier@iro.umontreal.ca, emacs-pretest-bug@gnu.org >> >> There is a function user-real-uid that may be able to be extended to >> contain the full id. Currently it is documented as returning a float or >> int, neither of which will contain a SID without losing precision. We'd >> have to check the users first. If elisp had a bignum type, it would be >> the best choice, as a cons cell will require different code for >> processing it. But before embarking on this, I'd like to see a case that >> actually needs it, as there are many other areas where we could be >> spending our limited resources. > > I'm not sure such an endeavor would be justified. After all, it's > quite possible to have two users on two Posix machines that have the > same uid, right? So this problem is not unique to Windows. > > Cygwin added the offset because they had a specific problem in the > mkpasswd program: it would create 2 user accounts for 2 different > users with the same uid. Emacs doesn't have such a problem: we don't > create user accounts. All we need to do is return a uid and user name > for each SID we get, and perhaps also handle the case where two > different SIDs map to the same uid, so that we don't return incorrect > user name for a given uid or vice versa. This can be done by caching > the full SIDs internally (I have somewhere a version of `stat' that > does precisely that, which I wrote for my private port of GNU `ls'). I do not understand. When the full SID is gone how can you distunguish between all SIDs mapping to a uid?