From owner-freebsd-fs@FreeBSD.ORG  Tue Feb 22 16:19:57 2011
Return-Path: <owner-freebsd-fs@FreeBSD.ORG>
Delivered-To: freebsd-fs@freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id B7CD21065673
	for <freebsd-fs@freebsd.org>; Tue, 22 Feb 2011 16:19:57 +0000 (UTC)
	(envelope-from jhb@freebsd.org)
Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42])
	by mx1.freebsd.org (Postfix) with ESMTP id 87A968FC14
	for <freebsd-fs@freebsd.org>; Tue, 22 Feb 2011 16:19:57 +0000 (UTC)
Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net
	[66.111.2.69])
	by cyrus.watson.org (Postfix) with ESMTPSA id 3ADD246B23;
	Tue, 22 Feb 2011 11:19:57 -0500 (EST)
Received: from jhbbsd.localnet (unknown [209.249.190.10])
	by bigwig.baldwin.cx (Postfix) with ESMTPSA id 7802C8A01D;
	Tue, 22 Feb 2011 11:19:56 -0500 (EST)
From: John Baldwin <jhb@freebsd.org>
To: freebsd-fs@freebsd.org
Date: Tue, 22 Feb 2011 09:31:17 -0500
User-Agent: KMail/1.13.5 (FreeBSD/7.4-CBSD-20110107; KDE/4.4.5; amd64; ; )
References: <201102211707.p1LH7c8n075660@lurza.secnetix.de>
	<476667.58379.qm@web121516.mail.ne1.yahoo.com>
	<20110222095211.GA96223@icarus.home.lan>
In-Reply-To: <20110222095211.GA96223@icarus.home.lan>
MIME-Version: 1.0
Content-Type: Text/Plain;
  charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
Message-Id: <201102220931.17733.jhb@freebsd.org>
X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6
	(bigwig.baldwin.cx); Tue, 22 Feb 2011 11:19:56 -0500 (EST)
X-Virus-Scanned: clamav-milter 0.96.3 at bigwig.baldwin.cx
X-Virus-Status: Clean
X-Spam-Status: No, score=0.5 required=4.2 tests=BAYES_00,MAY_BE_FORGED,
	RDNS_DYNAMIC autolearn=no version=3.3.1
X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bigwig.baldwin.cx
Cc: Kelly Dean <kellydeanch@yahoo.com>
Subject: Re: Why is procfs deprecated in favor of procstat?
X-BeenThere: freebsd-fs@freebsd.org
X-Mailman-Version: 2.1.5
Precedence: list
List-Id: Filesystems <freebsd-fs.freebsd.org>
List-Unsubscribe: <http://lists.freebsd.org/mailman/listinfo/freebsd-fs>,
	<mailto:freebsd-fs-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/freebsd-fs>
List-Post: <mailto:freebsd-fs@freebsd.org>
List-Help: <mailto:freebsd-fs-request@freebsd.org?subject=help>
List-Subscribe: <http://lists.freebsd.org/mailman/listinfo/freebsd-fs>,
	<mailto:freebsd-fs-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 22 Feb 2011 16:19:57 -0000

On Tuesday, February 22, 2011 4:52:11 am Jeremy Chadwick wrote:
> On Tue, Feb 22, 2011 at 12:45:36AM -0800, Kelly Dean wrote:
> > [ snipping stuff that I have no real response to :-) ]
> >
> > Jeremy, when you said procfs should be removed, did you mean just for
> > the same reasons Oliver said, or did you have other reasons?
> 
> The security issues are long-standing and there have been many over the
> years, but the real reason is something that's less evident (or at least
> less directly apparent):

Actually, the replacement for procfs is not sysctl, but ptrace(2), and there 
has been a long-running process in place to migrate tools such as truss, etc. 
from using procfs to use ptrace(2) instead and to add new features to 
ptrace(2) when there were things it did not support that procfs did.  One 
could argue that some of the more recent things like the sysctl's for procstat 
-v or procstat -k should have been implemented as new ptrace OPs rather than 
sysctls (and I'd probably agree with you).

-- 
John Baldwin