CVE-2023-52906·Kernel vulnerability
In the Linux kernel, the following vulnerability has been resolved: net/sched: act_mpls: Fix warning during failed attribute validation The 'TCA_MPLS_LABEL' attribute is of 'NLA_U32' type, but has a validation type of 'NLA_VALIDATE_FUNCTION'. This is an invalid combination according to the comment above 'struct nla_policy': " Meaning of `validate' field, use via NLA_POLICY_VALIDATE_FN: NLA_BINARY Validation function called for the attribute. All other Unused - but note that it's a union " This can trigger the warning [1] in nla_get_range_unsigned() when validation of the attribute fails. Despite being of 'NLA_U32' type, the associated 'min'/'max' fields in the policy are negative as they are aliased by the 'validate' field. Fix by changing the attribute type to 'NLA_BINARY' which is consistent with the above comment and all other users of NLA_POLICY_VALIDATE_FN(). As a result, move the length validation to the validation function. No regressions in MPLS tests: # ./tdc.py -f tc-tests/actions/mpls.json [...] # echo $? 0 [1] WARNING: CPU: 0 PID: 17743 at lib/nlattr.c:118 nla_get_range_unsigned+0x1d8/0x1e0 lib/nlattr.c:117 Modules linked in: CPU: 0 PID: 17743 Comm: syz-executor.0 Not tainted 6.1.0-rc8 #3 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.13.0-48-gd9c812dda519-prebuilt.qemu.org 04/01/2014 RIP: 0010:nla_get_range_unsigned+0x1d8/0x1e0 lib/nlattr.c:117 [...] Call Trace: <TASK> __netlink_policy_dump_write_attr+0x23d/0x990 net/netlink/policy.c:310 netlink_policy_dump_write_attr+0x22/0x30 net/netlink/policy.c:411 netlink_ack_tlv_fill net/netlink/af_netlink.c:2454 [inline] netlink_ack+0x546/0x760 net/netlink/af_netlink.c:2506 netlink_rcv_skb+0x1b7/0x240 net/netlink/af_netlink.c:2546 rtnetlink_rcv+0x18/0x20 net/core/rtnetlink.c:6109 netlink_unicast_kernel net/netlink/af_netlink.c:1319 [inline] netlink_unicast+0x5e9/0x6b0 net/netlink/af_netlink.c:1345 netlink_sendmsg+0x739/0x860 net/netlink/af_netlink.c:1921 sock_sendmsg_nosec net/socket.c:714 [inline] sock_sendmsg net/socket.c:734 [inline] ____sys_sendmsg+0x38f/0x500 net/socket.c:2482 ___sys_sendmsg net/socket.c:2536 [inline] __sys_sendmsg+0x197/0x230 net/socket.c:2565 __do_sys_sendmsg net/socket.c:2574 [inline] __se_sys_sendmsg net/socket.c:2572 [inline] __x64_sys_sendmsg+0x42/0x50 net/socket.c:2572 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x2b/0x70 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd
- Severity
- high
- Software
- Kernel
- Fixed in
- 6.1.7
- Published
- 2024-08-21
Affected versions
From: 5.16
Until: 6.1.7
Fixed in: 6.1.7
How to fix this CVE
Update your Linux kernel to version 6.1.7 or later to resolve this netlink attribute validation flaw in the MPLS traffic control module. The vulnerability stems from a mismatch between attribute type declaration and validation function usage, which can trigger kernel warnings during failed policy validation. Apply the update through your distribution's package manager to ensure the kernel patch is installed and active after reboot.
sudo dnf update kernel kernel-develDefensia detects this vulnerability
How to check if you are affected
- Check kernel version: uname -r — verify it is 6.1.7 or later; versions 5.16 through 6.1.6 are vulnerable
- Verify MPLS traffic control module presence: lsmod | grep mpls — check if act_mpls is loaded
- Review kernel logs for validation warnings: dmesg | grep -i 'nla_get_range_unsigned' — look for netlink attribute range validation warnings
- Confirm patch applied: grep -i 'TCA_MPLS_LABEL' /boot/config-$(uname -r) — ensure kernel configuration includes MPLS support; reboot after kernel update and re-run uname -r to confirm fixed version is running
FAQ
What is CVE-2023-52906?
A Linux kernel vulnerability in the MPLS traffic control module where the TCA_MPLS_LABEL attribute was incorrectly configured with a validation function mismatch, causing kernel warnings and potential system instability during netlink policy validation.
Is CVE-2023-52906 being actively exploited?
No, CVE-2023-52906 is not listed on the CISA Known Exploited Vulnerabilities catalog and no public exploits are available. However, it should still be patched to prevent kernel warnings and maintain system reliability.
What versions of Kernel are affected by CVE-2023-52906?
Linux kernel versions 5.16 through 6.1.6 are vulnerable. The fix is included in kernel 6.1.7 and later.
How do I check if my server is vulnerable to CVE-2023-52906?
Run 'uname -r' and compare your kernel version against 6.1.7; if your version is between 5.16 and 6.1.6, you are vulnerable and should update immediately.
Does Defensia detect CVE-2023-52906?
Yes — Defensia's CVE advisory scanner compares installed package versions against the NVD database. If Kernel is installed on a monitored server, CVE-2023-52906 will appear in your dashboard with remediation steps.
Related Kernel CVEs
References
- https://git.kernel.org/stable/c/2b157c3c5d6b8ddca48d53c9e662032f65af8d61
- https://git.kernel.org/stable/c/453277feb41c2235cf2c0de9209eef962c401457
- https://git.kernel.org/stable/c/8a97b544b98e44f596219ebb290fd2ba2fd5d644
- https://git.kernel.org/stable/c/9e17f99220d111ea031b44153fdfe364b0024ff2
- https://git.kernel.org/stable/c/9e2c38827cdc6fdd3bb375c8607fc04d289756f9
Track CVEs across your fleet automatically
Defensia scans your Linux servers and tells you exactly which ones are running vulnerable versions — including CVE-2023-52906. Free for 1 server.
Get started free