From: Vasanthakumar Thiagarajan <vasanth@atheros.com>
To: ath9k-devel@lists.ath9k.org
Subject: [ath9k-devel] [PATCH] ath9k: Prevent read buffer overflow
Date: Wed, 12 Aug 2009 17:28:05 +0530 [thread overview]
Message-ID: <20090812115803.GA4876@vasanth-laptop> (raw)
In-Reply-To: <4A81BB1E.6040904@gmail.com>
On Wed, Aug 12, 2009 at 12:10:30AM +0530, Roel Kluin wrote:
> Prevent a read from valid_rate_index[] with a negative index
>
> Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
> ---
> Maybe we should add this?
>
> diff --git a/drivers/net/wireless/ath/ath9k/rc.c b/drivers/net/wireless/ath/ath9k/rc.c
> index ba06e78..a67b7f6 100644
> --- a/drivers/net/wireless/ath/ath9k/rc.c
> +++ b/drivers/net/wireless/ath/ath9k/rc.c
> @@ -1458,7 +1458,7 @@ static void ath_rc_init(struct ath_softc *sc,
> ath_rc_priv->rate_max_phy = ath_rc_priv->valid_phy_rateidx[i][j-1];
> }
> ASSERT(ath_rc_priv->rate_table_size <= RATE_TABLE_SIZE);
> - ASSERT(k <= RATE_TABLE_SIZE);
> + ASSERT(k <= RATE_TABLE_SIZE && k >= 4);
NACK, k is initialized to 0 in the for loop few lines above this
ASSERT.
Vasanth
WARNING: multiple messages have this Message-ID (diff)
From: Vasanthakumar Thiagarajan <vasanth@atheros.com>
To: Roel Kluin <roel.kluin@gmail.com>
Cc: Luis Rodriguez <Luis.Rodriguez@Atheros.com>,
"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>,
"ath9k-devel@lists.ath9k.org" <ath9k-devel@lists.ath9k.org>,
Andrew Morton <akpm@linux-foundation.org>
Subject: Re: [PATCH] ath9k: Prevent read buffer overflow
Date: Wed, 12 Aug 2009 17:28:05 +0530 [thread overview]
Message-ID: <20090812115803.GA4876@vasanth-laptop> (raw)
In-Reply-To: <4A81BB1E.6040904@gmail.com>
On Wed, Aug 12, 2009 at 12:10:30AM +0530, Roel Kluin wrote:
> Prevent a read from valid_rate_index[] with a negative index
>
> Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
> ---
> Maybe we should add this?
>
> diff --git a/drivers/net/wireless/ath/ath9k/rc.c b/drivers/net/wireless/ath/ath9k/rc.c
> index ba06e78..a67b7f6 100644
> --- a/drivers/net/wireless/ath/ath9k/rc.c
> +++ b/drivers/net/wireless/ath/ath9k/rc.c
> @@ -1458,7 +1458,7 @@ static void ath_rc_init(struct ath_softc *sc,
> ath_rc_priv->rate_max_phy = ath_rc_priv->valid_phy_rateidx[i][j-1];
> }
> ASSERT(ath_rc_priv->rate_table_size <= RATE_TABLE_SIZE);
> - ASSERT(k <= RATE_TABLE_SIZE);
> + ASSERT(k <= RATE_TABLE_SIZE && k >= 4);
NACK, k is initialized to 0 in the for loop few lines above this
ASSERT.
Vasanth
next prev parent reply other threads:[~2009-08-12 11:58 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-08-11 18:40 [ath9k-devel] [PATCH] ath9k: Prevent read buffer overflow Roel Kluin
2009-08-11 18:40 ` Roel Kluin
2009-08-12 11:58 ` Vasanthakumar Thiagarajan [this message]
2009-08-12 11:58 ` Vasanthakumar Thiagarajan
2009-08-12 12:35 ` [ath9k-devel] " roel kluin
2009-08-12 12:35 ` roel kluin
2009-08-12 12:42 ` [ath9k-devel] " Vasanthakumar Thiagarajan
2009-08-12 12:42 ` Vasanthakumar Thiagarajan
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=20090812115803.GA4876@vasanth-laptop \
--to=vasanth@atheros.com \
--cc=ath9k-devel@lists.ath9k.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.