CVE-2024-35896: netfilter: validate user input for expected length

Published May 19, 2024
·
Updated

In the Linux kernel, the following vulnerability has been resolved:

netfilter: validate user input for expected length

I got multiple syzbot reports showing old bugs exposed by BPF after commit 20f2505fb436 ("bpf: Try to avoid kzalloc in cgroup/{s,g}etsockopt")

setsockopt() @optlen argument should be taken into account before copying data.

BUG: KASAN: slab-out-of-bounds in copyfromsockptroffset include/linux/sockptr.h:49 [inline] BUG: KASAN: slab-out-of-bounds in copyfromsockptr include/linux/sockptr.h:55 [inline] BUG: KASAN: slab-out-of-bounds in doreplace net/ipv4/netfilter/iptables.c:1111 [inline] BUG: KASAN: slab-out-of-bounds in doiptsetctl+0x902/0x3dd0 net/ipv4/netfilter/iptables.c:1627 Read of size 96 at addr ffff88802cd73da0 by task syz-executor.4/7238

CPU: 1 PID: 7238 Comm: syz-executor.4 Not tainted 6.9.0-rc2-next-20240403-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/27/2024 Call Trace: dumpstack lib/dumpstack.c:88 [inline] dumpstacklvl+0x241/0x360 lib/dumpstack.c:114 printaddressdescription mm/kasan/report.c:377 [inline] printreport+0x169/0x550 mm/kasan/report.c:488 kasanreport+0x143/0x180 mm/kasan/report.c:601 kasancheckrange+0x282/0x290 mm/kasan/generic.c:189 asanmemcpy+0x29/0x70 mm/kasan/shadow.c:105 copyfromsockptroffset include/linux/sockptr.h:49 [inline] copyfromsockptr include/linux/sockptr.h:55 [inline] doreplace net/ipv4/netfilter/iptables.c:1111 [inline] doiptsetctl+0x902/0x3dd0 net/ipv4/netfilter/iptables.c:1627 nfsetsockopt+0x295/0x2c0 net/netfilter/nfsockopt.c:101 dosocksetsockopt+0x3af/0x720 net/socket.c:2311 syssetsockopt+0x1ae/0x250 net/socket.c:2334 dosyssetsockopt net/socket.c:2343 [inline] sesyssetsockopt net/socket.c:2340 [inline] x64syssetsockopt+0xb5/0xd0 net/socket.c:2340 dosyscall64+0xfb/0x240 entrySYSCALL64afterhwframe+0x72/0x7a RIP: 0033:0x7fd22067dde9 Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 20 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b0 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fd21f9ff0c8 EFLAGS: 00000246 ORIGRAX: 0000000000000036 RAX: ffffffffffffffda RBX: 00007fd2207abf80 RCX: 00007fd22067dde9 RDX: 0000000000000040 RSI: 0000000000000000 RDI: 0000000000000003 RBP: 00007fd2206ca47a R08: 0000000000000001 R09: 0000000000000000 R10: 0000000020000880 R11: 0000000000000246 R12: 0000000000000000 R13: 000000000000000b R14: 00007fd2207abf80 R15: 00007ffd2d0170d8

Allocated by task 7238: kasansavestack mm/kasan/common.c:47 [inline] kasansavetrack+0x3f/0x80 mm/kasan/common.c:68 poisonkmallocredzone mm/kasan/common.c:370 [inline] kasankmalloc+0x98/0xb0 mm/kasan/common.c:387 kasankmalloc include/linux/kasan.h:211 [inline] dokmallocnode mm/slub.c:4069 [inline] kmallocnoprof+0x200/0x410 mm/slub.c:4082 kmallocnoprof include/linux/slab.h:664 [inline] cgroupbpfrunfiltersetsockopt+0xd47/0x1050 kernel/bpf/cgroup.c:1869 dosocksetsockopt+0x6b4/0x720 net/socket.c:2293 syssetsockopt+0x1ae/0x250 net/socket.c:2334 dosyssetsockopt net/socket.c:2343 [inline] sesyssetsockopt net/socket.c:2340 [inline] x64syssetsockopt+0xb5/0xd0 net/socket.c:2340 dosyscall64+0xfb/0x240 entrySYSCALL64afterhwframe+0x72/0x7a

The buggy address belongs to the object at ffff88802cd73da0 which belongs to the cache kmalloc-8 of size 8 The buggy address is located 0 bytes inside of allocated 1-byte region [ffff88802cd73da0, ffff88802cd73da1)

