lkml.org 
[lkml]   [2014]   [Nov]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH] devcoredump: provide a one-way disable function
From
On Thu, Nov 13, 2014 at 2:36 PM, Johannes Berg
<johannes@sipsolutions.net> wrote:
> On Thu, 2014-11-13 at 13:56 -0800, Kees Cook wrote:
>
>> > + /*
>> > + * This essentially makes the attribute write-once, since you can't
>> > + * go back to not having it disabled. This is intentional, it serves
>> > + * as a system lockdown feature.
>> > + */
>> > + if (tmp != 1)
>> > + return -EINVAL;
>>
>> Just a nit, but writing "0" is valid if devcd_disabled = false?
>
> I thought about that too, but what would the point be? The only
> operation you ever can/want to do is writing "1" to it to disable the
> framework.

Yup, seems like not a useful thing to do, but figured I'd point it out
just in case. I think the patch is fine as-is.

-Kees

--
Kees Cook
Chrome OS Security


\
 
 \ /
  Last update: 2014-11-14 01:01    [W:0.610 / U:0.316 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site