From: Miroslav Benes <mbenes@suse.cz>
To: Yafang Shao <laoar.shao@gmail.com>
Cc: jpoimboe@kernel.org, jikos@kernel.org, pmladek@suse.com,
joe.lawrence@redhat.com, song@kernel.org,
live-patching@vger.kernel.org,
sashiko-bot <sashiko-bot@kernel.org>
Subject: Re: [PATCH] livepatch: Fix NULL pointer dereference in klp_find_func()
Date: Thu, 25 Jun 2026 15:24:49 +0200 (CEST) [thread overview]
Message-ID: <alpine.LSU.2.21.2606251523310.18862@pobox.suse.cz> (raw)
In-Reply-To: <20260623091638.76648-1-laoar.shao@gmail.com>
On Tue, 23 Jun 2026, Yafang Shao wrote:
> A NULL old_name in a newly loaded livepatch's function entry causes a
> NULL pointer dereference in strcmp():
>
> klp_init_patch()
> klp_add_nops()
> klp_find_func()
> strcmp(old_func->old_name, func->old_name)
>
> Add a sanity check at the beginning of klp_enable_patch() to reject
> patches with NULL old_name before they reach this code path.
The changelog could also mention the introduction of klp_check_patch().
Acked-by: Miroslav Benes <mbenes@suse.cz>
M
next prev parent reply other threads:[~2026-06-25 13:24 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-23 9:16 [PATCH] livepatch: Fix NULL pointer dereference in klp_find_func() Yafang Shao
2026-06-25 13:24 ` Miroslav Benes [this message]
2026-06-28 11:46 ` [PATCH v2] " Yafang Shao
2026-06-30 15:50 ` Petr Mladek
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=alpine.LSU.2.21.2606251523310.18862@pobox.suse.cz \
--to=mbenes@suse.cz \
--cc=jikos@kernel.org \
--cc=joe.lawrence@redhat.com \
--cc=jpoimboe@kernel.org \
--cc=laoar.shao@gmail.com \
--cc=live-patching@vger.kernel.org \
--cc=pmladek@suse.com \
--cc=sashiko-bot@kernel.org \
--cc=song@kernel.org \
/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