From: Florian Westphal <fw@strlen.de>
To: wkx <13514081436@163.com>
Cc: davem@davemloft.net, edumazet@google.com, kuba@kernel.org,
pabeni@redhat.com, netdev@vger.kernel.org,
21210240012@m.fudan.edu.cn
Subject: Re: [BUG net] possible use after free bugs due to race condition
Date: Mon, 12 Aug 2024 21:00:57 +0200 [thread overview]
Message-ID: <20240812190057.GB21559@breakpoint.cc> (raw)
In-Reply-To: <49ee57f2.9a9d.191465ab362.Coremail.13514081436@163.com>
wkx <13514081436@163.com> wrote:
>
>
> Our team recently developed a vulnerability detection tool, and we have employed it to scan the Linux Kernel (version 6.9.6). After manual review, we found some potentially vulnerable code snippets, which may have use-after-free bugs due to race conditions. Therefore, we would appreciate your expert insight to confirm whether these vulnerabilities could indeed pose a risk to the system.
>
> 1. /drivers/net/ethernet/broadcom/bcm63xx_enet.c
>
> In bcm_enet_probe, &priv->mib_update_task is bounded with bcm_enet_update_mib_counters_defer. bcm_enet_isr_mac will be called to start the work.
> If we remove the driver which will call bcm_enet_remove to make a cleanup, there may be unfinished work.
> The possible sequence is as follows:
> CPU0 CPU1
>
> | bcm_enet_update_mib_counters_defer
> bcm_enet_remove |
unregister_netdev(dev);
... which should end up calling bcm_enet_stop() (via ops->ndo_stop in
__dev_close_many()). This calls cancel_work_sync().
Did not look at the others.
next prev parent reply other threads:[~2024-08-12 19:01 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-12 11:30 [BUG net] possible use after free bugs due to race condition wkx
2024-08-12 19:00 ` Florian Westphal [this message]
2024-08-15 12:33 ` wkx
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=20240812190057.GB21559@breakpoint.cc \
--to=fw@strlen.de \
--cc=13514081436@163.com \
--cc=21210240012@m.fudan.edu.cn \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.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).