[cfe-dev] RFC: Move default module cache path from /tmp

Neil Nelson via cfe-dev cfe-dev at lists.llvm.org
Sun Jun 21 10:50:04 PDT 2020


nnelson at x570:~$ mktemp -d
/tmp/tmp.lOPA8997cg
nnelson at x570:~$ ls -ld /tmp/tmp.lOPA8997cg
drwx------ 2 nnelson nnelson 40 Jun 21 11:27 /tmp/tmp.lOPA8997cg

This shows that mktemp creates a directory under /tmp with only the 
user's access permissions.

/tmp currently defaults to disk when Ubuntu is installed. There may be 
cases where some distributions mount /tmp in memory. I have changed 
fstab here to mount /tmp in memory.

Neil Nelson

On 6/21/20 3:54 AM, David Zarzycki via cfe-dev wrote:
> Hello,
>
> I'd like to request that we move the default module cache that is 
> currently created in /tmp to somewhere that isn't a shared writable 
> directory (with all of the associated security risks).
>
> The traditional Unix solution for caches (web browser, ccache, etc) is 
> to have a directory in $HOME.
>
> I'd like to suggest moving the clang module cache there.
>
> Dave
>
> _______________________________________________
> cfe-dev mailing list
> cfe-dev at lists.llvm.org
> https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20200621/69e66ce5/attachment.html>


More information about the cfe-dev mailing list