This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: [Patch, Fortran] Set umask(0600) before calling mkstemp
- From: Janne Blomqvist <blomqvist dot janne at gmail dot com>
- To: Tobias Burnus <burnus at net-b dot de>
- Cc: gcc-patches <gcc-patches at gcc dot gnu dot org>, "fortran at gcc dot gnu dot org" <fortran at gcc dot gnu dot org>
- Date: Wed, 10 Oct 2012 13:58:48 +0300
- Subject: Re: [Patch, Fortran] Set umask(0600) before calling mkstemp
- References: <50754E8F.90309@net-b.de>
On Wed, Oct 10, 2012 at 1:31 PM, Tobias Burnus <burnus@net-b.de> wrote:
> Depending on the system mkstemp might create the scratch files with 0666
> permission (e.g. glibc <= 2.06); for security reasons, it should use 0600.
> Thus, one is supposed to set a umask before calling the function (see, e.g.,
> the Linux man page for mkstemp).
>
> Build and regtested on x86-64-linux.
> OK for the trunk?
Ok, thanks for the patch.
> Is this something one should back port to the branches?
By all means, if you have the energy.
--
Janne Blomqvist