From: jeff.chen_1@oss.nxp.com
To: techyminati <sinha.aryan03@gmail.com>
Cc: Jeff Chen <jeff.chen_1@oss.nxp.com>,
Jeff Chen <jeff.chen_1@nxp.com>,
Johannes Berg <johannes@sipsolutions.net>,
Francesco Dolcini <francesco@dolcini.it>,
linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH wireless] wifi: nxpwifi: fix NULL deref and leak in authenticate
Date: Tue, 6 Oct 2026 00:31:17 +0800 [thread overview]
Message-ID: <20261005163117.2883960-1-jeff.chen_1@oss.nxp.com> (raw)
In-Reply-To: <20261001161730.49134-1-techyminati@outlook.com>
From: Jeff Chen <jeff.chen_1@oss.nxp.com>
On Thu, Oct 01, 2026 at 09:47:13 PM +0530, techyminati wrote:
> From: Aryan Sinha <sinha.aryan03@gmail.com>
>
> diff --git a/drivers/net/wireless/nxp/nxpwifi/cfg80211.c b/drivers/net/wireless/nxp/nxpwifi/cfg80211.c
> index 86304ea33..9eb809caa 100644
> --- a/drivers/net/wireless/nxp/nxpwifi/cfg80211.c
> +++ b/drivers/net/wireless/nxp/nxpwifi/cfg80211.c
> @@ -3403,6 +3403,8 @@ nxpwifi_cfg80211_authenticate(struct wiphy *wiphy,
> pkt_len -= 4;
>
> mgmt = kzalloc(pkt_len, GFP_KERNEL);
> + if (!mgmt)
> + return -ENOMEM;
>
> skb = dev_alloc_skb(NXPWIFI_MIN_DATA_HEADER_LEN +
> NXPWIFI_MGMT_FRAME_HEADER_SIZE +
> @@ -3410,6 +3412,7 @@ nxpwifi_cfg80211_authenticate(struct wiphy *wiphy,
> if (!skb) {
> nxpwifi_dbg(adapter, ERROR,
> "allocate skb failed for management frame\n");
> + kfree(mgmt);
> return -ENOMEM;
> }
>
Hi Aryan,
Thanks for the patch.
This issue has already been addressed by another accepted patch:
https://patchwork.kernel.org/project/linux-wireless/patch/20260820081634.4043666-3-lilinmao@kylinos.cn/
Thanks,
Jeff
prev parent reply other threads:[~2026-10-05 16:32 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-01 16:17 [PATCH wireless] wifi: nxpwifi: fix NULL deref and leak in authenticate techyminati
2026-10-05 16:31 ` jeff.chen_1 [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=20261005163117.2883960-1-jeff.chen_1@oss.nxp.com \
--to=jeff.chen_1@oss.nxp.com \
--cc=francesco@dolcini.it \
--cc=jeff.chen_1@nxp.com \
--cc=johannes@sipsolutions.net \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=sinha.aryan03@gmail.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