From: Sven Peter <sven@svenpeter.dev>
To: Alyssa Rosenzweig <alyssa@rosenzweig.io>,
Janne Grunau <j@jannau.net>, Asahi Lina <lina@asahilina.net>,
Jens Axboe <axboe@kernel.dk>,
asahi@lists.linux.dev, linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org,
Harshit Mogalapalli <harshit.m.mogalapalli@oracle.com>
Cc: Sven Peter <sven@svenpeter.dev>,
dan.carpenter@linaro.org, kernel-janitors@vger.kernel.org,
error27@gmail.com
Subject: Re: [PATCH] soc: apple: rtkit: Fix use-after-free in apple_rtkit_crashlog_rx()
Date: Tue, 18 Feb 2025 18:05:27 +0100 [thread overview]
Message-ID: <173989828130.49947.10388452698510580758.b4-ty@svenpeter.dev> (raw)
In-Reply-To: <20250212085853.1357906-1-harshit.m.mogalapalli@oracle.com>
On Wed, 12 Feb 2025 00:58:53 -0800, Harshit Mogalapalli wrote:
> This code calls kfree(bfr); and then passes "bfr" to rtk->ops->crashed()
> which is a use after free. The ->crashed function pointer is implemented
> by apple_nvme_rtkit_crashed() and it doesn't use the "bfr" pointer so
> this doesn't cause a problem. But it still looks sketchy as can be.
>
> Fix this by moving kfree() after the last usage of bfr.
>
> [...]
Applied, thanks!
[1/1] soc: apple: rtkit: Fix use-after-free in apple_rtkit_crashlog_rx()
commit: 00834971f0d9e38beae37e92055b1432782827d0
Best regards,
--
Sven Peter <sven@svenpeter.dev>
prev parent reply other threads:[~2025-02-18 17:05 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-12 8:58 Harshit Mogalapalli
2025-02-12 10:00 ` Eric Curtin
2025-02-18 15:34 ` Sven Peter
2025-02-18 16:01 ` Harshit Mogalapalli
2025-02-18 17:02 ` Sven Peter
2025-02-18 17:05 ` Sven Peter [this message]
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=173989828130.49947.10388452698510580758.b4-ty@svenpeter.dev \
--to=sven@svenpeter.dev \
--cc=alyssa@rosenzweig.io \
--cc=asahi@lists.linux.dev \
--cc=axboe@kernel.dk \
--cc=dan.carpenter@linaro.org \
--cc=error27@gmail.com \
--cc=harshit.m.mogalapalli@oracle.com \
--cc=j@jannau.net \
--cc=kernel-janitors@vger.kernel.org \
--cc=lina@asahilina.net \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.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
all inboxes | Powered by JetHome®