[FFmpeg-devel] [PATCH] wrap mkstemp with umask

Michael Niedermayer michaelni
Fri Jul 18 23:11:12 CEST 2008

On Thu, Jul 17, 2008 at 09:39:33PM +0200, Reimar D?ffinger wrote:
> Hello,
> On Thu, Jul 17, 2008 at 12:28:45PM -0700, Erik Hovland wrote:
> > It is possible that the current umask of the process creating the file
> > with mkstemp is such that the temp file could be writable by others then
> > the user. When mkstemp is used it can be wrapped with umask() calls to
> > make absolutely sure that the temp file cannot be tampered with.
> That makes it completely thread-unsafe.
> Since in the long time since this was last discussed and nobody bothered
> to do anything about it I am in favour of throwing out this code and its
> only user the libxvid 2-pass encoding along with it.
> I've had this in my local tree since ages, though done the ugly way:

What about
1. asking/reprotring this design issue on xvid-dev ?
2. just use stdin/out and point whoever complains to xvid-dev.
   use of stdin/out would be annoying but would be better than droping
   2 pass xvid support.

Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

No great genius has ever existed without some touch of madness. -- Aristotle
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20080718/315e60af/attachment.pgp>

More information about the ffmpeg-devel mailing list