From owner-freebsd-fs Mon Aug 28 10:38:27 2000 Delivered-To: freebsd-fs@freebsd.org Received: from fledge.watson.org (fledge.watson.org [204.156.12.50]) by hub.freebsd.org (Postfix) with ESMTP id 0A82537B424 for ; Mon, 28 Aug 2000 10:38:25 -0700 (PDT) Received: from fledge.watson.org (robert@fledge.pr.watson.org [192.0.2.3]) by fledge.watson.org (8.9.3/8.9.3) with SMTP id NAA86273; Mon, 28 Aug 2000 13:35:32 -0400 (EDT) (envelope-from robert@fledge.watson.org) Date: Mon, 28 Aug 2000 13:35:32 -0400 (EDT) From: Robert Watson X-Sender: robert@fledge.watson.org To: Poul-Henning Kamp Cc: freebsd-fs@FreeBSD.ORG Subject: Re: procfs_lookup() and jail interaction In-Reply-To: <11832.967483188@critter> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-fs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org On Mon, 28 Aug 2000, Poul-Henning Kamp wrote: > >So the check is still happening above the VFS layer. > > > >I'll look at the code further this evening. > > Hmm, but vn_open needs to find the vnode first, and that means > a VOP_LOOKUP into procfs doesn't it ? How else (when the vfscache > isn't used) would it know which vnode ? Sure enough, procfs_lookup() was missing a call to {PRISON_CHECK(), p_cansee()}, so adding one now gives the right results: alsvid:~> touch /proc/1 touch: /proc/1: Read-only file system I'll update p_stuff, and keep looking for other problems. Thanks, Robert N M Watson robert@fledge.watson.org http://www.watson.org/~robert/ PGP key fingerprint: AF B5 5F FF A6 4A 79 37 ED 5F 55 E9 58 04 6A B1 TIS Labs at Network Associates, Safeport Network Services To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-fs" in the body of the message