From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 606D942049; Thu, 15 Jan 2026 16:54:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768496063; cv=none; b=t1jJUhn/L1hHbDR0NAHSgE8o+wUIwshLDmDhnGeWJ6lRsSjCYST6tiDeo5olQU6kiWbpjrr1ufhSqoEJOtS7eLI6HFw2lqqIG61n80+TK+lL8eou2tsbVL7ZEmxg44SqwfNowmUcp/kQOjUJeB+SeN0JddVIttDPUMsZNIjb53I= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768496063; c=relaxed/simple; bh=J4bTb74X9OJ6aksbrTPMfbYESZ5lkTEr6OFMxyZ2TyM=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=CK5y2YxjHaGA11W9SHTT/nxFHEzUrkMMBB41InLqJrAzj4YzFzWHuOq1zeh/W2YJEdtxpBvzus//5KHQeip5J4NbBAfooe/T5gYbD7Btd4Vq8OCB7QlygNP8aCszYdTe7Da4ZRwcRTw5/EqtkrFt5H2f3OZJhtKKGGYk0alnB8M= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=e2iJdGOa; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="e2iJdGOa" Received: by smtp.kernel.org (Postfix) with ESMTPSA id E3808C116D0; Thu, 15 Jan 2026 16:54:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1768496063; bh=J4bTb74X9OJ6aksbrTPMfbYESZ5lkTEr6OFMxyZ2TyM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=e2iJdGOa/UZXgg26rlryrIm42pGpZvTxmt1n92uNBEASakn0nlWq0lrDI9anNCL+C pJwOHYy48km945m+Xl9Bi8GnBKfNmDpI2Et4RZI469BkJE9xntwbVojneiwB4SGytm 99BDHZdA9EIkH9DfVaiyWKeqQ/eRlbTTckYgn/fU= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, syzbot+bfc7323743ca6dbcc3d3@syzkaller.appspotmail.com, Eric Dumazet , Johannes Berg Subject: [PATCH 6.18 037/181] wifi: avoid kernel-infoleak from struct iw_point Date: Thu, 15 Jan 2026 17:46:14 +0100 Message-ID: <20260115164203.668561581@linuxfoundation.org> X-Mailer: git-send-email 2.52.0 In-Reply-To: <20260115164202.305475649@linuxfoundation.org> References: <20260115164202.305475649@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.18-stable review patch. If anyone has any objections, please let me know. ------------------ From: Eric Dumazet commit 21cbf883d073abbfe09e3924466aa5e0449e7261 upstream. struct iw_point has a 32bit hole on 64bit arches. struct iw_point { void __user *pointer; /* Pointer to the data (in user space) */ __u16 length; /* number of fields or size in bytes */ __u16 flags; /* Optional params */ }; Make sure to zero the structure to avoid disclosing 32bits of kernel data to user space. Fixes: 87de87d5e47f ("wext: Dispatch and handle compat ioctls entirely in net/wireless/wext.c") Reported-by: syzbot+bfc7323743ca6dbcc3d3@syzkaller.appspotmail.com Closes: https://lore.kernel.org/netdev/695f83f3.050a0220.1c677c.0392.GAE@google.com/T/#u Signed-off-by: Eric Dumazet Cc: stable@vger.kernel.org Link: https://patch.msgid.link/20260108101927.857582-1-edumazet@google.com Signed-off-by: Johannes Berg Signed-off-by: Greg Kroah-Hartman --- net/wireless/wext-core.c | 4 ++++ net/wireless/wext-priv.c | 4 ++++ 2 files changed, 8 insertions(+) --- a/net/wireless/wext-core.c +++ b/net/wireless/wext-core.c @@ -1101,6 +1101,10 @@ static int compat_standard_call(struct n return ioctl_standard_call(dev, iwr, cmd, info, handler); iwp_compat = (struct compat_iw_point *) &iwr->u.data; + + /* struct iw_point has a 32bit hole on 64bit arches. */ + memset(&iwp, 0, sizeof(iwp)); + iwp.pointer = compat_ptr(iwp_compat->pointer); iwp.length = iwp_compat->length; iwp.flags = iwp_compat->flags; --- a/net/wireless/wext-priv.c +++ b/net/wireless/wext-priv.c @@ -228,6 +228,10 @@ int compat_private_call(struct net_devic struct iw_point iwp; iwp_compat = (struct compat_iw_point *) &iwr->u.data; + + /* struct iw_point has a 32bit hole on 64bit arches. */ + memset(&iwp, 0, sizeof(iwp)); + iwp.pointer = compat_ptr(iwp_compat->pointer); iwp.length = iwp_compat->length; iwp.flags = iwp_compat->flags;