Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1496693

RE: [PATCH] printk: introduce kptr_restrict level 3

From "Roberts, William C" <william.c.roberts@intel.com>
Newsgroups linux.kernel
Subject RE: [PATCH] printk: introduce kptr_restrict level 3
Date 2016-10-06 17:10 +0200
Message-ID <spit3-1Pe-9@gated-at.bofh.it> (permalink)
References <soYNI-4PT-13@gated-at.bofh.it> <sph3Y-GK-21@gated-at.bofh.it> <sphdE-Kt-19@gated-at.bofh.it> <sphnj-Oy-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw



> -----Original Message-----
> From: Christoph Hellwig [mailto:hch@infradead.org]
> Sent: Thursday, October 6, 2016 9:56 AM
> To: Roberts, William C <william.c.roberts@intel.com>
> Cc: Christoph Hellwig <hch@infradead.org>; kernel-
> hardening@lists.openwall.com; corbet@lwn.net; linux-doc@vger.kernel.org;
> linux-kernel@vger.kernel.org
> Subject: Re: [PATCH] printk: introduce kptr_restrict level 3
> 
> On Thu, Oct 06, 2016 at 01:47:47PM +0000, Roberts, William C wrote:
> > Out of tree modules still affect core kernel security.
> 
> So don't use them.
> 
> > I would also bet money, that somewhere In-tree someone has put a %p
> > when they wanted a %pK.
> 
> So fix them.

As Jann Horn points out, "And in total, there are 13578 matches for %p[^FfSsBRrhbMmIiEUVKNadCDgG] throughout the kernel. Reviewing all of those manually would suck."

> 
> > So this method is just quite error
> > prone. We currently have a blacklist approach versus whitelist.
> 
> Or fix the entire thing, get rid of %pK and always protect %p if you can show that
> it doesn't break anything.
> 
> But stop posting patches with bullshit arguments like out of tree modules.

Ok perhaps the commit message sucks, and I should have included the large spread usages of %p throughout
the kernel, I assumed those would just be known, I shouldn't have made that assumption.

We should care about out-of-tree modules wrt security as they affect the security of the whole system, especially when the
modules are linking to core symbols like printing and string routines. There are tons of %p usages throughout the
kernel as noted above.

This is pretty low hanging fruit and we should fix this, as Kees points out.

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH] printk: introduce kptr_restrict level 3 william.c.roberts@intel.com - 2016-10-05 20:10 +0200
  Re: [PATCH] printk: introduce kptr_restrict level 3 Kees Cook <keescook@chromium.org> - 2016-10-05 21:40 +0200
    RE: [PATCH] printk: introduce kptr_restrict level 3 "Roberts, William C" <william.c.roberts@intel.com> - 2016-10-06 15:20 +0200
  Re: [PATCH] printk: introduce kptr_restrict level 3 Rasmus Villemoes <linux@rasmusvillemoes.dk> - 2016-10-05 23:00 +0200
    RE: [PATCH] printk: introduce kptr_restrict level 3 "Roberts, William C" <william.c.roberts@intel.com> - 2016-10-06 15:30 +0200
  Re: [PATCH] printk: introduce kptr_restrict level 3 Christoph Hellwig <hch@infradead.org> - 2016-10-06 15:40 +0200
    RE: [PATCH] printk: introduce kptr_restrict level 3 "Roberts, William C" <william.c.roberts@intel.com> - 2016-10-06 15:50 +0200
      Re: [PATCH] printk: introduce kptr_restrict level 3 Christoph Hellwig <hch@infradead.org> - 2016-10-06 16:00 +0200
        RE: [PATCH] printk: introduce kptr_restrict level 3 "Roberts, William C" <william.c.roberts@intel.com> - 2016-10-06 17:10 +0200
        Re: [PATCH] printk: introduce kptr_restrict level 3 Kees Cook <keescook@chromium.org> - 2016-10-06 23:10 +0200
          Re: [PATCH] printk: introduce kptr_restrict level 3 Joe Perches <joe@perches.com> - 2016-10-06 23:30 +0200
            Re: [PATCH] printk: introduce kptr_restrict level 3 Kees Cook <keescook@chromium.org> - 2016-10-06 23:30 +0200
          RE: [PATCH] printk: introduce kptr_restrict level 3 "Roberts, William C" <william.c.roberts@intel.com> - 2016-10-07 16:30 +0200
      Re: [kernel-hardening] RE: [PATCH] printk: introduce kptr_restrict  level 3 Jann Horn <jann@thejh.net> - 2016-10-06 16:10 +0200
        Re: [kernel-hardening] RE: [PATCH] printk: introduce kptr_restrict  level 3 Jann Horn <jann@thejh.net> - 2016-10-06 16:50 +0200
        Re: [kernel-hardening] RE: [PATCH] printk: introduce kptr_restrict  level 3 Jann Horn <jann@thejh.net> - 2016-10-07 14:00 +0200

csiph-web