delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2019/02/17/10:07:24

X-Recipient: archive-cygwin AT delorie DOT 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=kqpyTbAXTNOeU5Z+bN5Cf+togVy4dHRv4N2bZ8oembj+x7Kq6dXkN
uRWDkILhh/3io2hHUZ1ZCfuR7N360XXEiGOXSNPIlufNX13rCjH2BU2Kkf7ML3SZ
24qWluers3Oy7tO3S0kPh9bJPcDKfdsXNbNRA1kSWQaWyIZ7Wct6nQ=
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=N5+bPq2AXbxme7syoHUuR87/tqI=; b=JDdyvZeGPwXEu/VQoFf+VeGxogNI
Ydcm206oHGlDPZnOLJnqZyYkdv7T8g+wcn/lXysgWknuA9xtl741TaFn6PlMRa09
TWPn1ugUN5aH4NMVjLhC4wMmElWZ8ezl5niis6T6vZo6ZWz32ez7Mr+znsmYrLYB
lF+y2HUx3MnTbHw=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.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
Authentication-Results: sourceware.org; auth=none
X-Spam-SWARE-Status: No, score=-110.4 required=5.0 tests=BAYES_00,GIT_PATCH_2,GIT_PATCH_3,GOOD_FROM_CORINNA_CYGWIN,KAM_LAZY_DOMAIN_SECURITY,KAM_NUMSUBJECT,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 spammy=tomorrow, H*F:D*cygwin.com
X-HELO: mout.kundenserver.de
Date: Sun, 17 Feb 2019 16:07:06 +0100
From: Corinna Vinschen <corinna-cygwin AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: fixup_mmaps_after_fork failure with cygwin-3.0.0
Message-ID: <20190217150706.GN4256@calimero.vinschen.de>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <1d506605-a0af-12c2-6faf-ac74ab842182 AT cornell DOT edu> <20190217090820 DOT GI4256 AT calimero DOT vinschen DOT de> <20190217091308 DOT GK4256 AT calimero DOT vinschen DOT de> <0587a444-6849-b35f-60b1-700282408f07 AT cornell DOT edu>
MIME-Version: 1.0
In-Reply-To: <0587a444-6849-b35f-60b1-700282408f07@cornell.edu>
User-Agent: Mutt/1.10.1 (2018-07-13)

--bX/mw5riLlTkt+Gv
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Feb 17 14:56, Ken Brown wrote:
> On 2/17/2019 4:13 AM, Corinna Vinschen wrote:
> > On Feb 17 10:08, Corinna Vinschen wrote:
> >> On Feb 17 00:11, Ken Brown wrote:
> >>> I'm getting a lot of errors like this when building emacs from its gi=
t repo:
> >>>
> >> Weird.  I built at least gawk and openssh with 3.0 already and I
> >> didn't notice this problem.
> >>
> >>> A bisection points to the following as the first bad commit:
> >>>[...]
> >>> I'll try to do some debugging and/or provide further information
> >>> tomorrow, but I thought I'd start with this preliminary report.
> >>
> >> That would be nice.  It's not clear to me which permission is missing.
> >> The first part of the patch has been reverted in 3.0.0, so
> >> child_info_spawn::get_parent_handle opens the parent with
> >> PROCESS_VM_READ again.  The second patch has been reworked as well,m
> >> the current perms are
> >>
> >> PROCESS_QUERY_LIMITED_INFORMATION | PROCESS_VM_READ | SYNCHRONIZE
> >>
> >> If I may place a bet, please try to replace
> >> PROCESS_QUERY_LIMITED_INFORMATION with PROCESS_QUERY_INFORMATION
>=20
> That didn't change anything.  Just to make sure I understood correctly, h=
ere's=20
> what I tried:
>=20
> --- a/winsup/cygwin/sigproc.cc
> +++ b/winsup/cygwin/sigproc.cc
> @@ -814,7 +814,7 @@ child_info::child_info (unsigned in_cb, child_info_ty=
pes chtype,
>        allow the child to copy cygheap etc. from the parent to itself.  If
>        we're forking, we also need handle duplicate access. */
>     parent =3D NULL;
> -  DWORD perms =3D PROCESS_QUERY_LIMITED_INFORMATION | PROCESS_VM_READ
> +  DWORD perms =3D PROCESS_QUERY_INFORMATION | PROCESS_VM_READ
>                  | SYNCHRONIZE;
>     if (type =3D=3D _CH_FORK)
>       {
>=20
> > On second thought, an even better candidate may be PROCESS_VM_OPERATION.
>=20
> That's even worse.  With that change, simply invoking 'make' leads to
> the same error.

PROCESS_VM_OPERATION has to be specified additionally, not replacing
PROCESS_QUERY_{LIMITED_}INFORMATION.  Sorry if that wasn't clear.

Another idea is to specify all process-specific permissions from
https://docs.microsoft.com/en-us/windows/desktop/ProcThread/process-securit=
y-and-access-rights
and then eliminate backwards.


Corinna

--=20
Corinna Vinschen
Cygwin Maintainer

--bX/mw5riLlTkt+Gv
Content-Type: application/pgp-signature; name="signature.asc"

-----BEGIN PGP SIGNATURE-----

iQIzBAEBCAAdFiEEoVYPmneWZnwT6kwF9TYGna5ET6AFAlxpeJoACgkQ9TYGna5E
T6C5jBAAnR3qhHA471m/61iclwl8NdbEB+hzwGvwRr91D+0GjGUvK2qPd1z3ADu+
CbTpJppw9aVXFtkd5FKbwbKEYtr2rjqEoFSIHbRFTZxbcvTlt5wFBMYZ1i2wS5TW
9XEJsuICyxgFFwSbsVur76lla80E3QpjVncwkn6eKM3nsoww3Vgakv778csDmkJU
v78Ssw9lzyZ0mzgYFljzl2lLreITSMfLXzUMClBh4QO0THfVSo86sb+4PutpTgVL
ejIaDUnksw/8bwBdtQFFq7iayLkiX/xyo/VWL4PN5ED4azq1T08XQtJRo2DEbRq+
0ngAf4L1Vk/Ka61JQzfQfpSw1MDM2ms74sqT0aCvAsPG1FZXfRxmKyDrRN2xCMO3
2IwAldrwsvm9XFWmpvvV9Se8LutlWmP8WnchcRwFqsvs+umUzN0h4+g72KvSAC/S
tOyydAqhzwA2iZQmoCYXmjkLOiIIH113r290ZXIV2YEmN9+aiF0BRQ5EeXxUP3aX
MffJMoUu9lzBIEL7Qetmzb2OGukOxH+1y/YTEQTcioRlMRVsb+ksBBxMfPjI4RKY
6bnPLTS34yzorgesLouBCYmJRtW9cOd5M3ViXM5XM/qkFss0hY1Xzbei71WJfTv8
GZdlIQjOabVQ488qwvmKWcWKHRiG5YFo43fyxYkXJDe8fIbV4p0=
=oM/v
-----END PGP SIGNATURE-----

--bX/mw5riLlTkt+Gv--

- Raw text -


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