mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: Gavrilov Ilia <Ilia.Gavrilov@infotecs.ru>
Cc: Julan Hsu <julanhsu@google.com>,
	"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"lvc-project@linuxtesting.org" <lvc-project@linuxtesting.org>,
	"stable@vger.kernel.org" <stable@vger.kernel.org>
Subject: Re: [PATCH] wifi: mac80211: fix interger overflow in hwmp_route_info_get()
Date: Mon, 13 Jan 2025 16:05:27 +0100	[thread overview]
Message-ID: <a6bd38c58f2f7685eac53844f2336432503c328e.camel@sipsolutions.net> (raw)
In-Reply-To: <20241226074737.3737062-1-Ilia.Gavrilov@infotecs.ru>

On Thu, 2024-12-26 at 07:47 +0000, Gavrilov Ilia wrote:
> Since the new_metric and last_hop_metric variables can reach
> the MAX_METRIC(0xffffffff) value, an integer overflow may occur
> when multiplying them by 10/9. It can lead to incorrect behavior.
> 
> Found by InfoTeCS on behalf of Linux Verification Center
> (linuxtesting.org) with SVACE.
> 
> -					      mult_frac(new_metric, 10, 9) :
> +					      mult_frac((u64)new_metric, 10, 9) :
> 

As you would expect, this doesn't build on 32-bit.

johannnes

      reply	other threads:[~2025-01-13 15:05 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-26  7:47 Gavrilov Ilia
2025-01-13 15:05 ` Johannes Berg [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=a6bd38c58f2f7685eac53844f2336432503c328e.camel@sipsolutions.net \
    --to=johannes@sipsolutions.net \
    --cc=Ilia.Gavrilov@infotecs.ru \
    --cc=julanhsu@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=lvc-project@linuxtesting.org \
    --cc=stable@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

all inboxes | Powered by JetHome®