enhance security via private TMP/TMPDIR by default

Peter Jones pjones at redhat.com
Fri May 27 20:15:45 UTC 2005


On Tue, 2005-05-24 at 18:24 -0400, Matthew Miller wrote:
> On Tue, May 24, 2005 at 06:18:43PM -0400, Peter Jones wrote:
> > > 1. Each user should have there own ~/tmp space which only they can
> > > access.  This could be used for the users agent sockets, but also just
> [...]
> > Of course, ~/tmp/ really sucks for this -- lots of places use nfs
> > homedirs, and you'd rather not put the sort of stuff you use /tmp for on
> > the network.
> 
> Which goes back to my original post here, which cleverly (?) checks if ~/tmp
> is on a local filesystem and uses mktemp in /tmp otherwise.

Yeah, that's better than just blindly using ~/tmp/.  But why have the
extra complexity?  Why not always do mktemp and the bind+namespace
magic?  This does have some advantage -- all users' tmp dirs are created
the way the admin intended when he set the system up, and they're easy
to find if he needs to look for them, for whatever reason.

-- 
        Peter




More information about the devel mailing list