| From bippy-5f407fcff5a0 Mon Sep 17 00:00:00 2001 |
| From: Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
| To: <linux-cve-announce@vger.kernel.org> |
| Reply-to: <cve@kernel.org>, <linux-kernel@vger.kernel.org> |
| Subject: CVE-2024-50094: sfc: Don't invoke xdp_do_flush() from netpoll. |
| |
| Description |
| =========== |
| |
| In the Linux kernel, the following vulnerability has been resolved: |
| |
| sfc: Don't invoke xdp_do_flush() from netpoll. |
| |
| Yury reported a crash in the sfc driver originated from |
| netpoll_send_udp(). The netconsole sends a message and then netpoll |
| invokes the driver's NAPI function with a budget of zero. It is |
| dedicated to allow driver to free TX resources, that it may have used |
| while sending the packet. |
| |
| In the netpoll case the driver invokes xdp_do_flush() unconditionally, |
| leading to crash because bpf_net_context was never assigned. |
| |
| Invoke xdp_do_flush() only if budget is not zero. |
| |
| The Linux kernel CVE team has assigned CVE-2024-50094 to this issue. |
| |
| |
| Affected and fixed versions |
| =========================== |
| |
| Issue introduced in 6.11 with commit 401cb7dae8130fd34eb84648e02ab4c506df7d5e and fixed in 6.11.4 with commit 65d4fc76d75c136744e67754d20feda609e7b793 |
| Issue introduced in 6.11 with commit 401cb7dae8130fd34eb84648e02ab4c506df7d5e and fixed in 6.12 with commit 55e802468e1d38dec8e25a2fdb6078d45b647e8c |
| |
| 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-2024-50094 |
| 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/sfc/efx_channels.c |
| drivers/net/ethernet/sfc/siena/efx_channels.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/65d4fc76d75c136744e67754d20feda609e7b793 |
| https://git.kernel.org/stable/c/55e802468e1d38dec8e25a2fdb6078d45b647e8c |