Junglewise Threat Intelligence

CVE-2024-36939: Linux Kernel NFS resource cleanup failure in nfs_net_init

CVE-2024-36939 · Severity: medium · CVSS 5.5 · Published 2024-05-30

Technologies: Linux Kernel. Vendors: Linux.

Executive brief

A vulnerability in the Linux kernel's Network File System (NFS) component could allow a local user to cause a system warning or instability. The issue occurs when the system fails to properly handle errors during the initialization of network namespaces, a feature used to isolate network environments. While primarily resulting in kernel warnings during cleanup, such flaws can sometimes be leveraged to impact system availability.

Technical details

A flaw exists in the nfs_net_init() function within the Linux kernel's NFS implementation. The root cause is the failure to check the return value of rpc_proc_register(). If this registration fails, nfs_net_init() incorrectly returns success. Consequently, when the network namespace (netns) is later destroyed, nfs_net_exit() attempts to call rpc_proc_unregister(), which triggers a warning in remove_proc_entry() because it tries to remove a non-existent proc directory entry. This issue was made more visible by recent changes that converted procfs to be per-network namespace. Patches have been released for various stable kernel branches (e.g., 6.8.10, 6.6.31, 6.1.91).

Affected products

  • Linux Linux Kernel 2.6.12 to 6.8.10

Timeline

  • 2024-04-04: patched: Initial fix committed to mainline kernel
  • 2024-05-30: advisory: CVE published by NVD

References

Related threats