lkml.org 
[lkml]   [2015]   [Dec]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v2 1/2] um: Set secure access mode for temporary file
From
Date
Am 08.12.2015 um 21:37 schrieb Tristan Schmelcher:
> On 6 December 2015 at 09:43, Mickaël Salaün <mic@digikod.net> wrote:
>> Well, I'm concerned to use umask because it is not thread-safe and drivers may use create_mem_file() in a multi-theaded context.
>
> You are right. We should perhaps set the umask to 0700 permanently
> during process start. But I am not sure if this will interfere with
> other UML code.

It *should* not hurt. Let's see what explodes. :)

>> I prefer to stick to fchmod and handle the race-condition with O_TMPFILE unsell someone is sure that this will not create bugs :)
>
> The fchmod call is basically useless and should probably be removed.

I agree.

Thanks,
//richard


\
 
 \ /
  Last update: 2015-12-08 23:21    [W:0.321 / U:0.292 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site