Date: Fri, 28 Jan 2005 15:31:33 +0100 From: Pawel Jakub Dawidek <pjd@FreeBSD.org> To: Poul-Henning Kamp <phk@phk.freebsd.dk> Cc: Kris Kennaway <kris@obsecurity.org> Subject: Re: fstat triggered INVARIANTS panic in memrw() Message-ID: <20050128143133.GA795@darkness.comp.waw.pl> In-Reply-To: <38517.1106917155@critter.freebsd.dk> References: <200501280254.j0S2sMJH050277@blue.mwk.domain> <38517.1106917155@critter.freebsd.dk>
next in thread | previous in thread | raw e-mail | index | archive | help
--CKsGbYqZLAW+svb0 Content-Type: text/plain; charset=iso-8859-2 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Jan 28, 2005 at 01:59:15PM +0100, Poul-Henning Kamp wrote: +> In message <200501280254.j0S2sMJH050277@blue.mwk.domain>, "Mark W. Krent= el" writes: +> >I've looked a little deeper into Kris's fstat panic. +> >Turns out there are bugs in three places. +> > +> >(1) fstat(1) sometimes calls kvm_read() with a ridiculously out-of- +> >bounds value for nbytes. +>=20 +> The only real problem here is that fstat(1) uses kvm in the first place. +> The necessary information should be exported via sysctls. +>=20 +> No program used as part of regular system operation should use kvm. I've work mostly done in pjd_fuser branch. I modified existing (but not used by anything right now) sysctl kern.file to be able to export everything what things like fstat(1) needs. The main reason for doing this was to create posix-compilant fuser(1) utility (which exist in Solaris and Linux). --=20 Pawel Jakub Dawidek http://www.wheel.pl pjd@FreeBSD.org http://www.FreeBSD.org FreeBSD committer Am I Evil? Yes, I Am! --CKsGbYqZLAW+svb0 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (FreeBSD) iD8DBQFB+kzFForvXbEpPzQRAl5FAKCUMAt7vGsY9bycJBKs/JPe9Q8OMACgtNHN +OA5fZlZ3nq+S6/d/Cxv/RA= =Ukow -----END PGP SIGNATURE----- --CKsGbYqZLAW+svb0--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050128143133.GA795>
