From nobody Wed Jun 12 19:16:56 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4VzwJn1FqSz5NHq6; Wed, 12 Jun 2024 19:16:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VzwJm5Wm1z57F3; Wed, 12 Jun 2024 19:16:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1718219816; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=gZIJ7MPfO4dMuLvXdPMukRqbKvB2vC1DG18hXI2fH44=; b=mY0YtUki21bqz1FE6xzH4YwogEVz8o6lK7JcRcg2wKGgjogMmMdfL5FHfJuUDm5j2M186S w21W0kUM7UBQwn7D3L3FAfImOvzB50b8OwNefSn+38E7HsenVHstt4qkMiF679b/SMvMhZ 4uBLlY1N5/ouYCGcCeG0sqBk9Mdk5BK0rvFM5mWFhzUTEPRC/j9nSBCKgBLIkRIlddUb1p 1/Q765PQS1Mf0l6MBJfwyN9lFnVRXUF7XqF/Z3C9nFGQqoyAZiI2L59Eu4yMcNtAu888Qy gR1lq+2A795ey7ZWqpGfNkWF2DAsS8zbYqbZ6GvPb9RRmXYUhtbxdYUiWUvCDA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1718219816; a=rsa-sha256; cv=none; b=Qp5vdwHzIEVXpq40zKkUSUJ+PwS0GyWJt4xX+v/hsB7CKHIqt59z5tUctLf+8FQbDh7Q8V b8wypzDBcL5OM++Q1hS3Ho+yjCEujKdmOwSFVuR4gnjYfI+j5no/DYCm+J1o4uUbG4cPr8 Mhv2f4bO6sw7F+z1ZFr8mGOr9+CGEJmiADNgzbuK5xw2lWYhiL9x9SD7KFsIBSbmQW8hVr uM4A919LbC6flqWpd3J2XRCQaemVpYjRkCOrX4HZSogX21hALfUiLm1MR+M3uEtWTC4ZiZ LN6m+srdCA1skFShYqIZjl4sFc0hFuKGQR4GkqaCmkIY5xHCCW81AJsbyToTAA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1718219816; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=gZIJ7MPfO4dMuLvXdPMukRqbKvB2vC1DG18hXI2fH44=; b=HhHmJt1hWGeRoIh5uANWHgJ5trOA9WcjHqCAssR3iocHVk8jhi0TdGKBLQfYUSS/ivr2BD +XGp2mwqHH1P8S+mDgX5ynXP53XE1gC7ycEB0zVAapeS8AYIObzveNbNEiE9aEJzON/s8G uA75ZHDcsbxHGSMRzNIETvQXUjvxdhyTjOk4DgwJthmD+qY2G7vllBjU453okSBNCrXjO6 toW5FkHu+Oer9gsT2y8v1QHLWrf8ASiQzujdqZz7oNbc7pZh3X4EUuuTn0I0/jpnDsSjAO fI48dtX/jgv/IcHDu+ksOf3oeDnP5H6mSl0eEVICPcyNzSSgc40zxHocd2OdWg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4VzwJm58JGz158D; Wed, 12 Jun 2024 19:16:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 45CJGuXY004373; Wed, 12 Jun 2024 19:16:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 45CJGuCF004370; Wed, 12 Jun 2024 19:16:56 GMT (envelope-from git) Date: Wed, 12 Jun 2024 19:16:56 GMT Message-Id: <202406121916.45CJGuCF004370@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: ba0e9f526481 - stable/13 - LinuxKPI: 802.11: initalize lsta to NULL in linuxkpi_ieee80211_rx() List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: ba0e9f526481d087bb9b3dfeb341134a5d56a7c5 Auto-Submitted: auto-generated The branch stable/13 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=ba0e9f526481d087bb9b3dfeb341134a5d56a7c5 commit ba0e9f526481d087bb9b3dfeb341134a5d56a7c5 Author: Bjoern A. Zeeb AuthorDate: 2024-06-05 22:35:00 +0000 Commit: Bjoern A. Zeeb CommitDate: 2024-06-12 17:02:05 +0000 LinuxKPI: 802.11: initalize lsta to NULL in linuxkpi_ieee80211_rx() The logic following this new assignment in some cases may not set lsta but the later tracing is checking for it to be != NULL. With lsta not initialized that check may not hold up and later we would dereference lsta->state and possibly panic. Sponsored by: The FreeBSD Foundation Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D45507 (cherry picked from commit 582469016aed4fac3a7ead24dc31000edbb7e823) --- sys/compat/linuxkpi/common/src/linux_80211.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index e5fcb81dce6a..b48f64fb1b0f 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -4926,6 +4926,7 @@ no_trace_beacons: goto err; } + lsta = NULL; if (sta != NULL) { lsta = STA_TO_LSTA(sta); ni = ieee80211_ref_node(lsta->ni);