From: Adrien Schildknecht <adrien+dev@schischi.me>
To: "Grumbach, Emmanuel" <emmanuel.grumbach@intel.com>
Cc: "Berg, Johannes" <johannes.berg@intel.com>,
"ilw@linux.intel.com" <ilw@linux.intel.com>,
"kvalo@codeaurora.org" <kvalo@codeaurora.org>,
"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>,
"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] iwlwifi: out-of-bounds access in iwl_init_sband_channels
Date: Fri, 14 Aug 2015 09:04:08 +0200 [thread overview]
Message-ID: <20150814090408.1521e8fe.adrien+dev@schischi.me> (raw)
In-Reply-To: <0BA3FCBA62E2DC44AF3030971E174FB32E7EA2CE@hasmsx107.ger.corp.intel.com>
Hi,
> On 08/14/2015 03:36 AM, Adrien Schildknecht wrote:
> > Both loops of this function compare data from the 'chan' array and
> > then check if the index is valid.
> >
> > The 2 conditions should be inverted to avoid an out-of-bounds
> > access.
> >
>
> Was that found by a static analyzer or any other automated tool, or
> was that the result of your very careful review?
The error has been reported by KASan:
==================================================================
BUG: KASan: out of bounds access in iwl_init_sband_channels+0x207/0x260 [iwlwifi] at addr ffff8800c2d0aac8
Read of size 4 by task modprobe/329
==================================================================
--
Adrien Schildknecht
next prev parent reply other threads:[~2015-08-14 7:04 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-08-14 0:35 [PATCH] iwlwifi: out-of-bounds access in iwl_init_sband_channels Adrien Schildknecht
2015-08-14 4:31 ` Grumbach, Emmanuel
2015-08-14 7:04 ` Adrien Schildknecht [this message]
2015-08-14 7:14 ` Kalle Valo
2015-08-14 9:05 ` [PATCH v2] " Adrien Schildknecht
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=20150814090408.1521e8fe.adrien+dev@schischi.me \
--to=adrien+dev@schischi.me \
--cc=emmanuel.grumbach@intel.com \
--cc=ilw@linux.intel.com \
--cc=johannes.berg@intel.com \
--cc=kvalo@codeaurora.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=netdev@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;
as well as URLs for NNTP newsgroup(s).