From owner-freebsd-hackers Mon Sep 18 14:09:57 1995 Return-Path: owner-hackers Received: (from root@localhost) by freefall.freebsd.org (8.6.12/8.6.6) id OAA02771 for hackers-outgoing; Mon, 18 Sep 1995 14:09:57 -0700 Received: from phaeton.artisoft.com (phaeton.Artisoft.COM [198.17.250.211]) by freefall.freebsd.org (8.6.12/8.6.6) with ESMTP id OAA02752 for ; Mon, 18 Sep 1995 14:09:48 -0700 Received: (from terry@localhost) by phaeton.artisoft.com (8.6.11/8.6.9) id OAA08630; Mon, 18 Sep 1995 14:06:56 -0700 From: Terry Lambert Message-Id: <199509182106.OAA08630@phaeton.artisoft.com> Subject: Re: suspect code in 'unlink' syscall. To: julian@ref.tfs.com (Julian Elischer) Date: Mon, 18 Sep 1995 14:06:56 -0700 (MST) Cc: julian@ref.tfs.com, hackers@FreeBSD.ORG In-Reply-To: <199509180806.BAA01219@ref.tfs.com> from "Julian Elischer" at Sep 18, 95 01:06:48 am X-Mailer: ELM [version 2.4 PL24] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Content-Length: 565 Sender: owner-hackers@FreeBSD.ORG Precedence: bulk > > now, if we were NOT root, and it IS a dir...... (normal...) > > > > can we delete it? > The answer is 'NO' but I'm not sure I see why.. Because the underlying FS will prevent it. > AH I just found it.. only root can unlink a dir, all others can > only do 'rmdir' calls.. ok, I admit it.. I need to go to sleep. No, this is a good correction. The semantics should be enforced at the system call layer where possible. Terry Lambert terry@lambert.org --- Any opinions in this posting are my own and not those of my present or previous employers.