From: Benjamin Tissoires <bentiss@kernel.org>
To: Rishi Gupta <gupt21@gmail.com>, Arnaud Lecomte <contact@arnaud-lcm.com>
Cc: Jiri Kosina <jikos@kernel.org>,
linux-i2c@vger.kernel.org, linux-input@vger.kernel.org,
linux-kernel@vger.kernel.org,
syzbot+52c1a7d3e5b361ccd346@syzkaller.appspotmail.com
Subject: Re: [PATCH] hid: fix I2C read buffer overflow in raw_event() for mcp2221
Date: Wed, 13 Aug 2025 11:43:27 +0200 [thread overview]
Message-ID: <175507820752.20076.8458113244883958100.b4-ty@kernel.org> (raw)
In-Reply-To: <20250726220931.7126-1-contact@arnaud-lcm.com>
On Sat, 26 Jul 2025 23:09:31 +0100, Arnaud Lecomte wrote:
> As reported by syzbot, mcp2221_raw_event lacked
> validation of incoming I2C read data sizes, risking buffer
> overflows in mcp->rxbuf during multi-part transfers.
> As highlighted in the DS20005565B spec, p44, we have:
> "The number of read-back data bytes to follow in this packet:
> from 0 to a maximum of 60 bytes of read-back bytes."
> This patch enforces we don't exceed this limit.
>
> [...]
Applied to hid/hid.git (for-6.17/upstream-fixes), thanks!
[1/1] hid: fix I2C read buffer overflow in raw_event() for mcp2221
https://git.kernel.org/hid/hid/c/b56cc41a3ae7
Cheers,
--
Benjamin Tissoires <bentiss@kernel.org>
prev parent reply other threads:[~2025-08-13 9:43 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-26 22:09 [PATCH] hid: fix I2C read buffer overflow in raw_event() for mcp2221 Arnaud Lecomte
2025-08-05 21:07 ` Arnaud Lecomte
2025-08-13 9:43 ` Benjamin Tissoires [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=175507820752.20076.8458113244883958100.b4-ty@kernel.org \
--to=bentiss@kernel.org \
--cc=contact@arnaud-lcm.com \
--cc=gupt21@gmail.com \
--cc=jikos@kernel.org \
--cc=linux-i2c@vger.kernel.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=syzbot+52c1a7d3e5b361ccd346@syzkaller.appspotmail.com \
/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