From: Jens Axboe <axboe@kernel.dk>
To: clingfei <clf700383@gmail.com>
Cc: io-uring@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] io_uring: gate personality per opcode to fix TOCTOU check in io_msg_ring_prep
Date: Sun, 25 Jan 2026 07:16:43 -0700 [thread overview]
Message-ID: <cea5285e-061b-4e5e-8c06-82461e8eeb62@kernel.dk> (raw)
In-Reply-To: <20260125075302.621785-1-1599101385@qq.com>
On 1/25/26 12:53 AM, clingfei wrote:
> From: Cheng Lingfei <clf700383@gmail.com>
>
> Add allow_personality io_issue_def and reject personality use in
> io_init_req for opcodes that do not permit it. This fixes a TOCTOU
> window in the prior implementation: userspace could race-update
> sqe->personality and bypass the __io_msg_ring_prep personality check.
Please do detail what the bug is here, this looks like some kind of
AI hallucination. The check in msg_ring prep exists just to reject
commands with it set, for future expansion. The only thing that
matters is the ordering and use in io_init_req(), which is fine.
--
Jens Axboe
next prev parent reply other threads:[~2026-01-25 14:16 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-25 7:53 [PATCH] io_uring: gate personality per opcode to fix TOCTOU check in io_msg_ring_prep clingfei
2026-01-25 14:16 ` Jens Axboe [this message]
2026-01-26 1:57 ` clingfei
2026-01-26 12:36 ` Jens Axboe
2026-01-27 2:24 ` clingfei
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=cea5285e-061b-4e5e-8c06-82461e8eeb62@kernel.dk \
--to=axboe@kernel.dk \
--cc=clf700383@gmail.com \
--cc=io-uring@vger.kernel.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