From owner-freebsd-hackers Thu Jan 25 01:09:40 1996 Return-Path: owner-hackers Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id BAA03283 for hackers-outgoing; Thu, 25 Jan 1996 01:09:40 -0800 (PST) Received: from paris.CS.Berkeley.EDU (paris.CS.Berkeley.EDU [128.32.34.47]) by freefall.freebsd.org (8.7.3/8.7.3) with SMTP id BAA03274 for ; Thu, 25 Jan 1996 01:09:37 -0800 (PST) Received: (from jmacd@localhost) by paris.CS.Berkeley.EDU (8.6.11/8.6.9) id BAA19980 for freebsd-hackers@freebsd.org; Thu, 25 Jan 1996 01:09:28 -0800 Date: Thu, 25 Jan 1996 01:09:28 -0800 From: Josh MacDonald Message-Id: <199601250909.BAA19980@paris.CS.Berkeley.EDU> To: freebsd-hackers@freebsd.org Subject: sticky directory symlinks Sender: owner-hackers@freebsd.org Precedence: bulk I apologize if this has been discussed before, though I couldn't find anything on the subject. I asked a NetBSD user and he said he recalled some discussion on this topic but didn't recall the results. I just encountered the following problem: axis-/tmp % ls -ld . drwxrwsrwt 4 root wheel 512 Jan 25 00:46 ./ axis-/tmp % ln -s this sucks axis-/tmp % ls -l sucks lrwxrwsrwt 1 root wheel 4 Jan 25 00:46 sucks@ -> this axis-/tmp % rm sucks rm: sucks: Operation not permitted /tmp is mode 1777 and when I create a symlink I can't remove it. I notice that the link shares the sticky dirs inode. I think this is very very bad. I guess that an optimization is made where the linkname is kept in the directory file instead of on disk but if its a sticky directory, then I can't remove something I create. That sucks a lot. Has this been brought up before? -josh