From owner-freebsd-audit Tue Feb 6 16:25:45 2001 Delivered-To: freebsd-audit@freebsd.org Received: from mail.gmx.net (pop.gmx.de [194.221.183.20]) by hub.freebsd.org (Postfix) with SMTP id 196F837B401 for ; Tue, 6 Feb 2001 16:25:27 -0800 (PST) Received: (qmail 15708 invoked by uid 0); 7 Feb 2001 00:25:25 -0000 Received: from p3e9bc2c4.dip.t-dialin.net (HELO forge.local) (62.155.194.196) by mail.gmx.net (mail02) with SMTP; 7 Feb 2001 00:25:25 -0000 Received: from thomas by forge.local with local (Exim 3.20 #1) id 14QIQC-000E20-00 for ; Wed, 07 Feb 2001 01:25:20 +0100 Date: Wed, 7 Feb 2001 01:25:20 +0100 From: Thomas Moestl To: freebsd-audit@freebsd.org Subject: patches to remove setgid kmem from systat Message-ID: <20010207012520.A53599@crow.dom2ip.de> Mail-Followup-To: Thomas Moestl , freebsd-audit@freebsd.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i Sender: owner-freebsd-audit@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Hi, here is a second set of patches (partly dependent on those previously posted for top), this time to remove setgid kmem from systat. Most data needed for systat -vmstat was already exported; I needed to add three sysctls, hw.nintr, hw.intrnames and hw.intrcnt. Those export the number of interrups, a list of zero-terminated interrupt names and a list if interrupt counters. I did not split the lists into various sysctls because I wanted to keep the old structures in the kernel (other programs might still use it), and doing it with the existing structures would be kind of a hassle. I think that is OK, though. For this, I had to add an include file for i386 and change one for alpha and ia64; I do not expect problems, but it would be good if someone could do a test-compile on one of these archs. systat -netstat uses only information that is currently exported via sysctl. For a large number of sockets, the new code might be slow, so the kvm code is still used if we have the privileges to access the relevant devices. For normal use, I think it is OK to remove setgid. The new patches are at: - for systat: http://www.tu-bs.de/~y0015675/systat.diff - for the kernel: http://www.tu-bs.de/~y0015675/sysctl2.diff The top changes are at: - for top: http://www.tu-bs.de/~y0015675/top.diff - for libkvm: http://www.tu-bs.de/~y0015675/libkvm.diff - for the kernel: http://www.tu-bs.de/~y0015675/sysctl.diff (those have been updated since my last post to remove some compile-time warnings, most of which weren't my fault ;-) Could these patches please reviewed and committed if OK? - thomas To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-audit" in the body of the message