CVE-2023-4015: Use-after-free in Linux kernel's netfilter: nf_tables component

Published Sep 6, 2023
·
Updated

A use-after-free vulnerability in the Linux kernel's netfilter: nftables component can be exploited to achieve local privilege escalation.

On an error when building a nftables rule, deactivating immediate expressions in nftimmediatedeactivate() can lead unbinding the chain and objects be deactivated but later used.

We recommend upgrading past commit 0a771f7b266b02d262900c75f1e175c7fe76fec2.

Affected Software

100 affected componentsFixes available
Linux Linux kernel>=5.9<5.10.190
Linux Linux kernel>=5.11<5.15.124
Linux Linux kernel>=5.16<6.1.43
Linux Linux kernel>=6.2<6.4.8
Debian Debian Linux=12.0
Linux Linux kernel<=6.5
redhat/kernel<6.5
6.5
ubuntu/linux-hwe-edge*
ubuntu/linux-aws-5.0*
ubuntu/linux-aws-5.3*
ubuntu/linux-azure*
ubuntu/linux-azure-5.3*
ubuntu/linux-azure-edge*
ubuntu/linux-gcp*
ubuntu/linux-gcp-5.3*
ubuntu/linux-gke-4.15*
ubuntu/linux-gke-5.4*
ubuntu/linux-gkeop-5.4*
ubuntu/linux-hwe*
ubuntu/linux-oem*
ubuntu/linux-oracle-5.0*
ubuntu/linux-oracle-5.3*
ubuntu/linux-aws-5.15<5.15.0-1043.48~20.04.1
5.15.0-1043.48~20.04.1
ubuntu/linux-azure-5.15<5.15.0-1045.52~20.04.1
5.15.0-1045.52~20.04.1
ubuntu/linux-gcp-5.15<5.15.0-1040.48~20.04.1
5.15.0-1040.48~20.04.1
ubuntu/linux-gkeop-5.15<5.15.0-1026.31~20.04.1
5.15.0-1026.31~20.04.1
ubuntu/linux-hwe-5.15<5.15.0-82.91~20.04.1
5.15.0-82.91~20.04.1
ubuntu/linux-ibm-5.15<5.15.0-1036.39~20.04.1
5.15.0-1036.39~20.04.1
ubuntu/linux-intel-iotg-5.15<5.15.0-1038.43~20.04.1
5.15.0-1038.43~20.04.1
ubuntu/linux-lowlatency-hwe-5.15<5.15.0-82.91~20.04.1
5.15.0-82.91~20.04.1
ubuntu/linux-nvidia-tegra-5.15<5.15.0-1017.17~20.04.1
5.15.0-1017.17~20.04.1
ubuntu/linux-oracle-5.15<5.15.0-1041.47~20.04.1
5.15.0-1041.47~20.04.1
ubuntu/linux-riscv-5.15<5.15.0-1039.43~20.04.2
5.15.0-1039.43~20.04.2
ubuntu/linux-aws-5.11*
ubuntu/linux-aws-5.13*
ubuntu/linux-aws-5.8*
ubuntu/linux-azure-5.11*
ubuntu/linux-azure-5.13*
ubuntu/linux-azure-5.8*
ubuntu/linux-gcp-5.11*
ubuntu/linux-gcp-5.13*
ubuntu/linux-gcp-5.8*
ubuntu/linux-hwe-5.11*
ubuntu/linux-hwe-5.13*
ubuntu/linux-hwe-5.8*
ubuntu/linux-intel-5.13*
ubuntu/linux-oem-5.10*
ubuntu/linux-oem-5.13*
ubuntu/linux-oem-5.6*
ubuntu/linux-oracle-5.11*
ubuntu/linux-oracle-5.13*
ubuntu/linux-oracle-5.8*
ubuntu/linux-raspi2*
ubuntu/linux-riscv*
ubuntu/linux-riscv-5.11*
ubuntu/linux-riscv-5.8*
ubuntu/linux<5.15.0-82.91
5.15.0-82.91
ubuntu/linux-allwinner-5.19*
ubuntu/linux-aws<5.15.0-1043.48
5.15.0-1043.48
ubuntu/linux-aws-5.19*
ubuntu/linux-aws-6.2<6.2.0-1010.10~22.04.1
6.2.0-1010.10~22.04.1
ubuntu/linux-azure<5.15.0-1045.52
5.15.0-1045.52
ubuntu/linux-azure-5.19*
ubuntu/linux-azure-6.2*
ubuntu/linux-azure-fde<5.15.0-1045.52.1
5.15.0-1045.52.1
ubuntu/linux-azure-fde-5.19*
ubuntu/linux-azure-fde-6.2*
ubuntu/linux-gcp<5.15.0-1040.48
5.15.0-1040.48
ubuntu/linux-gcp-5.19*
ubuntu/linux-gcp-6.2*
ubuntu/linux-gke<5.15.0-1040.45
5.15.0-1040.45
ubuntu/linux-gkeop<5.15.0-1026.31
5.15.0-1026.31
ubuntu/linux-hwe-5.19*
ubuntu/linux-hwe-6.2<6.2.0-31.31~22.04.1
6.2.0-31.31~22.04.1
ubuntu/linux-ibm<5.15.0-1036.39
5.15.0-1036.39
ubuntu/linux-intel-iotg<5.15.0-1038.43
5.15.0-1038.43
ubuntu/linux-kvm<5.15.0-1040.45
5.15.0-1040.45
ubuntu/linux-lowlatency<5.15.0-82.91
5.15.0-82.91
ubuntu/linux-lowlatency-hwe-5.19*
ubuntu/linux-lowlatency-hwe-6.2<6.2.0-1011.11~22.04.1
6.2.0-1011.11~22.04.1
ubuntu/linux-nvidia<5.15.0-1031.31
5.15.0-1031.31
ubuntu/linux-nvidia-6.2*
ubuntu/linux-nvidia-tegra<5.15.0-1017.17
5.15.0-1017.17
ubuntu/linux-nvidia-tegra-igx<5.15.0-1004.4
5.15.0-1004.4
ubuntu/linux-oem-5.17*
ubuntu/linux-oem-6.0<6.0.0-1021.21
6.0.0-1021.21
ubuntu/linux-oem-6.1<6.1.0-1020.20
6.1.0-1020.20
ubuntu/linux-oracle<5.15.0-1041.47
5.15.0-1041.47
ubuntu/linux-raspi<5.15.0-1036.39
5.15.0-1036.39
ubuntu/linux-realtime*
ubuntu/linux-riscv*
ubuntu/linux-riscv-5.19*
ubuntu/linux-starfive-5.19*
ubuntu/linux-xilinx-zynqmp<5.15.0-1025.29
5.15.0-1025.29
ubuntu/linux-bluefield<5.15.0-1022.24
5.15.0-1022.24
ubuntu/linux-intel-iot-realtime<5.15.0-1037.39
5.15.0-1037.39
ubuntu/linux-realtime<5.15.0-1044.49
5.15.0-1044.49
ubuntu/linux-fips*
ubuntu/linux-raspi-realtime*
debian/linux
6.1.52-16.4.11-1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade redhat/Kernel to a version that resolves this vulnerability.

    Fixed in 6.5
  2. Upgrade

    Upgrade ubuntu/linux-aws-5.15 to a version that resolves this vulnerability.

    Fixed in 5.15.0-1043.48~20.04.1
  3. Upgrade

    Upgrade ubuntu/linux-azure-5.15 to a version that resolves this vulnerability.

    Fixed in 5.15.0-1045.52~20.04.1
  4. Upgrade

    Upgrade ubuntu/linux-gcp-5.15 to a version that resolves this vulnerability.

    Fixed in 5.15.0-1040.48~20.04.1
  5. Upgrade

    Upgrade ubuntu/linux-gkeop-5.15 to a version that resolves this vulnerability.

    Fixed in 5.15.0-1026.31~20.04.1
  6. Upgrade

    Upgrade ubuntu/linux-hwe-5.15 to a version that resolves this vulnerability.

    Fixed in 5.15.0-82.91~20.04.1
  7. Upgrade

    Upgrade ubuntu/linux-ibm-5.15 to a version that resolves this vulnerability.

    Fixed in 5.15.0-1036.39~20.04.1
  8. Upgrade

    Upgrade ubuntu/linux-intel-iotg-5.15 to a version that resolves this vulnerability.

    Fixed in 5.15.0-1038.43~20.04.1
  9. Upgrade

    Upgrade ubuntu/linux-lowlatency-hwe-5.15 to a version that resolves this vulnerability.

    Fixed in 5.15.0-82.91~20.04.1
  10. Upgrade

    Upgrade ubuntu/linux-nvidia-tegra-5.15 to a version that resolves this vulnerability.

    Fixed in 5.15.0-1017.17~20.04.1
  11. Upgrade

    Upgrade ubuntu/linux-oracle-5.15 to a version that resolves this vulnerability.

    Fixed in 5.15.0-1041.47~20.04.1
  12. Upgrade

    Upgrade ubuntu/linux-riscv-5.15 to a version that resolves this vulnerability.

    Fixed in 5.15.0-1039.43~20.04.2
  13. Upgrade

    Upgrade ubuntu/linux to a version that resolves this vulnerability.

    Fixed in 5.15.0-82.91
  14. Upgrade

    Upgrade ubuntu/linux-aws to a version that resolves this vulnerability.

    Fixed in 5.15.0-1043.48
  15. Upgrade

    Upgrade ubuntu/linux-aws-6.2 to a version that resolves this vulnerability.

    Fixed in 6.2.0-1010.10~22.04.1
  16. Upgrade

    Upgrade ubuntu/linux-azure to a version that resolves this vulnerability.

    Fixed in 5.15.0-1045.52
  17. Upgrade

    Upgrade ubuntu/linux-azure-fde to a version that resolves this vulnerability.

    Fixed in 5.15.0-1045.52.1
  18. Upgrade

    Upgrade ubuntu/linux-gcp to a version that resolves this vulnerability.

    Fixed in 5.15.0-1040.48
  19. Upgrade

    Upgrade ubuntu/linux-gke to a version that resolves this vulnerability.

    Fixed in 5.15.0-1040.45
  20. Upgrade

    Upgrade ubuntu/linux-gkeop to a version that resolves this vulnerability.

    Fixed in 5.15.0-1026.31
  21. Upgrade

    Upgrade ubuntu/linux-hwe-6.2 to a version that resolves this vulnerability.

    Fixed in 6.2.0-31.31~22.04.1
  22. Upgrade

    Upgrade ubuntu/linux-ibm to a version that resolves this vulnerability.

    Fixed in 5.15.0-1036.39
  23. Upgrade

    Upgrade ubuntu/linux-intel-iotg to a version that resolves this vulnerability.

    Fixed in 5.15.0-1038.43
  24. Upgrade

    Upgrade ubuntu/linux-kvm to a version that resolves this vulnerability.

    Fixed in 5.15.0-1040.45
  25. Upgrade

    Upgrade ubuntu/linux-lowlatency to a version that resolves this vulnerability.

    Fixed in 5.15.0-82.91
  26. Upgrade

    Upgrade ubuntu/linux-lowlatency-hwe-6.2 to a version that resolves this vulnerability.

    Fixed in 6.2.0-1011.11~22.04.1
  27. Upgrade

    Upgrade ubuntu/linux-nvidia to a version that resolves this vulnerability.

    Fixed in 5.15.0-1031.31
  28. Upgrade

    Upgrade ubuntu/linux-nvidia-tegra to a version that resolves this vulnerability.

    Fixed in 5.15.0-1017.17
  29. Upgrade

    Upgrade ubuntu/linux-nvidia-tegra-igx to a version that resolves this vulnerability.

    Fixed in 5.15.0-1004.4
  30. Upgrade

    Upgrade ubuntu/linux-oem-6.0 to a version that resolves this vulnerability.

    Fixed in 6.0.0-1021.21
  31. Upgrade

    Upgrade ubuntu/linux-oem-6.1 to a version that resolves this vulnerability.

    Fixed in 6.1.0-1020.20
  32. Upgrade

    Upgrade ubuntu/linux-oracle to a version that resolves this vulnerability.

    Fixed in 5.15.0-1041.47
  33. Upgrade

    Upgrade ubuntu/linux-raspi to a version that resolves this vulnerability.

    Fixed in 5.15.0-1036.39
  34. Upgrade

    Upgrade ubuntu/linux-xilinx-zynqmp to a version that resolves this vulnerability.

    Fixed in 5.15.0-1025.29
  35. Upgrade

    Upgrade ubuntu/linux-bluefield to a version that resolves this vulnerability.

    Fixed in 5.15.0-1022.24
  36. Upgrade

    Upgrade ubuntu/linux-intel-iot-realtime to a version that resolves this vulnerability.

    Fixed in 5.15.0-1037.39
  37. Upgrade

    Upgrade ubuntu/linux-realtime to a version that resolves this vulnerability.

    Fixed in 5.15.0-1044.49
  38. Upgrade

    Upgrade debian/linux to a version that resolves this vulnerability.

    Fixed in 6.1.52-1Fixed in 6.4.11-1
  39. Upgrade

    Upgrade Linux kernel netfilter nf_tables to a version that resolves this vulnerability.

    Patch 0a771f7b266b02d262900c75f1e175c7fe76fec2
  40. Configuration

    If unprivileged users do not need to create namespaces, set kernel.unprivileged_userns_clone=0; apply temporarily with sysctl and persist across reboots in /etc/sysctl.d/99-disable-unpriv-userns.conf.

    Linux kernel kernel.unprivileged_userns_clone = 0

