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=Ke03C6Ynh+kvbieBbhSuKM979AnU6mI5ksJwyjJBmfb0uPvaoiSSb dSex/lu3EXBfz9HdIaxoz16fmB3Fj+GHLqI9edN4tRbm2cF1sEg8D4u6iHWdnK0/ w4QV6PxkZCkqZL2BJ5fU9X3iGQMm1uaWJ/grfTqzNUeQQuoB03zH48= 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=VsCS6OwZ2mCoNpM4aBd/1CeZ9Eo=; b=PX2LF7tT8D1REXe8781HKYVMcGr5 zF5E0Xhcw5iRJECxAP4CPc8SWP4lG5LIvPwBTKNSpEHmkZ66QzjyEKPW4/L/Kkgy 9Dbpsd/Lsr05CzoB4oW3QWAYJ/YBgTPV4cjtd0t1S0usGVDXRfBLKymJzLtagBCu x+hK6hIbW6rA6Vw= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , 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-Virus-Found: No X-Spam-SWARE-Status: No, score=-101.6 required=5.0 tests=BAYES_00,GOOD_FROM_CORINNA_CYGWIN,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=H*MI:sk:98eb08b, Opening, mechanism, H*F:D*cygwin.com X-HELO: drew.franken.de Date: Wed, 30 Nov 2016 11:47:24 +0100 From: Corinna Vinschen To: cygwin AT cygwin DOT com Subject: Re: Retrieving per-process environment block? Message-ID: <20161130104724.GD14074@calimero.vinschen.de> Reply-To: cygwin AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com References: <20161117140012 DOT GA23664 AT calimero DOT vinschen DOT de> <98eb08bf-5012-fe14-b10c-241b427c4366 AT cs DOT umass DOT edu> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="xesSdrSSBC0PokLI" Content-Disposition: inline In-Reply-To: <98eb08bf-5012-fe14-b10c-241b427c4366@cs.umass.edu> User-Agent: Mutt/1.7.1 (2016-10-04) --xesSdrSSBC0PokLI Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Nov 29 09:28, Eliot Moss wrote: > On 11/29/2016 8:26 AM, Erik Bray wrote: > > I could do this, if each process kept a copy of its environment block > > in shared memory, which would in turn have to be updated every time > > the process's environment is updated. But I don't know what the > > impact of that would be performance-wise. >=20 > Sorry, no advice getting around this, but a thought about why it may have > been hard -- it can be a security hole. Using the mechanism outlined in my mail from 2 minutes ago, there's no security problem. Opening the signal pipe is only allowed to same user processes or administrative processes. Other will get a /proc/$PID/environ content of "" Corinna --=20 Corinna Vinschen Please, send mails regarding Cygwin to Cygwin Maintainer cygwin AT cygwin DOT com Red Hat --xesSdrSSBC0PokLI Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCAAGBQJYPq47AAoJEPU2Bp2uRE+gndcQAIVwdVzMVD+xEr8cd6xf5x6U 2Yt03oHqCSCwDxtnoHYSs8YPzfyxjl6/N6nJTFw0/BDKWNdRw/WPO66OfFxuUH9K QeXkg2p1McmMmWcZyfYQwMueZ1EQLtrpGIwGjf/Bv9sxeFdB+MM+joWPOZI7jyPu 5ZIW3kDKGdbz4Yhgf7JMzPf7VdCpSNZuan5XvquQ7YTMq1DLXYVmh6+BL0upb68l /ziGrIQBH5LaXONqa/HbGRISn1N/iGARdY8Rx1LLUDbTh2LbtOl6U5AjtBVjS75t PxxQ0TrdZNLjjYAEYVQfILRUYgHJSTbS1e8G/q6qghwfhqEZ/OM1yG5EJ1sTXdS5 XDKwCdoTeFEUSN4RabuNZOxYVaOkYWGEz4xiqqFSy4PRJkiF6tAKmhguSIFT71Vl hguoqmuKOkfjyjtChZUSEZZao1Fi5/HEkgRvvdlEa0I5wdmuHy5lcaQopIIesovg xSJlahvuXy9JlxG8pxHJOgZz8gEgyPylzG7ifqDeAMgnMkaQyaUl2gN3jxB6TkEF 8SizG67aCPhFWjQVe21ESuCN95CnaePkKfdtHYz/NyCfBD70xRixVbhqMjlqOl+h rzmJM4T6PMULN4FlwvEWbx7g+ZF6cYwa8n1Mu8GQw3RM+4fDj+4OHWZFPYux00dd bpaI3LuhG6eiYX2GLD+I =5h1O -----END PGP SIGNATURE----- --xesSdrSSBC0PokLI--