lkml.org 
[lkml]   [2016]   [Oct]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [kernel-hardening] [RFC] module: add 'module_ronx=off' boot cmdline parameter to disable ro/nx module mappings
Hi,

On Tue, Oct 18, 2016 at 03:09:51PM +0900, AKASHI Takahiro wrote:
> As making CONFIG_DEBUG_RODATA mandatory is a good idea, so will be
> for CONFIG_SET_MODULE_RONX.

I completely agree, given most distros ship a large number of drivers as
modules...

> This patch adds a command line parameter, "module_ronx=," in order to
> make this configuration always on in the future, but still allowing for
> disabling read-only module mappings at boot time as "rodata=" does.
>
> I have, however, some concerns on this prototype:
> (1) should we use a separate parameter like "module_ronx=," or
> unify it with "rodata="?

I think this should be merged with "rodata=".

> (2) should we keep NX permission set even if module_ronx=off?

I think we should; for arm64 we set NX for kernel mappings even with
rodata=off, and I think we should be consistent.

Thanks,
Mark.

\
 
 \ /
  Last update: 2016-10-18 15:36    [W:0.047 / U:0.572 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site