From owner-freebsd-hackers Mon Aug 23 13:13:53 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from gratis.grondar.za (gratis.grondar.za [196.7.18.133]) by hub.freebsd.org (Postfix) with ESMTP id 1627215734; Mon, 23 Aug 1999 13:13:43 -0700 (PDT) (envelope-from mark@grondar.za) Received: from grondar.za (localhost [127.0.0.1]) by gratis.grondar.za (8.9.3/8.9.3) with ESMTP id WAA78393; Mon, 23 Aug 1999 22:12:39 +0200 (SAST) (envelope-from mark@grondar.za) Message-Id: <199908232012.WAA78393@gratis.grondar.za> To: "Daniel C. Sobral" Cc: Greg Lehey , Poul-Henning Kamp , Matthew Dillon , FreeBSD Hackers , FreeBSD Committers , Garrett Wollman Subject: Re: Mandatory locking? Date: Mon, 23 Aug 1999 22:12:38 +0200 From: Mark Murray Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG > > Now I suppose you're going to come and say that this is bad > > programming, and advisory locking would do the job if the software is > > written right. Correct. You could also use the same argument to say > > that memory protection isn't necessary, because a correctly written > > program doesn't overwrite other processes address space. It's the > > same thing: file protection belongs in the kernel. > > Well, I'd say advisory lock does the job if the software is written > right, and if the software is not written right, mandatory locking > won't help. Folk are all skirting around a very convenient (and necessary) loophole; in cases where there _is_ mandatory locking, there is always some meta-user which is allowed to violate this. In process-space, this is the kernel. In file-space, this should be root. Processes that require mandatory locking must revoke superuser before attempting locks. M -- Mark Murray Join the anti-SPAM movement: http://www.cauce.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message