Date: Sat, 19 Oct 1996 10:54:31 +1000 From: Andrew Tridgell <tridge@arvidsjaur.anu.edu.au> To: julian@whistle.com Cc: Guido.vanRooij@nl.cis.philips.com, freebsd-hackers@FreeBSD.org Subject: Re: fix for symlinks in /tmp (fwd) FYI Message-ID: <96Oct19.105441%2B1000est.65037-172%2B230@arvidsjaur.anu.edu.au> In-Reply-To: <326817C5.61133CF4@whistle.com> (message from Julian Elischer on Fri, 18 Oct 1996 16:50:29 -0700)
next in thread | previous in thread | raw e-mail | index | archive | help
> It's probably not THAT common, but it MIGHT cause someone to lose hours > in a very frustrating way.. How many hours have been lost in a "frustrating way" when someone has broken into a system or destroyed files by exploiting this type of hole ... Surely you've noticed all the "symlink-in-/tmp" style security holes discussed on places like bugtraq? > tmpfile creation should not follow a symlink anyhow.. yep, in an ideal world it wouldn't. Its just that programs that do it unsafely and scripts that redirect stuff temporarily into /tmp are all too common. Have you never written a shell script that does something like: #!/bin/sh tmpfile=/tmp/silly_name.$$ cat > $tmpfile grep foobar $tmpfile | cut -mumble | someprog | Mail mumble grep barfoo $tmpfile | otherprog > some_log_file rm $tmpfile I know I've written such stupid things many times. I also know they are bad, wrong and terrible. But its oh so tempting to get the job done .... And I know that lots of other people do the same :-) Cheers, Andrew
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?96Oct19.105441%2B1000est.65037-172%2B230>