[lkml]   [2017]   [Nov]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [RFC PATCH] fw_lockdown: new micro LSM module to prevent loading unsigned firmware
On Fri, 2017-11-10 at 20:35 +0100, Luis R. Rodriguez wrote:
> On Fri, Nov 10, 2017 at 12:58:23PM -0500, Mimi Zohar wrote:
> > Hi David,
> >
> > If you are interested in preventing the loading of unsigned firmware,
> > the patch below is straight forward.  The patch has ONLY been tested
> > with IMA-appraisal enabled, and works as intended - allowing only
> > signed firmware to be loaded.
> Very nice! This is the sort of thing that I mean by LSM'ifying fw access
> through a system policy.
> We currently handle the LSM aspect for firmware through
> kernel_read_file_from_path() and so the kernel_read_file LSM hook, so why a new
> hook here?

kernel_read_file(), itself, is not an LSM hook, but calls two LSM
hooks named security_kernel_read_file(), prior to reading a file, and
security_kernel_post_read_file(), post reading a file.

In this case, we want to reject even reading the file if it isn't
signed, so we're using the security_kernel_read_file() LSM hook.

> Where does this plug in?

This is a standalone, micro LSM that can be configured at build.  For
now I left it is an optional Kconfig parameter, but at some point, you
might want to consider making it required.


 \ /
  Last update: 2017-11-10 20:51    [W:0.050 / U:8.308 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site