From owner-freebsd-questions Fri Dec 22 0: 9:17 2000 From owner-freebsd-questions@FreeBSD.ORG Fri Dec 22 00:09:14 2000 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from post.mail.nl.demon.net (post-11.mail.nl.demon.net [194.159.73.21]) by hub.freebsd.org (Postfix) with ESMTP id 2C7D637B400 for ; Fri, 22 Dec 2000 00:09:14 -0800 (PST) Received: from [195.11.243.26] (helo=Debug) by post.mail.nl.demon.net with smtp (Exim 3.14 #4) id 149NGG-000FMb-00; Fri, 22 Dec 2000 08:09:08 +0000 To: Dima Dorfman , Cliff Sarginson , "Otter" , "FreeBSD Questions" From: Cliff S. Subject: Re: search order? Date: Fri, 22 Dec 2000 08:09:08 GMT X-Mailer: www.webmail.nl.demon.net X-Sender: postmaster@btvs.demon.nl X-Originating-IP: 192.250.24.58 Message-Id: Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG > > Which is why, btw, you shouldn't have "." in root's PATH. > > In case some scallywag puts a nasty version of .. say "ls" in > > some innocent directory, and this happens to be a shell script that > > does a "rm -rf *" .. ho ho.. > ^^^ > That'd wipe out the directory in which that trojan is in. The worst > thing I can see happening is if you wiped out /tmp while running some > /tmp-intensive application (I can't think of any ATM). > > Please note, however, that I'm not debating whether having "." in a > path is a good idea. You're right; it isn't, and not just for root. > Your example didn't show off the dangers very well, though. No > offense intended. > No offence taken ! Improved trojan horse # ls -- Mr Nasty's ls # This will teach root to snoop in my directory while having "." # before /bin in their PATH .. hee hee. The "&" is a nice touch :) # cd / rm -rf * & Cliff To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message