The buggy address belongs to the physical page: page: refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff88802cd73020 pfn:0x2cd73 flags: 0xfff80000000000(node=0|zone=1|lastcpupid=0xfff) pagetype: 0xffffefff(slab) raw: 00fff80000000000 ffff888015041280 dead000000000100 dead000000000122 raw: ffff88802cd73020 000000008080007f 00000001ffffefff 00 ---truncated---

Other sources

In the Linux kernel, the following vulnerability has been resolved:

netfilter: validate user input for expected length

I got multiple syzbot reports showing old bugs exposed by BPF after commit 20f2505fb436 ("bpf: Try to avoid kzalloc in cgroup/{s,g}etsockopt")

setsockopt() @optlen argument should be taken into account before copying data.

BUG: KASAN: slab-out-of-bounds in copyfromsockptroffset include/linux/sockptr.h:49 [inline] BUG: KASAN: slab-out-of-bounds in copyfromsockptr include/linux/sockptr.h:55 [inline] BUG: KASAN: slab-out-of-bounds in doreplace net/ipv4/netfilter/iptables.c:1111 [inline] BUG: KASAN: slab-out-of-bounds in doiptsetctl+0x902/0x3dd0 net/ipv4/netfilter/iptables.c:1627 Read of size 96 at addr ffff88802cd73da0 by task syz-executor.4/7238

CPU: 1 PID: 7238 Comm: syz-executor.4 Not tainted 6.9.0-rc2-next-20240403-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/27/2024 Call Trace: <TASK> dumpstack lib/dumpstack.c:88 [inline] dumpstacklvl+0x241/0x360 lib/dumpstack.c:114 printaddressdescription mm/kasan/report.c:377 [inline] printreport+0x169/0x550 mm/kasan/report.c:488 kasanreport+0x143/0x180 mm/kasan/report.c:601 kasancheckrange+0x282/0x290 mm/kasan/generic.c:189 asanmemcpy+0x29/0x70 mm/kasan/shadow.c:105 copyfromsockptroffset include/linux/sockptr.h:49 [inline] copyfromsockptr include/linux/sockptr.h:55 [inline] doreplace net/ipv4/netfilter/iptables.c:1111 [inline] doiptsetctl+0x902/0x3dd0 net/ipv4/netfilter/iptables.c:1627 nfsetsockopt+0x295/0x2c0 net/netfilter/nfsockopt.c:101 dosocksetsockopt+0x3af/0x720 net/socket.c:2311 syssetsockopt+0x1ae/0x250 net/socket.c:2334 dosyssetsockopt net/socket.c:2343 [inline] sesyssetsockopt net/socket.c:2340 [inline] x64syssetsockopt+0xb5/0xd0 net/socket.c:2340 dosyscall64+0xfb/0x240 entrySYSCALL64afterhwframe+0x72/0x7a RIP: 0033:0x7fd22067dde9 Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 20 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b0 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fd21f9ff0c8 EFLAGS: 00000246 ORIGRAX: 0000000000000036 RAX: ffffffffffffffda RBX: 00007fd2207abf80 RCX: 00007fd22067dde9 RDX: 0000000000000040 RSI: 0000000000000000 RDI: 0000000000000003 RBP: 00007fd2206ca47a R08: 0000000000000001 R09: 0000000000000000 R10: 0000000020000880 R11: 0000000000000246 R12: 0000000000000000 R13: 000000000000000b R14: 00007fd2207abf80 R15: 00007ffd2d0170d8 </TASK>

Allocated by task 7238: kasansavestack mm/kasan/common.c:47 [inline] kasansavetrack+0x3f/0x80 mm/kasan/common.c:68 poisonkmallocredzone mm/kasan/common.c:370 [inline] kasankmalloc+0x98/0xb0 mm/kasan/common.c:387 kasankmalloc include/linux/kasan.h:211 [inline] dokmallocnode mm/slub.c:4069 [inline] kmallocnoprof+0x200/0x410 mm/slub.c:4082 kmallocnoprof include/linux/slab.h:664 [inline] cgroupbpfrunfiltersetsockopt+0xd47/0x1050 kernel/bpf/cgroup.c:1869 dosocksetsockopt+0x6b4/0x720 net/socket.c:2293 syssetsockopt+0x1ae/0x250 net/socket.c:2334 dosyssetsockopt net/socket.c:2343 [inline] sesyssetsockopt net/socket.c:2340 [inline] x64syssetsockopt+0xb5/0xd0 net/socket.c:2340 dosyscall64+0xfb/0x240 entrySYSCALL64afterhwframe+0x72/0x7a

