The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Petr Mladek <pmladek@suse.com>
To: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
	linux-kernel@vger.kernel.org, linux-hardening@vger.kernel.org,
	Andrew Morton <akpm@linux-foundation.org>,
	Kees Cook <kees@kernel.org>,
	Rasmus Villemoes <linux@rasmusvillemoes.dk>,
	Sergey Senozhatsky <senozhatsky@chromium.org>,
	Steven Rostedt <rostedt@goodmis.org>,
	Tycho Andersen <tycho@tycho.pizza>
Subject: Re: [PATCH 1/2] vsprintf: Don't leak pointers for %ps without KALLSYMS enabled
Date: Thu, 20 Aug 2026 17:40:57 +0200	[thread overview]
Message-ID: <aocgCfQoKIVbaU4k@pathway.suse.cz> (raw)
In-Reply-To: <20260820142426.Q3y-RHVx@linutronix.de>

On Thu 2026-08-20 16:24:26, Sebastian Andrzej Siewior wrote:
> On 2026-08-15 11:58:03 [+0300], Andy Shevchenko wrote:
> > On Fri, Aug 14, 2026 at 04:48:53PM +0200, Sebastian Andrzej Siewior wrote:
> > > The "%ps" format modifier prints the name of the symbol which is more
> > > valuable in terms of debugging and does not leak the actual pointer.
> > > 
> > > Without KALLSYMS it will leak the pointer which is not intended. The
> > > default policy for pointers is to print a hashed value and not to leak
> > > the actual pointer.
> > > 
> > > Print "(unknown)" for any symbol resolution witout KALLSYMS enabled.
> > 
> > Hmm... I would expect some test cases to be added/modified.
> 
> No bot complained so far, so maybe not ;)

It seems that we really do not have test cases for this. I guess
that it is because it is so tricky with the various fallbacks, ...

The existing test cases for %p are tricky as well. As a result
they are an infinite source of problems ;-)

Best Regards,
Petr

  reply	other threads:[~2026-08-20 15:41 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-14 14:48 [PATCH 0/2] vsprintf: Don't leak pointers Sebastian Andrzej Siewior
2026-08-14 14:48 ` [PATCH 1/2] vsprintf: Don't leak pointers for %ps without KALLSYMS enabled Sebastian Andrzej Siewior
2026-08-15  8:58   ` Andy Shevchenko
2026-08-20 14:24     ` Sebastian Andrzej Siewior
2026-08-20 15:40       ` Petr Mladek [this message]
2026-08-14 14:48 ` [PATCH 2/2] kallsyms: Don't leak pointers for unresolved symbols Sebastian Andrzej Siewior
2026-08-14 19:08   ` Bradley Morgan
2026-08-14 19:56 ` [PATCH 0/2] vsprintf: Don't leak pointers Andrew Morton
2026-08-20 15:28   ` Petr Mladek
2026-08-20 15:35     ` Sebastian Andrzej Siewior

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=aocgCfQoKIVbaU4k@pathway.suse.cz \
    --to=pmladek@suse.com \
    --cc=akpm@linux-foundation.org \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=bigeasy@linutronix.de \
    --cc=kees@kernel.org \
    --cc=linux-hardening@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@rasmusvillemoes.dk \
    --cc=rostedt@goodmis.org \
    --cc=senozhatsky@chromium.org \
    --cc=tycho@tycho.pizza \
    /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