{"id":"CVE-2026-143359","state":"PUBLISHED","title":"bpf: Reject non-IPv6 packets in BPF_LWT_ENCAP_SEG6","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nbpf: Reject non-IPv6 packets in BPF_LWT_ENCAP_SEG6\n\nThe mode BPF_LWT_ENCAP_SEG6 of bpf_lwt_push_encap() pushes an IPv6 header\nand an SRH, and it replaces the dst. The SRH says that IPv6 follows, and\nskb->protocol does not change. Thus the mode assumes an IPv6 packet, but an\nlwt_in prog also runs for IPv4 packets. After the prog, bpf_input() calls\norig_input() of the old dst. This IPv4 handler reads the pushed headers as\nIPv4. It can write after the packet data, and the kernel crashes.\n\n                 after the push         orig_input() expects\n                 ---------------------  --------------------\n  skb->protocol  ETH_P_IP               ETH_P_IP\n  dst            rt6_info               rtable\n  packet         | IPv6 | SRH | IPv4 |  | IPv4 |\n\nThe mode BPF_LWT_ENCAP_SEG6_INLINE returns -EBADMSG for non-IPv6 packets.\nApply this check to both modes. End.BPF does not change, because\nseg6_local_input() drops non-IPv6 packets.","publishedAt":"2026-12-03T09:22:13.623Z","updatedAt":"2026-12-03T09:22:13.623Z","severity":null,"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"fe94cc290f535709d3c5ebd1e472dfd0aec7ee79","status":"affected","lessThan":"4a612ff71a094f2d77a4b07787ef45cfc2eb04a3","versionType":"git"},{"version":"fe94cc290f535709d3c5ebd1e472dfd0aec7ee79","status":"affected","lessThan":"32f8d033044693f77f98da40ab206e38108cde6f","versionType":"git"},{"version":"fe94cc290f535709d3c5ebd1e472dfd0aec7ee79","status":"affected","lessThan":"ad3d6fe9772e06b50082d91e5906aa21ed2cb4ac","versionType":"git"},{"version":"fe94cc290f535709d3c5ebd1e472dfd0aec7ee79","status":"affected","lessThan":"d29c91e8c031bc9b5a78dc199235893c040877db","versionType":"git"},{"version":"fe94cc290f535709d3c5ebd1e472dfd0aec7ee79","status":"affected","lessThan":"d7106132b69e6916762bbbfd95fbcb60be4b8d9b","versionType":"git"},{"version":"fe94cc290f535709d3c5ebd1e472dfd0aec7ee79","status":"affected","lessThan":"58e39f8d58b141b96c030008a20dde9d625ec997","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/core/filter.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"4.18","status":"affected"},{"version":"0","status":"unaffected","lessThan":"4.18","versionType":"semver"},{"version":"5.10.276","status":"unaffected","lessThanOrEqual":"5.10.*","versionType":"semver"},{"version":"5.15.227","status":"unaffected","lessThanOrEqual":"5.15.*","versionType":"semver"},{"version":"6.12.120","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.18.66","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.3.7","status":"unaffected","lessThanOrEqual":"7.3.*","versionType":"semver"},{"version":"7.4-rc2","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/core/filter.c"]}],"references":["https://git.kernel.org/stable/c/4a612ff71a094f2d77a4b07787ef45cfc2eb04a3","https://git.kernel.org/stable/c/32f8d033044693f77f98da40ab206e38108cde6f","https://git.kernel.org/stable/c/ad3d6fe9772e06b50082d91e5906aa21ed2cb4ac","https://git.kernel.org/stable/c/d29c91e8c031bc9b5a78dc199235893c040877db","https://git.kernel.org/stable/c/d7106132b69e6916762bbbfd95fbcb60be4b8d9b","https://git.kernel.org/stable/c/58e39f8d58b141b96c030008a20dde9d625ec997"],"weaknesses":[],"ingestedAt":"2026-12-03T09:44:04.436Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/143xxx/CVE-2026-143359.json","commit":"9e309c7c0f08856e2558a1df33f75dca027fab70","baselineCommit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-143359","state":"PUBLISHED","datePublished":"2026-12-03T09:22:13.623Z","dateUpdated":"2026-12-03T09:22:13.623Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2026-12-03T03:10:28.371Z"},"containers":{"cna":{"title":"bpf: Reject non-IPv6 packets in BPF_LWT_ENCAP_SEG6","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nbpf: Reject non-IPv6 packets in BPF_LWT_ENCAP_SEG6\n\nThe mode BPF_LWT_ENCAP_SEG6 of bpf_lwt_push_encap() pushes an IPv6 header\nand an SRH, and it replaces the dst. The SRH says that IPv6 follows, and\nskb->protocol does not change. Thus the mode assumes an IPv6 packet, but an\nlwt_in prog also runs for IPv4 packets. After the prog, bpf_input() calls\norig_input() of the old dst. This IPv4 handler reads the pushed headers as\nIPv4. It can write after the packet data, and the kernel crashes.\n\n                 after the push         orig_input() expects\n                 ---------------------  --------------------\n  skb->protocol  ETH_P_IP               ETH_P_IP\n  dst            rt6_info               rtable\n  packet         | IPv6 | SRH | IPv4 |  | IPv4 |\n\nThe mode BPF_LWT_ENCAP_SEG6_INLINE returns -EBADMSG for non-IPv6 packets.\nApply this check to both modes. End.BPF does not change, because\nseg6_local_input() drops non-IPv6 packets."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"fe94cc290f535709d3c5ebd1e472dfd0aec7ee79","status":"affected","lessThan":"4a612ff71a094f2d77a4b07787ef45cfc2eb04a3","versionType":"git"},{"version":"fe94cc290f535709d3c5ebd1e472dfd0aec7ee79","status":"affected","lessThan":"32f8d033044693f77f98da40ab206e38108cde6f","versionType":"git"},{"version":"fe94cc290f535709d3c5ebd1e472dfd0aec7ee79","status":"affected","lessThan":"ad3d6fe9772e06b50082d91e5906aa21ed2cb4ac","versionType":"git"},{"version":"fe94cc290f535709d3c5ebd1e472dfd0aec7ee79","status":"affected","lessThan":"d29c91e8c031bc9b5a78dc199235893c040877db","versionType":"git"},{"version":"fe94cc290f535709d3c5ebd1e472dfd0aec7ee79","status":"affected","lessThan":"d7106132b69e6916762bbbfd95fbcb60be4b8d9b","versionType":"git"},{"version":"fe94cc290f535709d3c5ebd1e472dfd0aec7ee79","status":"affected","lessThan":"58e39f8d58b141b96c030008a20dde9d625ec997","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/core/filter.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"4.18","status":"affected"},{"version":"0","status":"unaffected","lessThan":"4.18","versionType":"semver"},{"version":"5.10.276","status":"unaffected","lessThanOrEqual":"5.10.*","versionType":"semver"},{"version":"5.15.227","status":"unaffected","lessThanOrEqual":"5.15.*","versionType":"semver"},{"version":"6.12.120","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.18.66","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.3.7","status":"unaffected","lessThanOrEqual":"7.3.*","versionType":"semver"},{"version":"7.4-rc2","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/core/filter.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/4a612ff71a094f2d77a4b07787ef45cfc2eb04a3"},{"url":"https://git.kernel.org/stable/c/32f8d033044693f77f98da40ab206e38108cde6f"},{"url":"https://git.kernel.org/stable/c/ad3d6fe9772e06b50082d91e5906aa21ed2cb4ac"},{"url":"https://git.kernel.org/stable/c/d29c91e8c031bc9b5a78dc199235893c040877db"},{"url":"https://git.kernel.org/stable/c/d7106132b69e6916762bbbfd95fbcb60be4b8d9b"},{"url":"https://git.kernel.org/stable/c/58e39f8d58b141b96c030008a20dde9d625ec997"}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-12-03T09:22:13.623Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.18","versionEndExcluding":"5.10.276"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.18","versionEndExcluding":"5.15.227"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.18","versionEndExcluding":"6.12.120"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.18","versionEndExcluding":"6.18.66"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.18","versionEndExcluding":"7.3.7"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.18","versionEndExcluding":"7.4-rc2"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}