The buggy address belongs to the object at ffff88802cd73da0 which belongs to the cache kmalloc-8 of size 8 The buggy address is located 0 bytes inside of allocated 1-byte region [ffff88802cd73da0, ffff88802cd73da1)

The buggy address belongs to the physical page: page: refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff88802cd73020 pfn:0x2cd73 flags: 0xfff80000000000(node=0|zone=1|lastcpupid=0xfff) pagetype: 0xffffefff(slab) raw: 00fff80000000000 ffff888015041280 dead000000000100 dead000000000122 raw: ffff88802cd73020 000000008080007f 00000001ffffefff 00 ---truncated---

— MITRE

In the Linux kernel, the following vulnerability has been resolved:

netfilter: validate user input for expected length

The Linux kernel CVE team has assigned CVE-2024-35896 to this issue.

Upstream advisory: https://lore.kernel.org/linux-cve-announce/2024051950-CVE-2024-35896-e6b5@gregkh/T

— Red Hat

Affected Software

214 affected componentsFixes available
IBM Security Verify Governance<=ISVG 10.0.2
IBM Security Verify Governance, Identity Manager Software Stack<=ISVG 10.0.2
IBM Security Verify Governance, Identity Manager Virtual Appliance<=ISVG 10.0.2
IBM Security Verify Governance Identity Manager Container<=ISVG 10.0.2
Linux Linux kernel>=2.6.12<5.10.215
Linux Linux kernel>=5.11<5.15.154
Linux Linux kernel>=5.16<6.1.85
Linux Linux kernel>=6.2<6.6.26
Linux Linux kernel>=6.7<6.8.5
Linux Linux kernel=6.9-rc1
Linux Linux kernel=6.9-rc2
Debian Debian Linux=10.0
linux/kernel>=2.6.12<5.10.215
5.10.215
linux/kernel>=5.11.0<5.15.154
5.15.154
linux/kernel>=5.16.0<6.1.85
6.1.85
linux/kernel>=6.2.0<6.6.26
6.6.26
linux/kernel>=6.7.0<6.8.5
6.8.5
debian/linux<6.1.85-1
6.1.85-1
debian/linux<6.8.9-1
6.8.9-1
debian/linux<6.8.9-1
6.8.9-1
debian/linux
6.1.176-16.1.190-16.12.107-16.12.115-27.2.12-17.2.15-1
redhat/kernel<5.10.215
5.10.215
redhat/kernel<5.15.154
5.15.154
redhat/kernel<6.1.85
6.1.85
redhat/kernel<6.6.26
6.6.26
redhat/kernel<6.8.5
6.8.5
redhat/kernel<6.9
6.9
ubuntu/linux<3.13.0-214.265
3.13.0-214.265
ubuntu/linux-aws<4.4.0-1141.147
4.4.0-1141.147
ubuntu/linux-azure<4.15.0-1186.201~14.04.1
4.15.0-1186.201~14.04.1
ubuntu/linux-lts-xenial<4.4.0-266.300~14.04.1
4.4.0-266.300~14.04.1
ubuntu/linux<4.4.0-266.300
4.4.0-266.300
ubuntu/linux-aws<4.4.0-1179.194
4.4.0-1179.194
ubuntu/linux-aws-hwe<4.15.0-1178.191~16.04.1
4.15.0-1178.191~16.04.1
ubuntu/linux-azure<4.15.0-1186.201~16.04.1
4.15.0-1186.201~16.04.1
ubuntu/linux-gcp<4.15.0-1171.188~16.04.1
4.15.0-1171.188~16.04.1
ubuntu/linux-hwe<4.15.0-235.247~16.04.1
4.15.0-235.247~16.04.1
ubuntu/linux-kvm<4.4.0-1142.153
4.4.0-1142.153
ubuntu/linux-oracle<4.15.0-1140.151~16.04.1
4.15.0-1140.151~16.04.1
ubuntu/linux-hwe-edge*
ubuntu/linux-fips<4.4.0-1111.118
4.4.0-1111.118
ubuntu/linux-fips*
ubuntu/linux<4.15.0-235.247
4.15.0-235.247
ubuntu/linux-aws<4.15.0-1178.191
4.15.0-1178.191
ubuntu/linux-aws-5.0*
ubuntu/linux-aws-5.3*
ubuntu/linux-aws-5.4<5.4.0-1142.152~18.04.1
5.4.0-1142.152~18.04.1
ubuntu/linux-azure*
ubuntu/linux-azure-4.15<4.15.0-1186.201
4.15.0-1186.201
ubuntu/linux-azure-5.3*
ubuntu/linux-azure-5.4<5.4.0-1145.152~18.04.1
5.4.0-1145.152~18.04.1
ubuntu/linux-azure-edge*
ubuntu/linux-gcp*
ubuntu/linux-gcp-4.15<4.15.0-1171.188
4.15.0-1171.188
ubuntu/linux-gcp-5.3*
ubuntu/linux-gcp-5.4<5.4.0-1143.152~18.04.1
5.4.0-1143.152~18.04.1
ubuntu/linux-gke-4.15*
ubuntu/linux-gke-5.4*
ubuntu/linux-gkeop-5.4*
ubuntu/linux-hwe*
ubuntu/linux-hwe-5.4<5.4.0-208.228~18.04.1
5.4.0-208.228~18.04.1
ubuntu/linux-hwe-edge*
ubuntu/linux-ibm-5.4<5.4.0-1086.91~18.04.1
5.4.0-1086.91~18.04.1
ubuntu/linux-kvm<4.15.0-1161.166
4.15.0-1161.166
ubuntu/linux-oem*
ubuntu/linux-oracle<4.15.0-1140.151
4.15.0-1140.151
ubuntu/linux-oracle-5.0*
ubuntu/linux-oracle-5.3*
ubuntu/linux-oracle-5.4<5.4.0-1138.147~18.04.1
5.4.0-1138.147~18.04.1
ubuntu/linux-raspi-5.4<5.4.0-1129.142~18.04.1
5.4.0-1129.142~18.04.1
ubuntu/linux-aws-fips<4.15.0-2116.122
4.15.0-2116.122
ubuntu/linux-azure-fips<4.15.0-2095.101
4.15.0-2095.101
ubuntu/linux-fips<4.15.0-1133.144
4.15.0-1133.144
ubuntu/linux-gcp-fips<4.15.0-2079.85
4.15.0-2079.85
ubuntu/linux-aws-fips*
ubuntu/linux-azure-fips*
ubuntu/linux-fips*
ubuntu/linux-gcp-fips*
ubuntu/linux<5.4.0-208.228
5.4.0-208.228
ubuntu/linux-aws<5.4.0-1140.150
5.4.0-1140.150
ubuntu/linux-aws-5.15<5.15.0-1065.71~20.04.1
5.15.0-1065.71~20.04.1
ubuntu/linux-azure<5.4.0-1145.152
5.4.0-1145.152
ubuntu/linux-azure-5.15<5.15.0-1068.77~20.04.1
5.15.0-1068.77~20.04.1
ubuntu/linux-bluefield<5.4.0-1099.106
5.4.0-1099.106
ubuntu/linux-gcp<5.4.0-1143.152
5.4.0-1143.152
ubuntu/linux-gcp-5.15<5.15.0-1065.73~20.04.1
5.15.0-1065.73~20.04.1
ubuntu/linux-gkeop-5.15<5.15.0-1048.55~20.04.1
5.15.0-1048.55~20.04.1
ubuntu/linux-hwe-5.15<5.15.0-116.126~20.04.1
5.15.0-116.126~20.04.1
ubuntu/linux-ibm<5.4.0-1086.91
5.4.0-1086.91
ubuntu/linux-ibm-5.15<5.15.0-1058.61~20.04.1
5.15.0-1058.61~20.04.1
ubuntu/linux-intel-iotg-5.15<5.15.0-1060.66~20.04.1
5.15.0-1060.66~20.04.1
ubuntu/linux-iot<5.4.0-1048.51
5.4.0-1048.51
ubuntu/linux-kvm<5.4.0-1127.136
5.4.0-1127.136
ubuntu/linux-lowlatency-hwe-5.15<5.15.0-116.126~20.04.1
5.15.0-116.126~20.04.1
ubuntu/linux-nvidia-tegra-5.15<5.15.0-1027.27~20.04.1
5.15.0-1027.27~20.04.1
ubuntu/linux-oracle<5.4.0-1138.147
5.4.0-1138.147
ubuntu/linux-oracle-5.15<5.15.0-1063.69~20.04.1
5.15.0-1063.69~20.04.1
ubuntu/linux-raspi<5.4.0-1129.142
5.4.0-1129.142
ubuntu/linux-riscv-5.15<5.15.0-1061.65~20.04.1
5.15.0-1061.65~20.04.1
ubuntu/linux-xilinx-zynqmp<5.4.0-1058.62
5.4.0-1058.62
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-azure-fde*
ubuntu/linux-gcp-5.11*
ubuntu/linux-gcp-5.13*
ubuntu/linux-gcp-5.8*
ubuntu/linux-gke*
ubuntu/linux-gke-5.15*
ubuntu/linux-gkeop*
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-aws-fips<5.4.0-1140.151+fips1
5.4.0-1140.151+fips1
ubuntu/linux-azure-fips<5.4.0-1145.152+fips1
5.4.0-1145.152+fips1
ubuntu/linux-fips<5.4.0-1116.126
5.4.0-1116.126
ubuntu/linux-gcp-fips<5.4.0-1143.152+fips1
5.4.0-1143.152+fips1
ubuntu/linux-aws-fips*
ubuntu/linux-azure-fips*
ubuntu/linux-fips*
ubuntu/linux-gcp-fips*
ubuntu/linux<5.15.0-116.126
5.15.0-116.126
ubuntu/linux-allwinner-5.19*
ubuntu/linux-aws<5.15.0-1065.71
5.15.0-1065.71
ubuntu/linux-aws-5.19*
ubuntu/linux-aws-6.2*
ubuntu/linux-aws-6.5*
ubuntu/linux-aws-6.8<6.8.0-1011.12~22.04.1
6.8.0-1011.12~22.04.1
ubuntu/linux-azure<5.15.0-1068.77
5.15.0-1068.77
ubuntu/linux-azure-5.19*
ubuntu/linux-azure-6.2*
ubuntu/linux-azure-6.5*
ubuntu/linux-azure-6.8<6.8.0-1010.10~22.04.1
6.8.0-1010.10~22.04.1
ubuntu/linux-azure-fde<5.15.0-1068.77.1
5.15.0-1068.77.1
ubuntu/linux-azure-fde-5.19*
ubuntu/linux-azure-fde-6.2*
ubuntu/linux-gcp<5.15.0-1064.72
5.15.0-1064.72
ubuntu/linux-gcp-5.19*
ubuntu/linux-gcp-6.2*
ubuntu/linux-gcp-6.5*
ubuntu/linux-gke<5.15.0-1062.68
5.15.0-1062.68
ubuntu/linux-gkeop<5.15.0-1048.55
5.15.0-1048.55
ubuntu/linux-hwe-5.19*
ubuntu/linux-hwe-6.2*
ubuntu/linux-hwe-6.5*
ubuntu/linux-ibm<5.15.0-1058.61
5.15.0-1058.61
ubuntu/linux-intel-iotg<5.15.0-1060.66
5.15.0-1060.66
ubuntu/linux-kvm<5.15.0-1062.67
5.15.0-1062.67
ubuntu/linux-lowlatency<5.15.0-116.126
5.15.0-116.126
ubuntu/linux-lowlatency-hwe-5.19*
ubuntu/linux-lowlatency-hwe-6.2*
ubuntu/linux-lowlatency-hwe-6.5*
ubuntu/linux-nvidia<5.15.0-1060.61
5.15.0-1060.61
ubuntu/linux-nvidia-6.2*
ubuntu/linux-nvidia-6.5*
ubuntu/linux-nvidia-6.8<6.8.0-1009.9~22.04.1
6.8.0-1009.9~22.04.1
ubuntu/linux-nvidia-tegra<5.15.0-1026.26
5.15.0-1026.26
ubuntu/linux-nvidia-tegra-igx<5.15.0-1015.15
5.15.0-1015.15
ubuntu/linux-oem-5.17*
ubuntu/linux-oem-6.0*
ubuntu/linux-oem-6.1*
ubuntu/linux-oem-6.5*
ubuntu/linux-oracle<5.15.0-1063.69
5.15.0-1063.69
ubuntu/linux-oracle-6.5*
ubuntu/linux-oracle-6.8<6.8.0-1008.8~22.04.1
6.8.0-1008.8~22.04.1
ubuntu/linux-raspi<5.15.0-1058.61
5.15.0-1058.61
ubuntu/linux-realtime*
ubuntu/linux-riscv*
ubuntu/linux-riscv-5.19*
ubuntu/linux-riscv-6.5*
ubuntu/linux-starfive-5.19*
ubuntu/linux-starfive-6.2*
ubuntu/linux-starfive-6.5*
ubuntu/linux-xilinx-zynqmp<5.15.0-1035.39
5.15.0-1035.39
ubuntu/linux-bluefield<5.15.0-1047.49
5.15.0-1047.49
ubuntu/linux-intel-iot-realtime<5.15.0-1058.60
5.15.0-1058.60
ubuntu/linux-realtime<5.15.0-1066.74
5.15.0-1066.74
ubuntu/linux-aws-fips*
ubuntu/linux-azure-fips*
ubuntu/linux-fips*
ubuntu/linux-gcp-fips*
ubuntu/linux-aws-fips<5.15.0-1065.71+fips1
5.15.0-1065.71+fips1
ubuntu/linux-azure-fips<5.15.0-1068.77+fips1
5.15.0-1068.77+fips1
ubuntu/linux-fips<5.15.0-115.125+fips1
5.15.0-115.125+fips1
ubuntu/linux-gcp-fips<5.15.0-1064.72+fips1
5.15.0-1064.72+fips1
ubuntu/linux<6.8.0-38.38
6.8.0-38.38
ubuntu/linux-aws<6.8.0-1011.12
6.8.0-1011.12
ubuntu/linux-azure<6.8.0-1010.10
6.8.0-1010.10
ubuntu/linux-gcp<6.8.0-1010.11
6.8.0-1010.11
ubuntu/linux-gke<6.8.0-1006.9
6.8.0-1006.9
ubuntu/linux-ibm<6.8.0-1008.8
6.8.0-1008.8
ubuntu/linux-intel<6.8.0-1007.14
6.8.0-1007.14
ubuntu/linux-lowlatency<6.8.0-38.38.1
6.8.0-38.38.1
ubuntu/linux-nvidia<6.8.0-1009.9
6.8.0-1009.9
ubuntu/linux-oem-6.8<6.8.0-1008.8
6.8.0-1008.8
ubuntu/linux-oracle<6.8.0-1008.8
6.8.0-1008.8
ubuntu/linux-raspi<6.8.0-1007.7
6.8.0-1007.7
ubuntu/linux-riscv<6.8.0-38.38.1
6.8.0-38.38.1
ubuntu/linux-raspi-realtime<6.8.0-2006.6
6.8.0-2006.6
ubuntu/linux-realtime<6.8.1-1004.4
6.8.1-1004.4

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

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

    Fixed in 5.10.215
  2. Upgrade

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

    Fixed in 5.15.154
  3. Upgrade

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

    Fixed in 6.1.85
  4. Upgrade

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

    Fixed in 6.6.26
  5. Upgrade

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

    Fixed in 6.8.5
  6. Upgrade

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

    Fixed in 6.1.85-1
  7. Upgrade

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

    Fixed in 6.8.9-1
  8. Upgrade

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

    Fixed in 6.1.176-1Fixed in 6.1.190-1Fixed in 6.12.107-1Fixed in 6.12.115-2Fixed in 7.2.12-1Fixed in 7.2.15-1
  9. Upgrade

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

    Fixed in 5.10.215
  10. Upgrade

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

    Fixed in 5.15.154
  11. Upgrade

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

    Fixed in 6.1.85
  12. Upgrade

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

    Fixed in 6.6.26
  13. Upgrade

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

    Fixed in 6.8.5
  14. Upgrade

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

    Fixed in 6.9
  15. Upgrade

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

    Fixed in 3.13.0-214.265
  16. Upgrade

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

    Fixed in 4.4.0-1141.147
  17. Upgrade

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

    Fixed in 4.15.0-1186.201~14.04.1
  18. Upgrade

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

    Fixed in 4.4.0-266.300~14.04.1
  19. Upgrade

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

    Fixed in 4.4.0-266.300
  20. Upgrade

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

    Fixed in 4.4.0-1179.194
  21. Upgrade

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

    Fixed in 4.15.0-1178.191~16.04.1
  22. Upgrade

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

    Fixed in 4.15.0-1186.201~16.04.1
  23. Upgrade

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

    Fixed in 4.15.0-1171.188~16.04.1
  24. Upgrade

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

    Fixed in 4.15.0-235.247~16.04.1
  25. Upgrade

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

    Fixed in 4.4.0-1142.153
  26. Upgrade

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

    Fixed in 4.15.0-1140.151~16.04.1
  27. Upgrade

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

    Fixed in 4.4.0-1111.118
  28. Upgrade

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

    Fixed in 4.15.0-235.247
  29. Upgrade

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

    Fixed in 4.15.0-1178.191
  30. Upgrade

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

    Fixed in 5.4.0-1142.152~18.04.1
  31. Upgrade

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

    Fixed in 4.15.0-1186.201
  32. Upgrade

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

    Fixed in 5.4.0-1145.152~18.04.1
  33. Upgrade

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

    Fixed in 4.15.0-1171.188
  34. Upgrade

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

    Fixed in 5.4.0-1143.152~18.04.1
  35. Upgrade

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

    Fixed in 5.4.0-208.228~18.04.1
  36. Upgrade

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

    Fixed in 5.4.0-1086.91~18.04.1
  37. Upgrade

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

    Fixed in 4.15.0-1161.166
  38. Upgrade

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

    Fixed in 4.15.0-1140.151
  39. Upgrade

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

    Fixed in 5.4.0-1138.147~18.04.1
  40. Upgrade

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

    Fixed in 5.4.0-1129.142~18.04.1
  41. Upgrade

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

    Fixed in 4.15.0-2116.122
  42. Upgrade

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

    Fixed in 4.15.0-2095.101
  43. Upgrade

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

    Fixed in 4.15.0-1133.144
  44. Upgrade

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

    Fixed in 4.15.0-2079.85
  45. Upgrade

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

    Fixed in 5.4.0-208.228
  46. Upgrade

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

    Fixed in 5.4.0-1140.150
  47. Upgrade

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

    Fixed in 5.15.0-1065.71~20.04.1
  48. Upgrade

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

    Fixed in 5.4.0-1145.152
  49. Upgrade

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

    Fixed in 5.15.0-1068.77~20.04.1
  50. Upgrade

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

    Fixed in 5.4.0-1099.106
  51. Upgrade

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

    Fixed in 5.4.0-1143.152
  52. Upgrade

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

    Fixed in 5.15.0-1065.73~20.04.1
  53. Upgrade

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

    Fixed in 5.15.0-1048.55~20.04.1
  54. Upgrade

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

    Fixed in 5.15.0-116.126~20.04.1
  55. Upgrade

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

    Fixed in 5.4.0-1086.91
  56. Upgrade

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

    Fixed in 5.15.0-1058.61~20.04.1
  57. Upgrade

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

    Fixed in 5.15.0-1060.66~20.04.1
  58. Upgrade

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

    Fixed in 5.4.0-1048.51
  59. Upgrade

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

    Fixed in 5.4.0-1127.136
  60. Upgrade

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

    Fixed in 5.15.0-116.126~20.04.1
  61. Upgrade

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

    Fixed in 5.15.0-1027.27~20.04.1
  62. Upgrade

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

    Fixed in 5.4.0-1138.147
  63. Upgrade

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

    Fixed in 5.15.0-1063.69~20.04.1
  64. Upgrade

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

    Fixed in 5.4.0-1129.142
  65. Upgrade

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

    Fixed in 5.15.0-1061.65~20.04.1
  66. Upgrade

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

    Fixed in 5.4.0-1058.62
  67. Upgrade

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

    Fixed in 5.4.0-1140.151+fips1
  68. Upgrade

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

    Fixed in 5.4.0-1145.152+fips1
  69. Upgrade

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

    Fixed in 5.4.0-1116.126
  70. Upgrade

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

    Fixed in 5.4.0-1143.152+fips1
  71. Upgrade

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

    Fixed in 5.15.0-116.126
  72. Upgrade

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

    Fixed in 5.15.0-1065.71
  73. Upgrade

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

    Fixed in 6.8.0-1011.12~22.04.1
  74. Upgrade

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

    Fixed in 5.15.0-1068.77
  75. Upgrade

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

    Fixed in 6.8.0-1010.10~22.04.1
  76. Upgrade

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

    Fixed in 5.15.0-1068.77.1
  77. Upgrade

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

    Fixed in 5.15.0-1064.72
  78. Upgrade

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

    Fixed in 5.15.0-1062.68
  79. Upgrade

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

    Fixed in 5.15.0-1048.55
  80. Upgrade

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

    Fixed in 5.15.0-1058.61
  81. Upgrade

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

    Fixed in 5.15.0-1060.66
  82. Upgrade

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

    Fixed in 5.15.0-1062.67
  83. Upgrade

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

    Fixed in 5.15.0-116.126
  84. Upgrade

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

    Fixed in 5.15.0-1060.61
  85. Upgrade

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

    Fixed in 6.8.0-1009.9~22.04.1
  86. Upgrade

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

    Fixed in 5.15.0-1026.26
  87. Upgrade

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

    Fixed in 5.15.0-1015.15
  88. Upgrade

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

    Fixed in 5.15.0-1063.69
  89. Upgrade

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

    Fixed in 6.8.0-1008.8~22.04.1
  90. Upgrade

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

    Fixed in 5.15.0-1058.61
  91. Upgrade

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

    Fixed in 5.15.0-1035.39
  92. Upgrade

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

    Fixed in 5.15.0-1047.49
  93. Upgrade

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

    Fixed in 5.15.0-1058.60
  94. Upgrade

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

    Fixed in 5.15.0-1066.74
  95. Upgrade

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

    Fixed in 5.15.0-1065.71+fips1
  96. Upgrade

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

    Fixed in 5.15.0-1068.77+fips1
  97. Upgrade

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

    Fixed in 5.15.0-115.125+fips1
  98. Upgrade

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

    Fixed in 5.15.0-1064.72+fips1
  99. Upgrade

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

    Fixed in 6.8.0-38.38
  100. Upgrade

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

    Fixed in 6.8.0-1011.12
  101. Upgrade

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

    Fixed in 6.8.0-1010.10
  102. Upgrade

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

    Fixed in 6.8.0-1010.11
  103. Upgrade

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

    Fixed in 6.8.0-1006.9
  104. Upgrade

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

    Fixed in 6.8.0-1008.8
  105. Upgrade

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

    Fixed in 6.8.0-1007.14
  106. Upgrade

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

    Fixed in 6.8.0-38.38.1
  107. Upgrade

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

    Fixed in 6.8.0-1009.9
  108. Upgrade

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

    Fixed in 6.8.0-1008.8
  109. Upgrade

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

    Fixed in 6.8.0-1008.8
  110. Upgrade

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

    Fixed in 6.8.0-1007.7
  111. Upgrade

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

    Fixed in 6.8.0-38.38.1
  112. Upgrade

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

    Fixed in 6.8.0-2006.6
  113. Upgrade

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

    Fixed in 6.8.1-1004.4
  114. Upgrade

    Upgrade linux kernel to a version that resolves this vulnerability.

    Patch CVE-2024-35896
  115. Configuration

    Ensure the ip_tables/netfilter code path validates setsockopt() @optlen against the expected length before copying data (fix described as "netfilter: validate user input for expected length").

    netfilter ip_tables validate user input for expected length = apply validation of setsockopt() @optlen before copying data

