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 B3D4A2DE704 for ; Tue, 16 Dec 2025 15:07:49 +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=1765897669; cv=none; b=ryw+I9114Xhj/R46VxOxigDBB5EB2wBNnXIO05Xa2GjqJeUfVoO/2GMVaA7mkp9a2DpJfgwRUBwAXBWsFUdUISuMXEXznEuMHpFOuqZjvLKxOgh2uBXVXeGnegSdSctphJRCciXQ80l6J93ooRgIxfWaqBe5i4hYB485IYOCGvk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1765897669; c=relaxed/simple; bh=Dou8sTfprOv86zk9xgdd6zLKRCIn/30l85Sxt3i7JCg=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=ADTtNVCxRIkTZCiQt0jhOKijAhQabnwfeFCgPalklVCQSh14s5hdDbx1TvqXvUmAADbmZR9ajObR66v6uwdP6LIpT/v95KhwdJ6FU2HwHwb8gWD611p5wZmpQJcHexAt437zthqiHW6hCo2hmg6Ni8Q0l4iv0SpviHez18avXes= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=qR7YK4Xg; 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="qR7YK4Xg" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 380C5C4CEF1; Tue, 16 Dec 2025 15:07:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1765897669; bh=Dou8sTfprOv86zk9xgdd6zLKRCIn/30l85Sxt3i7JCg=; h=From:To:Cc:Subject:Date:Reply-To:From; b=qR7YK4XgzUBRb3NYp37QVJbU1fN2luSPlBoVQ7epI3nvjX6WW2V2UDCGTkch+by1t E02GpQG4NUXF73XuNbwKjKdZsb1071iSoHwoA0yYwePGKOFyvX8WctdmBoHjqQh8fc BBzqwfdx1IBViUkdQFdx6f7DXoxbImsEbU+FuKgM= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2025-68301: net: atlantic: fix fragment overflow handling in RX path Date: Tue, 16 Dec 2025 16:06:55 +0100 Message-ID: <2025121643-CVE-2025-68301-be31@gregkh> X-Mailer: git-send-email 2.52.0 Reply-To: , Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=5127; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=dORCzCGdISQSBApTEV2M6Pgv5LjwB4IElHEDmTQJvF0=; b=owGbwMvMwCRo6H6F97bub03G02pJDJmOpc2d+ZtUti47LlB/8nN1C/O+fR28/8tv3lg5a+nDs /Fqth/vdMSyMAgyMciKKbJ82cZzdH/FIUUvQ9vTMHNYmUCGMHBxCsBErF0ZZrOWyeSnK9ge31ug EZhk/fDQjuUKTAzzVOY87521ZkvT4j0m7b3FKfx+TALbAQ== X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: net: atlantic: fix fragment overflow handling in RX path The atlantic driver can receive packets with more than MAX_SKB_FRAGS (17) fragments when handling large multi-descriptor packets. This causes an out-of-bounds write in skb_add_rx_frag_netmem() leading to kernel panic. The issue occurs because the driver doesn't check the total number of fragments before calling skb_add_rx_frag(). When a packet requires more than MAX_SKB_FRAGS fragments, the fragment index exceeds the array bounds. Fix by assuming there will be an extra frag if buff->len > AQ_CFG_RX_HDR_SIZE, then all fragments are accounted for. And reusing the existing check to prevent the overflow earlier in the code path. This crash occurred in production with an Aquantia AQC113 10G NIC. Stack trace from production environment: ``` RIP: 0010:skb_add_rx_frag_netmem+0x29/0xd0 Code: 90 f3 0f 1e fa 0f 1f 44 00 00 48 89 f8 41 89 ca 48 89 d7 48 63 ce 8b 90 c0 00 00 00 48 c1 e1 04 48 01 ca 48 03 90 c8 00 00 00 <48> 89 7a 30 44 89 52 3c 44 89 42 38 40 f6 c7 01 75 74 48 89 fa 83 RSP: 0018:ffffa9bec02a8d50 EFLAGS: 00010287 RAX: ffff925b22e80a00 RBX: ffff925ad38d2700 RCX: fffffffe0a0c8000 RDX: ffff9258ea95bac0 RSI: ffff925ae0a0c800 RDI: 0000000000037a40 RBP: 0000000000000024 R08: 0000000000000000 R09: 0000000000000021 R10: 0000000000000848 R11: 0000000000000000 R12: ffffa9bec02a8e24 R13: ffff925ad8615570 R14: 0000000000000000 R15: ffff925b22e80a00 FS: 0000000000000000(0000) GS:ffff925e47880000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: ffff9258ea95baf0 CR3: 0000000166022004 CR4: 0000000000f72ef0 PKRU: 55555554 Call Trace: aq_ring_rx_clean+0x175/0xe60 [atlantic] ? aq_ring_rx_clean+0x14d/0xe60 [atlantic] ? aq_ring_tx_clean+0xdf/0x190 [atlantic] ? kmem_cache_free+0x348/0x450 ? aq_vec_poll+0x81/0x1d0 [atlantic] ? __napi_poll+0x28/0x1c0 ? net_rx_action+0x337/0x420 ``` Changes in v4: - Add Fixes: tag to satisfy patch validation requirements. Changes in v3: - Fix by assuming there will be an extra frag if buff->len > AQ_CFG_RX_HDR_SIZE, then all fragments are accounted for. The Linux kernel CVE team has assigned CVE-2025-68301 to this issue. Affected and fixed versions =========================== Issue introduced in 5.10.118 with commit cd66ab20a8f84474564a68fffffd37d998f6c340 and fixed in 5.10.247 with commit 34147477eeab24077fcfe9649e282849347d760c Issue introduced in 5.15.42 with commit 948ddbdc56636773401f2cb9c7a932eb9c43ccfd and fixed in 5.15.197 with commit b0c4d5135b04ea100988e2458c98f2d8564cda16 Issue introduced in 5.18 with commit 6aecbba12b5c90b26dc062af3b9de8c4b3a2f19f and fixed in 6.1.159 with commit 5d6051ea1b0417ae2f06a8440d22e48fbc8f8997 Issue introduced in 5.18 with commit 6aecbba12b5c90b26dc062af3b9de8c4b3a2f19f and fixed in 6.6.119 with commit 3be37c3c96b16462394fcb8e15e757c691377038 Issue introduced in 5.18 with commit 6aecbba12b5c90b26dc062af3b9de8c4b3a2f19f and fixed in 6.12.61 with commit 3fd2105e1b7e041cc24be151c9a31a14d5fc50ab Issue introduced in 5.18 with commit 6aecbba12b5c90b26dc062af3b9de8c4b3a2f19f and fixed in 6.17.11 with commit 64e47cd1fd631a21bf5a630cebefec6c8fc381cd Issue introduced in 5.18 with commit 6aecbba12b5c90b26dc062af3b9de8c4b3a2f19f and fixed in 6.18 with commit 5ffcb7b890f61541201461580bb6622ace405aec Issue introduced in 5.17.10 with commit dd4fb02847e737cc38ca75e708b1a836fba45faf Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2025-68301 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: drivers/net/ethernet/aquantia/atlantic/aq_ring.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/34147477eeab24077fcfe9649e282849347d760c https://git.kernel.org/stable/c/b0c4d5135b04ea100988e2458c98f2d8564cda16 https://git.kernel.org/stable/c/5d6051ea1b0417ae2f06a8440d22e48fbc8f8997 https://git.kernel.org/stable/c/3be37c3c96b16462394fcb8e15e757c691377038 https://git.kernel.org/stable/c/3fd2105e1b7e041cc24be151c9a31a14d5fc50ab https://git.kernel.org/stable/c/64e47cd1fd631a21bf5a630cebefec6c8fc381cd https://git.kernel.org/stable/c/5ffcb7b890f61541201461580bb6622ace405aec