kernel-hardening.lists.openwall.com archive mirror
 help / color / mirror / Atom feed
From: Solar Designer <solar@openwall.com>
To: Daniel Axtens <dja@axtens.net>
Cc: Jann Horn <jann@thejh.net>,
	kernel-hardening@lists.openwall.com,
	linux-kernel@vger.kernel.org,
	Andrew Morton <akpm@linux-foundation.org>,
	HATAYAMA Daisuke <d.hatayama@jp.fujitsu.com>,
	Vitaly Kuznetsov <vkuznets@redhat.com>,
	Baoquan He <bhe@redhat.com>,
	Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Subject: [kernel-hardening] Re: [RFC] kernel/panic: place an upper limit on number of oopses
Date: Wed, 13 Jan 2016 03:20:43 +0300	[thread overview]
Message-ID: <20160113002043.GA17146@openwall.com> (raw)
In-Reply-To: <87mvsa5q40.fsf@gamma.ozlabs.ibm.com>

Jann Horn <jann@thejh.net> wrote:
> To prevent an attacker from turning a mostly harmless oops into an
> exploitable issue using a refcounter wraparound caused by repeated
> oopsing, limit the number of oopses.

This may also reduce the likelihood of successful exploitation of some
other vulnerabilities involving memory corruption, where an unsuccessful
attempt may inadvertently trigger an Oops.  The attacker would then need
to succeed in fewer than the maximum allowed number of Oops'es.  Jann's
currently proposed default of 0x100000 is too high to make a difference
in that respect, but people may set it differently.

On Wed, Jan 13, 2016 at 10:34:39AM +1100, Daniel Axtens wrote:
> I'm torn between making the limit configurable and not adding to the
> massive proliferation of config options.

What about reusing panic_on_oops for the configurable limit?  The
currently supported values of 0 and 1 would retain their meaning,
2 would panic after 2nd Oops, and so on.

There's overlap with grsecurity's banning of users on Oops, but I think
it makes sense to have both the trivial change proposed by Jann (perhaps
with the reuse of panic_on_oops for configuration) and grsecurity-style
banning (maybe with a low configurable limit, rather than always on
first Oops).

Alexander

  parent reply	other threads:[~2016-01-13  0:20 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-12 19:25 [kernel-hardening] [RFC] kernel/panic: place an upper limit on number of oopses Jann Horn
2016-01-12 23:34 ` [kernel-hardening] " Daniel Axtens
2016-01-12 23:51   ` Jann Horn
2016-01-13  0:20   ` Solar Designer [this message]
2016-01-13  0:33     ` Daniel Axtens
2016-01-13 18:08     ` Jann Horn
2016-01-17  3:58       ` Jann Horn

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160113002043.GA17146@openwall.com \
    --to=solar@openwall.com \
    --cc=akpm@linux-foundation.org \
    --cc=bhe@redhat.com \
    --cc=d.hatayama@jp.fujitsu.com \
    --cc=dja@axtens.net \
    --cc=jann@thejh.net \
    --cc=kernel-hardening@lists.openwall.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=masami.hiramatsu.pt@hitachi.com \
    --cc=vkuznets@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).