Re: Security Anti Symlink Attack Patch for 2.1.71

Mark H. Wood (mwood@mhw.OIT.IUPUI.EDU)
Tue, 9 Dec 1997 14:27:32 -0500 (EST)


On Sun, 7 Dec 1997, Christoph Lameter wrote:

> Ok. Then I need to add condition 3 (which is already dealt with in the old
> patch)
>
> 3. Symlinks established by other user except root in +t dirs are not
> followed.
>
> Hmm. This again gets much too complicated..... Anyone got better thoughts?

Well, it seems to me that the safest way to do this is to abandon the
shared /tmp altogether and make every user provide his own ~/tmp. Best
would be to define an environment variable TMP to point to it, so you
could still do a single /tmp or put all the users' TMPs on a separate
scratch disk or.... It seems to work well on VMS. Set the protections
properly when the account is created, and if the user fiddles with them
then he gets what he deserves.

I know, I know: it would take years to get general agreement and many
more years to modify all of the programs that just assume /tmp . But you
asked.

Mark H. Wood, Lead System Programmer MWOOD@INDYVAX.IUPUI.EDU
Those who will not learn from history are doomed to reimplement it.