CVE-2023-4194: Kernel: tap: tap_open(): correctly initialize socket uid next fix of i_uid to current_fsuid
A flaw found in the Linux Kernel. The tun/tap sockets have their socket UID hardcoded to 0 due to a type confusion in their initialization function. While it will be often correct, as tuntap devices require CAPNETADMIN, it may not always be the case, e.g., a non-root user only having that capability. This would make tun/tap sockets being incorrectly treated in filtering/routing decisions, possibly bypassing network filters. The original fix for the CVE-2023-1076 was incorrect. The problem is that the following upstream commits (that were fix for the CVE-2023-1076) - a096ccca6e50 ("tun: tunchropen(): correctly initialize socket uid"), - 66b2c338adce ("tap: tapopen(): correctly initialize socket uid"), pass "inode->iuid" to sockinitdatauid() as the last parameter and that turns out to be entirely bogus.
References: https://lore.kernel.org/all/20230731164237.48365-1-lersek@redhat.com/ https://lore.kernel.org/all/20230731164237.48365-2-lersek@redhat.com/ https://lore.kernel.org/all/20230731164237.48365-3-lersek@redhat.com/
Other sources
A flaw was found in the Linux kernel's TUN/TAP functionality. This issue could allow a local user to bypass network filters and gain unauthorized access to some resources. The original patches fixing CVE-2023-1076 are incorrect or incomplete. The problem is that the following upstream commits - a096ccca6e50 ("tun: tunchropen(): correctly initialize socket uid"), - 66b2c338adce ("tap: tapopen(): correctly initialize socket uid"), pass "inode->iuid" to sockinitdatauid() as the last parameter and that turns out to not be accurate.
— Launchpad
Affected Software
Remediation
Event History
Frequently Asked Questions
What is the severity of CVE-2023-4194?
CVE-2023-4194 has been classified as a medium severity vulnerability due to its potential impact on non-root users.
How do I fix CVE-2023-4194?
To fix CVE-2023-4194, you should upgrade your kernel to version 6.5 or later.
What versions of the Linux Kernel are affected by CVE-2023-4194?
CVE-2023-4194 affects Linux Kernel versions up to 6.4, including specific release candidates like 6.5-rc1 to 6.5-rc4.
Is CVE-2023-4194 present in Red Hat Enterprise Linux?
Yes, CVE-2023-4194 is present in Red Hat Enterprise Linux versions prior to the patched release.
Can I find CVE-2023-4194 on Debian Linux distributions?
Yes, CVE-2023-4194 impacts various Debian Linux distributions, including versions 10.0, 11.0, and 12.0.