mirror of
https://github.com/openembedded/meta-openembedded.git
synced 2026-07-15 16:07:26 +00:00
tcpdump: Fix patch-fuzz issue
Fix patch-fuzz for CVE-2024-2397.patch Signed-off-by: Sana Kazi <sanakazi720@gmail.com> Signed-off-by: Gyorgy Sarvari <skandigraun@gmail.com>
This commit is contained in:
committed by
Gyorgy Sarvari
parent
06fc0278f1
commit
a626bfdf31
@@ -1,4 +1,4 @@
|
|||||||
From b9811ef5bb1b7d45a90e042f81f3aaf233c8bcb2 Mon Sep 17 00:00:00 2001
|
From 732d375501d687812866da0602457109a2088254 Mon Sep 17 00:00:00 2001
|
||||||
From: Guy Harris <gharris@sonic.net>
|
From: Guy Harris <gharris@sonic.net>
|
||||||
Date: Tue, 12 Mar 2024 00:37:23 -0700
|
Date: Tue, 12 Mar 2024 00:37:23 -0700
|
||||||
Subject: [PATCH] ppp: use the buffer stack for the de-escaping buffer.
|
Subject: [PATCH] ppp: use the buffer stack for the de-escaping buffer.
|
||||||
@@ -29,20 +29,25 @@ Signed-off-by: Ashish Sharma <asharma@mvista.com>
|
|||||||
print.c | 8 ++++++--
|
print.c | 8 ++++++--
|
||||||
2 files changed, 23 insertions(+), 16 deletions(-)
|
2 files changed, 23 insertions(+), 16 deletions(-)
|
||||||
|
|
||||||
|
---
|
||||||
|
print-ppp.c | 31 +++++++++++++++++--------------
|
||||||
|
print.c | 8 ++++++--
|
||||||
|
2 files changed, 23 insertions(+), 16 deletions(-)
|
||||||
|
|
||||||
diff --git a/print-ppp.c b/print-ppp.c
|
diff --git a/print-ppp.c b/print-ppp.c
|
||||||
index 2cf06c363..9aed23eb9 100644
|
index aba243d..e5ae064 100644
|
||||||
--- a/print-ppp.c
|
--- a/print-ppp.c
|
||||||
+++ b/print-ppp.c
|
+++ b/print-ppp.c
|
||||||
@@ -37,6 +37,8 @@
|
@@ -42,6 +42,8 @@
|
||||||
|
#include <net/if_ppp.h>
|
||||||
#include "netdissect-stdinc.h"
|
#endif
|
||||||
|
|
||||||
+#include <stdlib.h>
|
+#include <stdlib.h>
|
||||||
+
|
+
|
||||||
#include "netdissect.h"
|
#include "netdissect.h"
|
||||||
#include "extract.h"
|
#include "extract.h"
|
||||||
#include "addrtoname.h"
|
#include "addrtoname.h"
|
||||||
@@ -1358,7 +1360,6 @@ ppp_hdlc(netdissect_options *ndo,
|
@@ -1363,7 +1365,6 @@ ppp_hdlc(netdissect_options *ndo,
|
||||||
u_char *b, *t, c;
|
u_char *b, *t, c;
|
||||||
const u_char *s;
|
const u_char *s;
|
||||||
u_int i, proto;
|
u_int i, proto;
|
||||||
@@ -50,7 +55,7 @@ index 2cf06c363..9aed23eb9 100644
|
|||||||
|
|
||||||
if (caplen == 0)
|
if (caplen == 0)
|
||||||
return;
|
return;
|
||||||
@@ -1366,9 +1367,11 @@ ppp_hdlc(netdissect_options *ndo,
|
@@ -1371,9 +1372,11 @@ ppp_hdlc(netdissect_options *ndo,
|
||||||
if (length == 0)
|
if (length == 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
@@ -65,7 +70,7 @@ index 2cf06c363..9aed23eb9 100644
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
* Unescape all the data into a temporary, private, buffer.
|
* Unescape all the data into a temporary, private, buffer.
|
||||||
@@ -1389,13 +1392,15 @@ ppp_hdlc(netdissect_options *ndo,
|
@@ -1394,13 +1397,15 @@ ppp_hdlc(netdissect_options *ndo,
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@@ -87,7 +92,7 @@ index 2cf06c363..9aed23eb9 100644
|
|||||||
length = ND_BYTES_AVAILABLE_AFTER(b);
|
length = ND_BYTES_AVAILABLE_AFTER(b);
|
||||||
|
|
||||||
/* now lets guess about the payload codepoint format */
|
/* now lets guess about the payload codepoint format */
|
||||||
@@ -1437,13 +1442,11 @@ ppp_hdlc(netdissect_options *ndo,
|
@@ -1442,13 +1447,11 @@ ppp_hdlc(netdissect_options *ndo,
|
||||||
}
|
}
|
||||||
|
|
||||||
cleanup:
|
cleanup:
|
||||||
@@ -104,7 +109,7 @@ index 2cf06c363..9aed23eb9 100644
|
|||||||
}
|
}
|
||||||
|
|
||||||
diff --git a/print.c b/print.c
|
diff --git a/print.c b/print.c
|
||||||
index b9ba5997d..f20633388 100644
|
index 9c0ab86..33706b9 100644
|
||||||
--- a/print.c
|
--- a/print.c
|
||||||
+++ b/print.c
|
+++ b/print.c
|
||||||
@@ -431,10 +431,14 @@ pretty_print_packet(netdissect_options *ndo, const struct pcap_pkthdr *h,
|
@@ -431,10 +431,14 @@ pretty_print_packet(netdissect_options *ndo, const struct pcap_pkthdr *h,
|
||||||
|
|||||||
Reference in New Issue
Block a user