lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 13 May 2020 09:34:49 +0200
From:   Petr Mladek <pmladek@...e.com>
To:     Kees Cook <keescook@...omium.org>
Cc:     Pavel Tatashin <pasha.tatashin@...een.com>,
        Anton Vorontsov <anton@...msg.org>,
        Colin Cross <ccross@...roid.com>,
        Tony Luck <tony.luck@...el.com>,
        Jonathan Corbet <corbet@....net>,
        Rob Herring <robh+dt@...nel.org>,
        Benson Leung <bleung@...omium.org>,
        Enric Balletbo i Serra <enric.balletbo@...labora.com>,
        Sergey Senozhatsky <sergey.senozhatsky@...il.com>,
        Steven Rostedt <rostedt@...dmis.org>,
        James Morris <jmorris@...ei.org>,
        Sasha Levin <sashal@...nel.org>,
        Linux Doc Mailing List <linux-doc@...r.kernel.org>,
        LKML <linux-kernel@...r.kernel.org>, devicetree@...r.kernel.org
Subject: Re: [PATCH v3 0/6] allow ramoops to collect all kmesg_dump events

On Tue 2020-05-12 11:45:54, Kees Cook wrote:
> Here are the problems I see being solved by this:
> 
> - lifting kmsg dump reason filtering out of the individual pstore
>   backends and making it part of the "infrastructure", so that
>   there is a central place to set expectations. Right now there
>   is a mix of explicit and implicit kmsg dump handling:
> 
>   - arch/powerpc/kernel/nvram_64.c has a hard-coded list

It handles restart, halt, poweroff the same way.  I wonder if anyone
would want to distinguish them.

>   - drivers/firmware/efi/efi-pstore.c doesn't expect anything but
>     OOPS and PANIC.
>   - drivers/mtd/mtdoops.c tries to filter using its own dump_oops
>     and doesn't expect anything but OOPS and PANIC.
>   - fs/pstore/ram.c: has a hard-coded list and uses its own
>     dump_oops.
>   - drivers/mtd/mtdpstore.c (under development[3]) expected only
>     OOPS and PANIC and had its own dump_oops.

The others handle only panic or oops.

What about splitting the reason into two variables? One for severity
and other for shutdown behavior. I mean:

  + reason: panic, oops, emergency, shutdown    (ordered by severity)
  + handling: restart, halt, poweroff

Or we might just replace KMSG_DUMP_RESTART, KMSG_DUMP_HALT,
KMSG_DUMP_POWEROFF with a single KMSG_DUMP_SHUTDOWN.

Then the max reason variable would make sense.

Best Regards,
Petr

Powered by blists - more mailing lists