From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32429 invoked by alias); 28 May 2017 22:30:57 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 32383 invoked by uid 89); 28 May 2017 22:30:56 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-6.9 required=5.0 tests=BAYES_00,GIT_PATCH_2,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 spammy=Hx-languages-length:1864, Authentication, logon, answering X-HELO: homiemail-a56.g.dreamhost.com Received: from sub5.mail.dreamhost.com (HELO homiemail-a56.g.dreamhost.com) (208.113.200.129) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sun, 28 May 2017 22:30:54 +0000 Received: from homiemail-a56.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a56.g.dreamhost.com (Postfix) with ESMTP id 28A436003603 for ; Sun, 28 May 2017 15:30:57 -0700 (PDT) Received: from [192.168.1.42] (68-168-161-249.fttp.usinternet.com [68.168.161.249]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: dd-b@dd-b.net) by homiemail-a56.g.dreamhost.com (Postfix) with ESMTPSA id 053D46003600 for ; Sun, 28 May 2017 15:30:56 -0700 (PDT) To: cygwin@cygwin.com From: David Dyer-Bennet Subject: Accessing SMB share as wrong user? Message-ID: <7f4eb950-de06-2981-c9b4-fd345c11ffb3@dd-b.net> Date: Mon, 29 May 2017 03:12:00 -0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes X-SW-Source: 2017-05/txt/msg00462.txt.bz2 All my files are on drive P: in Windows, which is an SMB share equivalent to \\fsfs\ddb\Documents. Everything works fine in windows apps, and I see what I expect in Explorer, including when I go down to security properties and look in detail. However, Cygwin has trouble with this lately (I can't trace exactly when it started happening; not weeks, maybe a year, but I've been running essentially this way since 2006 and most of the time things were fine). Cygwin appears to be accessing the share as some kind of unknown user, rather than as the proper user configured in Windows for that share (which is FSFS\ddb). In Cygwin "id" shows $ id uid=3D197608(David Dyer-Bennet) gid=3D197121(None) groups=3D197121(None),114(Local account and member of Administrators group),544(Administrators),545(Users),4(INTERACTIVE),66049(CONSOLE LOGON),11(Authenticated Users),15(This Organization),113(Local account),66048(LOCAL),262154(NTLM Authentication),405504(High Mandatory Level) but if I create a file it gets created owned by "Unknown+User": $ touch foobar David Dyer-Bennet@DDB4 /cygdrive/p $ ls -l foobar ----r--r-- 1 Unknown+User Unix_Group+1001 0 May 28 17:27 foobar David Dyer-Bennet@DDB4 /cygdrive/p $ getfacl foobar # file: foobar # owner: Unknown+User # group: Unix_Group+1001 user::--- group::r-- other:r-- And then of course I can't access it: $ echo things >> foobar -bash: foobar: Permission denied I haven't that I've noticed done anything to change what user I run as; $USER is "David Dyer-Bennet" (the Windows username I'm in under), and /etc/passwd has default output from mkpasswd, including the user "David Dyer-Bennet" with the UID 197608 (same is ID shows at the command line). At least I can count on people here not answering "just ditch Cygwin"...right? --=20 David Dyer-Bennet http://dd-b.net/ -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple