mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: Pengpeng Hou <pengpeng@iscas.ac.cn>
Cc: Bryam Vargas <hexlabsecurity@proton.me>,
	linux-input@vger.kernel.org,  linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] Input: iforce - validate input packet lengths
Date: Fri, 24 Jul 2026 20:56:02 -0700	[thread overview]
Message-ID: <amQzyVU2CExWfnm5@google.com> (raw)
In-Reply-To: <20260720115018.75045-1-pengpeng@iscas.ac.cn>

On Mon, Jul 20, 2026 at 07:50:18PM +0800, Pengpeng Hou wrote:
> iforce_process_packet() reads fixed fields from joystick, wheel and status
> packets without first checking their lengths. In particular, the shared
> hats-and-buttons helper unconditionally reads data[6]. The status tail is
> a sequence of 16-bit effect addresses, but an incomplete final address is
> also consumed. A successful zero-length USB URB additionally reads the
> packet ID before the common parser is called.
> 
> Reject the zero-length USB transfer, require the seven-byte joystick and
> wheel prefixes and the two-byte status prefix, and consume only complete
> status-tail addresses.
> 
> Signed-off-by: Pengpeng Hou <pengpeng@iscas.ac.cn>

Applied, thank you.

-- 
Dmitry

      reply	other threads:[~2026-07-25  3:56 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-20 11:50 Pengpeng Hou
2026-07-25  3:56 ` Dmitry Torokhov [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=amQzyVU2CExWfnm5@google.com \
    --to=dmitry.torokhov@gmail.com \
    --cc=hexlabsecurity@proton.me \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pengpeng@iscas.ac.cn \
    /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®