Event History

May 19, 2024
CVE Published
via Ubuntu·12:00 AM
Data Sourced
via Ubuntu·12:00 AM
RemedyDescriptionSeverityAffected Software
Updated
via Ubuntu·12:00 AM
Affected Software
Updated
via Ubuntu·12:00 AM
RemedyDescriptionAffected Software
Updated
via Ubuntu·12:00 AM
Description
CVE Published
via MITRE·08:34 AM
Data Sourced
via MITRE·08:34 AM
Description
Data Sourced
via OSV·08:34 AM
DescriptionSeverityAffected Software
Event
via OSV·09:15 AM
Data Sourced
via NVD·09:15 AM
Description
May 20, 2024
Data Sourced
via Red Hat·11:30 AM
DescriptionSeverityAffected Software
Dec 30, 2024
Data Sourced
via NVD·05:35 PM
RemedySeverityWeaknessAffected Software
Mar 21, 2025
Updated
via NVD·06:15 PM
Affected Software
Apr 9, 2025
Data Sourced
via IBM·12:00 AM
DescriptionAffected Software
May 12, 2026
Updated
via NVD·12:16 PM
Affected Software
Aug 4, 2026
Data Sourced
via MITRE·09:23 AM
Severity
Updated
via NVD·11:18 AM
Severity
Oct 15, 2026
Updated
via NVD·01:17 AM
SeverityAffected Software
Nov 12, 2026
Updated
via OSV·05:24 PM
Affected Software

Parent advisories

This vulnerability appears in the following advisories.

Peer vulnerabilities

Found alongside the following vulnerabilities.

Frequently Asked Questions

1

What is the severity of CVE-2024-35896?

CVE-2024-35896 is classified as a medium severity vulnerability in the Linux kernel.

2

How do I fix CVE-2024-35896?

To fix CVE-2024-35896, you should upgrade to the patched kernel versions including 5.10.215, 5.15.154, 6.1.85, 6.6.26, or newer.

3

What systems are affected by CVE-2024-35896?

CVE-2024-35896 affects several versions of the Linux kernel, specifically those below 5.10.215, 5.15.154, 6.1.85, and 6.6.26.

4

What components of the Linux kernel are impacted by CVE-2024-35896?

CVE-2024-35896 impacts the netfilter component of the Linux kernel, specifically user input validation.

5

How can I check if my system is vulnerable to CVE-2024-35896?

You can check the version of your Linux kernel against the affected versions listed for CVE-2024-35896 to determine vulnerability.

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