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  linux-cve-announce  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]
Message-ID: <5f3e1c5e-9456-4aa4-ae0b-6353357045d7@paulmck-laptop>
Date:   Sat, 29 Jul 2023 08:41:46 -0700
From:   "Paul E. McKenney" <paulmck@...nel.org>
To:     Masami Hiramatsu <mhiramat@...nel.org>
Cc:     akpm@...ux-foundation.org, adobriyan@...il.com, arnd@...nel.org,
        ndesaulniers@...gle.com, sfr@...b.auug.org.au,
        linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org,
        kernel-team@...a.com
Subject: Re: [PATCH RFC bootconfig] 2/2] fs/proc: Add /proc/cmdline_image for
 embedded arguments

On Sat, Jul 29, 2023 at 11:23:46PM +0900, Masami Hiramatsu wrote:
> Hi Paul,
> 
> On Thu, 27 Jul 2023 20:37:01 -0700
> "Paul E. McKenney" <paulmck@...nel.org> wrote:
> 
> > In kernels built with CONFIG_BOOT_CONFIG_FORCE=y, /proc/cmdline will show
> > all kernel boot parameters, both those supplied by the boot loader and
> > those embedded in the kernel image.  This works well for those who just
> > want to see all of the kernel boot parameters, but is not helpful to those
> > who need to see only those parameters that were embedded into the kernel
> > image.  This is especially important in situations where there are many
> > kernel images for different kernel versions and kernel configurations,
> > all of which opens the door to a great deal of human error.
> 
> There is /proc/bootconfig file which shows all bootconfig entries and is
> formatted as easily filter by grep (or any other line-based commands).
> (e.g. `grep ^kernel\\. /proc/cmdline` will filter all kernel cmdline
> parameters in the bootconfig)
> Could you clarify the reason why you need a dump of bootconfig file?

Because I was unaware of /proc/bootconfig?  ;-)

So how about if I replace this patch of mine with the following?

And thank you for pointing me at /proc/bootconfig.

							Thanx, Paul

------------------------------------------------------------------------

diff --git a/Documentation/filesystems/proc.rst b/Documentation/filesystems/proc.rst
index 98c43c5ef1ee..832d66d4e396 100644
--- a/Documentation/filesystems/proc.rst
+++ b/Documentation/filesystems/proc.rst
@@ -684,6 +684,7 @@ files are there, and which are missing.
  File         Content
  ============ ===============================================================
  apm          Advanced power management info
+ bootconfig   Kernel command line obtained from boot config	(5.5)
  buddyinfo    Kernel memory allocator information (see text)	(2.5)
  bus          Directory containing bus specific information
  cmdline      Kernel command line, both from bootloader and embedded

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