From: Simon Horman <simon.horman@corigine.com>
To: Sungwoo Kim <iam@sung-woo.kim>
Cc: wuruoyu@me.com, benquike@gmail.com, daveti@purdue.edu,
Marcel Holtmann <marcel@holtmann.org>,
Johan Hedberg <johan.hedberg@gmail.com>,
Luiz Augusto von Dentz <luiz.dentz@gmail.com>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
linux-bluetooth@vger.kernel.org, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Bluetooth: HCI: Fix global-out-of-bounds
Date: Tue, 21 Mar 2023 12:51:16 +0100 [thread overview]
Message-ID: <ZBmaNIij3IRXRwaT@corigine.com> (raw)
In-Reply-To: <20230321015018.1759683-1-iam@sung-woo.kim>
On Mon, Mar 20, 2023 at 09:50:18PM -0400, Sungwoo Kim wrote:
> To loop a variable-length array, hci_init_stage_sync(stage) considers
> that stage[i] is valid as long as stage[i-1].func is valid.
> Thus, the last element of stage[].func should be intentionally invalid
> as hci_init0[], le_init2[], and others did.
> However, amp_init1[] and amp_init2[] have no invalid element, letting
> hci_init_stage_sync() keep accessing amp_init1[] over its valid range.
> This patch fixes this by adding {} in the last of amp_init1[] and
> amp_init2[].
...
> This bug is found by FuzzBT, a modified version of Syzkaller.
> Other contributors for this bug are Ruoyu Wu and Peng Hui.
>
> Fixes: d0b137062b2d ("Bluetooth: hci_sync: Rework init stages")
> Signed-off-by: Sungwoo Kim <iam@sung-woo.kim>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
...
next prev parent reply other threads:[~2023-03-21 11:51 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-21 1:50 [PATCH] Bluetooth: HCI: Fix global-out-of-bounds Sungwoo Kim
2023-03-21 11:51 ` Simon Horman [this message]
2023-03-22 23:00 ` patchwork-bot+bluetooth
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=ZBmaNIij3IRXRwaT@corigine.com \
--to=simon.horman@corigine.com \
--cc=benquike@gmail.com \
--cc=davem@davemloft.net \
--cc=daveti@purdue.edu \
--cc=edumazet@google.com \
--cc=iam@sung-woo.kim \
--cc=johan.hedberg@gmail.com \
--cc=kuba@kernel.org \
--cc=linux-bluetooth@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=luiz.dentz@gmail.com \
--cc=marcel@holtmann.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=wuruoyu@me.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;
as well as URLs for NNTP newsgroup(s).