From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8298 invoked by alias); 11 Mar 2019 21:28:50 -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 8286 invoked by uid 89); 11 Mar 2019 21:28:50 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-102.2 required=5.0 tests=AWL,BAYES_00,GOOD_FROM_CORINNA_CYGWIN,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 spammy=privileges, permissions, she, showing X-HELO: mout.kundenserver.de Received: from mout.kundenserver.de (HELO mout.kundenserver.de) (217.72.192.75) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 11 Mar 2019 21:28:49 +0000 Received: from calimero.vinschen.de ([24.134.7.25]) by mrelayeu.kundenserver.de (mreue107 [212.227.15.183]) with ESMTPSA (Nemesis) id 1Mc0Aj-1gUxSz1gj9-00dWpx for ; Mon, 11 Mar 2019 22:28:46 +0100 Received: by calimero.vinschen.de (Postfix, from userid 500) id DCE2AA80461; Mon, 11 Mar 2019 22:28:45 +0100 (CET) Date: Mon, 11 Mar 2019 21:28:00 -0000 From: Corinna Vinschen To: cygwin@cygwin.com Subject: Re: Privilege(s) needed to run top command Message-ID: <20190311212845.GE3785@calimero.vinschen.de> Reply-To: cygwin@cygwin.com Mail-Followup-To: cygwin@cygwin.com References: <1552323028120-0.post@n5.nabble.com> <87r2bd4003.fsf@Rainer.invalid> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="NEAjDeynQrrxd8+d" Content-Disposition: inline In-Reply-To: <87r2bd4003.fsf@Rainer.invalid> User-Agent: Mutt/1.11.3 (2019-02-01) X-SW-Source: 2019-03/txt/msg00260.txt.bz2 --NEAjDeynQrrxd8+d Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-length: 1483 On Mar 11 21:41, Achim Gratz wrote: > jwang writes: > > This is used to work for a ordinary login. > > > > After re-install, top does not show the true load et al. Nor processes > > owned by SYSTEM. > > > > Please shed some light. >=20 > Cygwin is a user-space layer. It can't show you information that the > underlying OS determines to be off-limits for you. And I just checked, even under Cygwin 2.11.2, procps and top were not showing foreign processes if you're running under a non-admin user account or a non-elevated shell, so this is nothing new. In fact, `procps' at least tries to access /proc//stat. This doesn't return valid information because it has to be able to open a process with PROCESS_QUERY_LIMITED_INFORMATION and PROCESS_VM_READ permissions. No ordinary user has these permissions on processes she doesn't own.(*) However, Cygwin's `ps -e' was supposed to show all processes, but it didn't anymore since I created helper objects in the NT namespace with insufficient privileges for everyone. I pushed a patch and uploaded new developer snapshots to https://cywin.com/snapshots/ for testing. Thanks, Corinna (*) That doesn't mean it's not possible. In theory all Cygwin processes could be opened to allow everyone PROCESS_QUERY_LIMITED_INFORMATION access, which would at least fill most of /proc//stat for foreign processes. However, we never did that, so it can't have worked yet. --=20 Corinna Vinschen Cygwin Maintainer --NEAjDeynQrrxd8+d Content-Type: application/pgp-signature; name="signature.asc" Content-length: 833 -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEoVYPmneWZnwT6kwF9TYGna5ET6AFAlyG0w0ACgkQ9TYGna5E T6B7/hAAhtGBgHAVr6tGPCKUMf1rVBx9fX3SW40sSCEKxffT/dtA9TmB1KPEIfgi Hug7J274gpmT83GFsVYrdxXYgtti9nd3owkrFG5V8La2cJHpzpRH6AStSBrOrj34 LF38ALyde7rWHGz5YA1+24ngrWydQDBkAyK/lgnutk//AyiqTI2GGmLO6xF1iUgA fWMwdNaoeQyO+toPDti4UqyKbW9jKzxIOGqhNVl2K4uIPBJ8mO8nL2aeJfvG+HUo 47Tf0UOPYn1yAcEf9u0bhKfK8rUmw2PbdUkwSyR8DOvRpyRQjQU8RdQI90Wtk/lQ WvUgYdf+kTHolwWBlVKcJo9gM6oOjm8Pv4Sz4dXzqit+8pa5LALjq4cUFlK23I5m Wv3TOKC1b0M1HquYqRacmey+TPgaE+NZIpEodAS6IWgfwE/xaEJdpmJbnFn+bPQ9 GESZcTkIdQrax74+oF3+cgA1CY3YrmeghDFQNaXDU0Pg9CKozaWFSQcZAqP4c7gy 9/JWgXYjLWS/v5wYxTPkVcdEPwNQM+B+K6TRqSUaoA3uvUS01RgrCrqBa/liOwNo RPvyg73gsVDyRC5TWnaOc+VddrvXh847+i/7kJEc1aVx/Qih9BzDhYTPSkkPL/Se JF7J7VXCqerId1sVJ1GahBgNGLrBdDevL+/UODyCtDvFG4zG43k= =FSLG -----END PGP SIGNATURE----- --NEAjDeynQrrxd8+d--