X-Recipient: archive-cygwin@delorie.com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
	:list-unsubscribe:list-subscribe:list-archive:list-post
	:list-help:sender:date:from:to:subject:message-id:reply-to
	:references:mime-version:content-type:in-reply-to; q=dns; s=
	default; b=SdS5x83rc873cBAbuwbgLuHjEPzv+DnmogA5kzCUxvCDxLug/iG48
	CbaYPSd573ToOF4pHC5BTnppWFZW614Y+qjfKqVGmOMbzQMpPztZ98HWHjQRodRI
	Nk2wlxb6cZLMbfjgd72evOyz3Cj/6fG8a76Li7BZJId3QNfrJK8URk=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
	:list-unsubscribe:list-subscribe:list-archive:list-post
	:list-help:sender:date:from:to:subject:message-id:reply-to
	:references:mime-version:content-type:in-reply-to; s=default;
	 bh=RNSjyZb3lDDOQChbvxFB0TcmAXI=; b=u6P3La+NgtTPiTJ7zLzwcHgFDoeX
	MU0N1YXfLcEy2kuochQalWvsd0dfPmYU/228kBRSvtX9WYVqd3yC2JdX0zSbo07P
	CYE7q/mIl8/DjOr+5YWqBDC+oWnrnfDGHCICHjgK1GyNRsm6vf9Qbo8cP1HbH5Cq
	zxH/tjEZRKjmwZk=
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Id: <cygwin.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
Authentication-Results: sourceware.org; auth=none
X-Virus-Found: No
X-Spam-SWARE-Status: No, score=-4.6 required=5.0 tests=AWL,BAYES_50 autolearn=ham version=3.3.2
X-HELO: calimero.vinschen.de
Date: Mon, 28 Jul 2014 11:14:09 +0200
From: Corinna Vinschen <corinna-cygwin@cygwin.com>
To: cygwin@cygwin.com
Subject: Re: The eternal uid issue
Message-ID: <20140728091409.GA25860@calimero.vinschen.de>
Reply-To: cygwin@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
References: <53CF6CEC.6D68E485@boland.nl> <20140723091409.GH27005@calimero.vinschen.de> <53CF9E0F.F596FC60@boland.nl> <20140723152357.GA24446@calimero.vinschen.de> <53D0AD3A.1FDF0B3F@boland.nl> <20140724135222.GD12212@calimero.vinschen.de> <53D17DCD.726524E0@boland.nl> <20140725124200.GC8725@calimero.vinschen.de> <53D604BC.1CBD4557@boland.nl>
MIME-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha1;	protocol="application/pgp-signature"; boundary="pWyiEgJYm5f9v55/"
Content-Disposition: inline
In-Reply-To: <53D604BC.1CBD4557@boland.nl>
User-Agent: Mutt/1.5.23 (2014-03-12)

--pWyiEgJYm5f9v55/
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Jul 28 10:07, D. Boland wrote:
> Corinna Vinschen wrote:
> > On Jul 24 23:42, D. Boland wrote:
> > > [...]
> > > If I have Sendmail running in preferred mode (main program as
> > > cyg_server, children running as 'smmsp', removed from admin group),
> > > stat returns the wrong mode (rwxrwxrwx). As a consequence, Sendmail
> > > refuses to deliver email.
> >=20
> > That shouldn't happen.  Unless your home dir is on FAT or FAT32
> > and you're using the wrong umask.  For a start, can you try this:
> >=20
> > Login as user smmsp twice, once with admin privs, once without.
> > [...]
>=20
> Here's the output I get on the terminal:
>=20
> [...]
> $ strace -o /tmp/stat.trace stat /home/daniel/
>   File: `/home/daniel/'
>   Size: 0               Blocks: 0          IO Block: 65536  directory
> Device: e82f1393h/3895399315d   Inode: 1970324836993607  Links: 1
> Access: (0755/drwxr-xr-x)  Uid: ( 1003/  daniel)   Gid: (  513/    None)
> Access: 2014-07-28 09:40:47.976156800 +0200
> Modify: 2014-07-17 11:40:03.095408000 +0200
> Change: 2014-07-17 11:40:03.095408000 +0200
>  Birth: 2014-05-22 17:00:44.538505600 +0200
> [...]
> $ strace -o /tmp/stat.trace.admin stat /home/daniel/
>   File: `/home/daniel/'
>   Size: 0               Blocks: 0          IO Block: 65536  directory
> Device: e82f1393h/3895399315d   Inode: 1970324836993607  Links: 1
> Access: (0755/drwxr-xr-x)  Uid: ( 1003/  daniel)   Gid: (  513/    None)
> Access: 2014-07-28 09:53:19.596934400 +0200
> Modify: 2014-07-17 11:40:03.095408000 +0200
> Change: 2014-07-17 11:40:03.095408000 +0200
>  Birth: 2014-05-22 17:00:44.538505600 +0200

The permissions are the same in both cases, 0755.  This doesn't help us,
unfortunately.

Still, are you using setuid method 1 or another method?  Is your home
dir the default /home/$USER as created from inside the Cygwin
environment?  Any chance your home dir has an unusual ACL?

Did you set up sshd as service?  If not, you might consider to do that
so you can check what happens when switching to the smmsp account.  Run
ssh-host-config as admin, install the service.  Create an authorized_keys
file for the smmsp user (run ssh-user-config under smmsp for instance),
then start the service.  Now login to the smmsp user account using
public key authentication, admin-enabled vs. non-admin as above(*), and
observe the permissions ls or stat show you for your home dir.  Are they
really different?  If so, let's see the strace output again.


Corinna


(*) Note that an ssh login to an admin account will always provide you
    with an admin-enabled user token, not an UAC-disabled one.

--=20
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

--pWyiEgJYm5f9v55/
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQIcBAEBAgAGBQJT1hRhAAoJEPU2Bp2uRE+gwzUP+wQw/4B/ReBsPQSCiBf0gJOO
L/8HyM/7SQ+z+ZGu2UcuxTIMuDqRCfYZQs7lyAwkKuHiPkf140KZQWOU4vJlB7+0
1bOabiUxAs4wIY1H2+tiP4GPYdISSpHdWVeSQBhFGwsyp2gDSj44ToTfvxEL542h
9HvhNG7c7TbDiSbq79LEHoKA9lfHcSxuvVCRuIt+0r7296WTU81mBcLfmwPksfxV
bmc5tB1S/k5KcogOTabDX/2T6uGf2sq1vDQWl3OWt+ytvlXhBCxtkBjILjF9PFAv
lSTIAkn+lYfxneM/93wHdA5B4Yklsfawz3ZYbMWDHShvyTSeIUMhGCDy4rNBuQ4s
24PFzInBm52EHZ3kIAogaUSiF/uI8ZLc72NsRX1Tu+4sVKWtK57EuolG1P4gENLs
1zMRQXCSDqAYWHH2xxOPqQTT1aEa1ZkUBySqWtiXUOhoTyv/sbHRJlBYOc21W2E/
r5neDN1U9VAiHi1PhU3qquqdCdEXIkxwj+M3pJ5jauvM/hcpKrlqYjM8yCxlcKEa
3O28AGxPHX9mn5+jyq4/rh9fO6VLB7us4B71z7f1ZxDJm2qGXeLPDcxyYgDDgKar
4fJEE+QejygExOK/nOojvxva+fwcLgGrpfHwr8LSUrolgJgyVlM/X4mqPn5dqZtG
9r21CpibSALfNKMYAmUt
=N/XF
-----END PGP SIGNATURE-----

--pWyiEgJYm5f9v55/--
