From: David Marchand <david.marchand@redhat.com>
To: Owen Hilyard <ohilyard@iol.unh.edu>,
Vladimir Medvedkin <vladimir.medvedkin@intel.com>
Cc: dev <dev@dpdk.org>, Stephen Hemminger <stephen@networkplumber.org>
Subject: Re: [dpdk-dev] [PATCH v3] lib/rte_rib6: fix stack buffer overflow
Date: Tue, 22 Jun 2021 09:10:37 +0200 [thread overview]
Message-ID: <CAJFAV8ycf651T_AV3BjQ2BOWGHa77hbo2-ENof+gwpymeHEfQw@mail.gmail.com> (raw)
In-Reply-To: <20210621132834.21673-1-ohilyard@iol.unh.edu>
On Mon, Jun 21, 2021 at 3:28 PM <ohilyard@iol.unh.edu> wrote:
>
> From: Owen Hilyard <ohilyard@iol.unh.edu>
Hi Owen, Vladimir,
Owen, two comments on the patch title.
- We (try to) never prefix with lib/, as it gives no additional info.
The prefix should be the library name.
There were some transgressions to this rule, but this was Thomas or me
being absent minded.
For other parts of the tree, it is a bit more complex, but if unsure,
the simplest is to look at the git history.
Here this is the rib library, so "rib: " is enough.
- The title purpose is to give a hint of the functional impact: people
looking for fixes for a type of bug can find it more easily.
Here, just indicating we are fixing a buffer overflow won't help judge
in which usecase the issue happenned.
How about: "rib: fix max depth IPv6 lookup"
>
> ASAN found a stack buffer overflow in lib/rib/rte_rib6.c:get_dir.
> The fix for the stack buffer overflow was to make sure depth
> was always < 128, since when depth = 128 it caused the index
> into the ip address to be 16, which read off the end of the array.
>
> While trying to solve the buffer overflow, I noticed that a few
> changes could be made to remove the for loop entirely.
>
> Fixes: f7e861e21c ("rib: support IPv6")
Cc: stable@dpdk.org
>
> Signed-off-by: Owen Hilyard <ohilyard@iol.unh.edu>
Vladimir, can you review this fix?
Thanks!
--
David Marchand
next prev parent reply other threads:[~2021-06-22 7:10 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-16 16:07 [dpdk-dev] [PATCH] " ohilyard
2021-06-16 16:56 ` Stephen Hemminger
2021-06-16 17:27 ` Medvedkin, Vladimir
2021-06-16 18:18 ` [dpdk-dev] [PATCH v2] " ohilyard
2021-06-18 16:22 ` Medvedkin, Vladimir
2021-06-18 16:27 ` Medvedkin, Vladimir
2021-06-21 13:28 ` [dpdk-dev] [PATCH v3] " ohilyard
2021-06-22 7:10 ` David Marchand [this message]
2021-06-22 10:51 ` Medvedkin, Vladimir
2021-06-23 15:17 ` [dpdk-dev] [PATCH v4] rib: fix max depth IPv6 lookup ohilyard
2021-06-24 13:23 ` David Marchand
2021-06-24 9:01 ` [dpdk-dev] [PATCH v3] lib/rte_rib6: fix stack buffer overflow Medvedkin, Vladimir
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=CAJFAV8ycf651T_AV3BjQ2BOWGHa77hbo2-ENof+gwpymeHEfQw@mail.gmail.com \
--to=david.marchand@redhat.com \
--cc=dev@dpdk.org \
--cc=ohilyard@iol.unh.edu \
--cc=stephen@networkplumber.org \
--cc=vladimir.medvedkin@intel.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).