From: Sasha Levin Date: Thu, 23 Feb 2023 12:12:33 +0000 (-0500) Subject: Drop netfilter-conntrack-fix-bug-in-for_each_sctp_chunk.patch X-Git-Tag: v6.2.1~13 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=8564a575b95d4a7fa3dbf60f6525564c89083acd;p=thirdparty%2Fkernel%2Fstable-queue.git Drop netfilter-conntrack-fix-bug-in-for_each_sctp_chunk.patch Signed-off-by: Sasha Levin --- diff --git a/queue-4.14/netfilter-conntrack-fix-bug-in-for_each_sctp_chunk.patch b/queue-4.14/netfilter-conntrack-fix-bug-in-for_each_sctp_chunk.patch deleted file mode 100644 index ce6f037d4f1..00000000000 --- a/queue-4.14/netfilter-conntrack-fix-bug-in-for_each_sctp_chunk.patch +++ /dev/null @@ -1,42 +0,0 @@ -From dae6a918ba118f0d180f0d71922b235a1cc16eb6 Mon Sep 17 00:00:00 2001 -From: Sasha Levin -Date: Tue, 24 Jan 2023 02:47:19 +0100 -Subject: netfilter: conntrack: fix bug in for_each_sctp_chunk - -From: Sriram Yagnaraman - -[ Upstream commit 98ee0077452527f971567db01386de3c3d97ce13 ] - -skb_header_pointer() will return NULL if offset + sizeof(_sch) exceeds -skb->len, so this offset < skb->len test is redundant. - -if sch->length == 0, this will end up in an infinite loop, add a check -for sch->length > 0 - -Fixes: 9fb9cbb1082d ("[NETFILTER]: Add nf_conntrack subsystem.") -Suggested-by: Florian Westphal -Signed-off-by: Sriram Yagnaraman -Signed-off-by: Pablo Neira Ayuso -Signed-off-by: Sasha Levin ---- - net/netfilter/nf_conntrack_proto_sctp.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/net/netfilter/nf_conntrack_proto_sctp.c b/net/netfilter/nf_conntrack_proto_sctp.c -index 1278b27c625ab..cffd37f56c5c0 100644 ---- a/net/netfilter/nf_conntrack_proto_sctp.c -+++ b/net/netfilter/nf_conntrack_proto_sctp.c -@@ -184,8 +184,8 @@ static void sctp_print_conntrack(struct seq_file *s, struct nf_conn *ct) - - #define for_each_sctp_chunk(skb, sch, _sch, offset, dataoff, count) \ - for ((offset) = (dataoff) + sizeof(struct sctphdr), (count) = 0; \ -- (offset) < (skb)->len && \ -- ((sch) = skb_header_pointer((skb), (offset), sizeof(_sch), &(_sch))); \ -+ ((sch) = skb_header_pointer((skb), (offset), sizeof(_sch), &(_sch))) && \ -+ (sch)->length; \ - (offset) += (ntohs((sch)->length) + 3) & ~3, (count)++) - - /* Some validity checks to make sure the chunks are fine */ --- -2.39.0 - diff --git a/queue-4.14/series b/queue-4.14/series index 288a4a0f2bc..bad3505fdd0 100644 --- a/queue-4.14/series +++ b/queue-4.14/series @@ -2,7 +2,6 @@ wifi-rtl8xxxu-gen2-turn-on-the-rate-control.patch powerpc-dts-t208x-mark-mac1-and-mac2-as-10g.patch random-always-mix-cycle-counter-in-add_latent_entrop.patch powerpc-dts-t208x-disable-10g-on-mac1-and-mac2.patch -netfilter-conntrack-fix-bug-in-for_each_sctp_chunk.patch revert-netfilter-conntrack-fix-bug-in-for_each_sctp_.patch alarmtimer-prevent-starvation-by-small-intervals-and-sig_ign.patch uaccess-add-speculation-barrier-to-copy_from_user.patch diff --git a/queue-5.15/netfilter-conntrack-fix-bug-in-for_each_sctp_chunk.patch b/queue-5.15/netfilter-conntrack-fix-bug-in-for_each_sctp_chunk.patch deleted file mode 100644 index 5ba835f241a..00000000000 --- a/queue-5.15/netfilter-conntrack-fix-bug-in-for_each_sctp_chunk.patch +++ /dev/null @@ -1,42 +0,0 @@ -From a55ccf8f2aa2952cd462a6cf61709221f32636e9 Mon Sep 17 00:00:00 2001 -From: Sasha Levin -Date: Tue, 24 Jan 2023 02:47:19 +0100 -Subject: netfilter: conntrack: fix bug in for_each_sctp_chunk - -From: Sriram Yagnaraman - -[ Upstream commit 98ee0077452527f971567db01386de3c3d97ce13 ] - -skb_header_pointer() will return NULL if offset + sizeof(_sch) exceeds -skb->len, so this offset < skb->len test is redundant. - -if sch->length == 0, this will end up in an infinite loop, add a check -for sch->length > 0 - -Fixes: 9fb9cbb1082d ("[NETFILTER]: Add nf_conntrack subsystem.") -Suggested-by: Florian Westphal -Signed-off-by: Sriram Yagnaraman -Signed-off-by: Pablo Neira Ayuso -Signed-off-by: Sasha Levin ---- - net/netfilter/nf_conntrack_proto_sctp.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/net/netfilter/nf_conntrack_proto_sctp.c b/net/netfilter/nf_conntrack_proto_sctp.c -index 895e0ca542994..444f02271b36a 100644 ---- a/net/netfilter/nf_conntrack_proto_sctp.c -+++ b/net/netfilter/nf_conntrack_proto_sctp.c -@@ -144,8 +144,8 @@ static void sctp_print_conntrack(struct seq_file *s, struct nf_conn *ct) - - #define for_each_sctp_chunk(skb, sch, _sch, offset, dataoff, count) \ - for ((offset) = (dataoff) + sizeof(struct sctphdr), (count) = 0; \ -- (offset) < (skb)->len && \ -- ((sch) = skb_header_pointer((skb), (offset), sizeof(_sch), &(_sch))); \ -+ ((sch) = skb_header_pointer((skb), (offset), sizeof(_sch), &(_sch))) && \ -+ (sch)->length; \ - (offset) += (ntohs((sch)->length) + 3) & ~3, (count)++) - - /* Some validity checks to make sure the chunks are fine */ --- -2.39.0 - diff --git a/queue-5.15/series b/queue-5.15/series index 13780719d59..2313e466e6a 100644 --- a/queue-5.15/series +++ b/queue-5.15/series @@ -13,7 +13,6 @@ kvm-svm-skip-wrmsr-fastpath-on-vm-exit-if-next-rip-i.patch kvm-vmx-execute-ibpb-on-emulated-vm-exit-when-guest-.patch can-kvaser_usb-hydra-help-gcc-13-to-figure-out-cmd_l.patch powerpc-dts-t208x-disable-10g-on-mac1-and-mac2.patch -netfilter-conntrack-fix-bug-in-for_each_sctp_chunk.patch powerpc-use-generic-version-of-arch_is_kernel_initme.patch powerpc-vmlinux.lds-ensure-strict_align_size-is-at-l.patch powerpc-vmlinux.lds-add-an-explicit-symbol-for-the-s.patch diff --git a/queue-6.1/netfilter-conntrack-fix-bug-in-for_each_sctp_chunk.patch b/queue-6.1/netfilter-conntrack-fix-bug-in-for_each_sctp_chunk.patch deleted file mode 100644 index e9cd5c35c18..00000000000 --- a/queue-6.1/netfilter-conntrack-fix-bug-in-for_each_sctp_chunk.patch +++ /dev/null @@ -1,42 +0,0 @@ -From 943f7963ca9c3798552e70c6e1e5d69085a8b2fd Mon Sep 17 00:00:00 2001 -From: Sasha Levin -Date: Tue, 24 Jan 2023 02:47:19 +0100 -Subject: netfilter: conntrack: fix bug in for_each_sctp_chunk - -From: Sriram Yagnaraman - -[ Upstream commit 98ee0077452527f971567db01386de3c3d97ce13 ] - -skb_header_pointer() will return NULL if offset + sizeof(_sch) exceeds -skb->len, so this offset < skb->len test is redundant. - -if sch->length == 0, this will end up in an infinite loop, add a check -for sch->length > 0 - -Fixes: 9fb9cbb1082d ("[NETFILTER]: Add nf_conntrack subsystem.") -Suggested-by: Florian Westphal -Signed-off-by: Sriram Yagnaraman -Signed-off-by: Pablo Neira Ayuso -Signed-off-by: Sasha Levin ---- - net/netfilter/nf_conntrack_proto_sctp.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/net/netfilter/nf_conntrack_proto_sctp.c b/net/netfilter/nf_conntrack_proto_sctp.c -index 895e0ca542994..444f02271b36a 100644 ---- a/net/netfilter/nf_conntrack_proto_sctp.c -+++ b/net/netfilter/nf_conntrack_proto_sctp.c -@@ -144,8 +144,8 @@ static void sctp_print_conntrack(struct seq_file *s, struct nf_conn *ct) - - #define for_each_sctp_chunk(skb, sch, _sch, offset, dataoff, count) \ - for ((offset) = (dataoff) + sizeof(struct sctphdr), (count) = 0; \ -- (offset) < (skb)->len && \ -- ((sch) = skb_header_pointer((skb), (offset), sizeof(_sch), &(_sch))); \ -+ ((sch) = skb_header_pointer((skb), (offset), sizeof(_sch), &(_sch))) && \ -+ (sch)->length; \ - (offset) += (ntohs((sch)->length) + 3) & ~3, (count)++) - - /* Some validity checks to make sure the chunks are fine */ --- -2.39.0 - diff --git a/queue-6.1/series b/queue-6.1/series index baf1cf7e2a9..ffd4e19e0bb 100644 --- a/queue-6.1/series +++ b/queue-6.1/series @@ -23,7 +23,6 @@ spi-mediatek-enable-irq-before-the-spi-registration.patch drm-i915-remove-__maybe_unused-from-mtl_info.patch kvm-x86-fix-deadlock-for-kvm_xen_evtchn_reset.patch selftests-kvm-move-declaration-at-the-beginning-of-m.patch -netfilter-conntrack-fix-bug-in-for_each_sctp_chunk.patch powerpc-64s-radix-fix-rwx-mapping-with-relocated-ker.patch revert-netfilter-conntrack-fix-bug-in-for_each_sctp_.patch nfp-ethtool-support-reporting-link-modes.patch