Event History

Aug 3, 2023
CVE Published
12:00 AM
Data Sourced
12:00 AM
RemedyDescriptionSeverityAffected Software
Data Sourced
via OSV·12:00 AM
DescriptionSeverityAffected Software
Updated
12:00 AM
Affected Software
Updated
12:00 AM
Description
Updated
via Ubuntu·12:00 AM
RemedyDescriptionAffected Software
Sep 6, 2023
CVE Published
via MITRE·01:52 PM
Data Sourced
via MITRE·01:52 PM
DescriptionSeverityWeakness
Data Sourced
via Red Hat·05:37 PM
DescriptionSeverityAffected Software
Sep 7, 2023
Data Sourced
01:10 AM
Weakness
Sep 11, 2023
Updated
05:59 PM
SeverityWeakness
Dec 12, 2023
Updated
02:31 PM
Affected Software
Nov 21, 2024
Data Sourced
via NVD·08:34 AM
RemedyDescriptionSeverityWeaknessAffected Software
Updated
via NVD·08:34 AM
RemedyAffected Software
Feb 13, 2025
Updated
via NVD·05:17 PM
DescriptionAffected Software
Oct 14, 2026
Updated
via MITRE·09:23 PM
Description
Updated
via NVD·10:17 PM
Affected Software
Nov 12, 2026
Updated
via OSV·05:23 PM
Affected Software

Parent advisories

This vulnerability appears in the following advisories.

Frequently Asked Questions

1

What is the severity of CVE-2023-4015?

The severity of CVE-2023-4015 is relatively high due to its potential for local privilege escalation.

2

How do I fix CVE-2023-4015?

To fix CVE-2023-4015, update the Linux kernel to version 6.5 or apply the necessary patches as specified by your distribution.

3

Which systems are affected by CVE-2023-4015?

CVE-2023-4015 affects various versions of the Linux kernel, specifically from 5.9 to 6.5, and certain Debian Linux versions.

4

What type of vulnerability is CVE-2023-4015?

CVE-2023-4015 is classified as a use-after-free vulnerability in the netfilter nf_tables component.

5

Can CVE-2023-4015 be exploited remotely?

CVE-2023-4015 is primarily a local privilege escalation vulnerability and cannot be exploited remotely.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203