summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGianfranco Costamagna <costamagna.gianfranco@gmail.com>2021-01-09 18:15:46 +0100
committerArmin Kuster <akuster808@gmail.com>2021-09-05 09:52:53 -0700
commit3d6a451571c584340b7a49c09d8602f83ecaae7f (patch)
tree8115cd8ba333f1a2914eb41ce15e412bcfdcec9c
parent5d6945d7807bcb638bf571c607f4d9369cb5ab46 (diff)
downloadmeta-openembedded-3d6a451571c584340b7a49c09d8602f83ecaae7f.tar.gz
dlt-daemon: update to new release 2.18.6
- drop patches 241 245 275: upstream Signed-off-by: Gianfranco Costamagna <costamagnagianfranco@yahoo.it> Signed-off-by: Gianfranco Costamagna <locutusofborg@debian.org> Signed-off-by: Khem Raj <raj.khem@gmail.com> Stable version, bug fix only] (cherry picked from commit 8c17cac68473f98e663f05bc08b7505c0529e495) [ Stable version, bug fix only Fixup for Dunfell context] Signed-off-by: Scott Murray <scott.murray@konsulko.com> Signed-off-by: Armin Kuster <akuster808@gmail.com>
-rw-r--r--meta-oe/recipes-extended/dlt-daemon/dlt-daemon/241.patch30
-rw-r--r--meta-oe/recipes-extended/dlt-daemon/dlt-daemon/245.patch74
-rw-r--r--meta-oe/recipes-extended/dlt-daemon/dlt-daemon/275.patch38
-rw-r--r--meta-oe/recipes-extended/dlt-daemon/dlt-daemon_2.18.6.bb (renamed from meta-oe/recipes-extended/dlt-daemon/dlt-daemon_2.18.5.bb)5
4 files changed, 1 insertions, 146 deletions
diff --git a/meta-oe/recipes-extended/dlt-daemon/dlt-daemon/241.patch b/meta-oe/recipes-extended/dlt-daemon/dlt-daemon/241.patch
deleted file mode 100644
index 7d8f22ec7..000000000
--- a/meta-oe/recipes-extended/dlt-daemon/dlt-daemon/241.patch
+++ /dev/null
@@ -1,30 +0,0 @@
1From b8f9919f000e642fc8970d0a42c1bdadf5a9d720 Mon Sep 17 00:00:00 2001
2From: Gianfranco Costamagna <costamagnagianfranco@yahoo.it>
3Date: Mon, 10 Aug 2020 08:30:34 +0200
4Subject: [PATCH] sd-daemon.c: Fix build with newer glibc and musl libc
5
6Reported by Khem Raj on meta-oe list
7
8TOPDIR/build/tmp/work/armv7vet2hf-neon-yoe-linux-musleabi/dlt-daemon/2.18.5-r0/recipe-sysroot/usr/include/sys/fcntl.h:1:2: error: redirecting incorrect #include <sys/fcntl.h> to <fcntl.h> [-Werror,-W#warnings]
9 ^
101 error generated.
11
12Signed-off-by: Gianfranco Costamagna <costamagnagianfranco@yahoo.it>
13Signed-off-by: Gianfranco Costamagna <locutusofborg@debian.org>
14---
15 systemd/3rdparty/sd-daemon.c | 2 +-
16 1 file changed, 1 insertion(+), 1 deletion(-)
17
18diff --git a/systemd/3rdparty/sd-daemon.c b/systemd/3rdparty/sd-daemon.c
19index 88936d2..de3f985 100644
20--- a/systemd/3rdparty/sd-daemon.c
21+++ b/systemd/3rdparty/sd-daemon.c
22@@ -35,7 +35,7 @@
23 #ifdef __BIONIC__
24 #include <linux/fcntl.h>
25 #else
26-#include <sys/fcntl.h>
27+#include <fcntl.h>
28 #endif
29 #include <netinet/in.h>
30 #include <stdlib.h>
diff --git a/meta-oe/recipes-extended/dlt-daemon/dlt-daemon/245.patch b/meta-oe/recipes-extended/dlt-daemon/dlt-daemon/245.patch
deleted file mode 100644
index 43057489c..000000000
--- a/meta-oe/recipes-extended/dlt-daemon/dlt-daemon/245.patch
+++ /dev/null
@@ -1,74 +0,0 @@
1From 57fd61ea5c58a4f9fcd7140b53ac6cd6e971ef47 Mon Sep 17 00:00:00 2001
2From: Gianfranco Costamagna <costamagnagianfranco@yahoo.it>
3Date: Fri, 31 Jul 2020 15:16:02 +0200
4Subject: [PATCH] dlt_offline: fix build failures with gcc-10
5
6see bug report: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=957140
7
8/usr/bin/ld: CMakeFiles/dlt-daemon.dir/dlt_daemon_client.c.o:./obj-x86_64-linux-gnu/src/daemon/./src/offlinelogstorage/dlt_offline_logstorage.h:116: multiple definition of `g_logstorage_cache_max'; CMakeFiles/dlt-daemon.dir/dlt-daemon.c.o:./obj-x86_64-linux-gnu/src/daemon/./src/offlinelogstorage/dlt_offline_logstorage.h:116: first defined here
9/usr/bin/ld: CMakeFiles/dlt-daemon.dir/dlt_daemon_common.c.o:./obj-x86_64-linux-gnu/src/daemon/./src/offlinelogstorage/dlt_offline_logstorage.h:118: multiple definition of `g_logstorage_cache_size'; CMakeFiles/dlt-daemon.dir/dlt-daemon.c.o:./obj-x86_64-linux-gnu/src/daemon/./src/offlinelogstorage/dlt_offline_logstorage.h:118: first defined here
10/usr/bin/ld: CMakeFiles/dlt-daemon.dir/dlt_daemon_common.c.o:./obj-x86_64-linux-gnu/src/daemon/./src/offlinelogstorage/dlt_offline_logstorage.h:116: multiple definition of `g_logstorage_cache_max'; CMakeFiles/dlt-daemon.dir/dlt-daemon.c.o:./obj-x86_64-linux-gnu/src/daemon/./src/offlinelogstorage/dlt_offline_logstorage.h:116: first defined here
11/usr/bin/ld: CMakeFiles/dlt-daemon.dir/dlt_daemon_connection.c.o:./obj-x86_64-linux-gnu/src/daemon/./src/offlinelogstorage/dlt_offline_logstorage.h:118: multiple definition of `g_logstorage_cache_size'; CMakeFiles/dlt-daemon.dir/dlt-daemon.c.o:./obj-x86_64-linux-gnu/src/daemon/./src/offlinelogstorage/dlt_offline_logstorage.h:118: first defined here
12/usr/bin/ld: CMakeFiles/dlt-daemon.dir/dlt_daemon_connection.c.o:./obj-x86_64-linux-gnu/src/daemon/./src/offlinelogstorage/dlt_offline_logstorage.h:116: multiple definition of `g_logstorage_cache_max'; CMakeFiles/dlt-daemon.dir/dlt-daemon.c.o:./obj-x86_64-linux-gnu/src/daemon/./src/offlinelogstorage/dlt_offline_logstorage.h:116: first defined here
13/usr/bin/ld: CMakeFiles/dlt-daemon.dir/dlt_daemon_event_handler.c.o:./obj-x86_64-linux-gnu/src/daemon/./src/offlinelogstorage/dlt_offline_logstorage.h:118: multiple definition of `g_logstorage_cache_size'; CMakeFiles/dlt-daemon.dir/dlt-daemon.c.o:./obj-x86_64-linux-gnu/src/daemon/./src/offlinelogstorage/dlt_offline_logstorage.h:118: first defined here
14/usr/bin/ld: CMakeFiles/dlt-daemon.dir/dlt_daemon_event_handler.c.o:./obj-x86_64-linux-gnu/src/daemon/./src/offlinelogstorage/dlt_offline_logstorage.h:116: multiple definition of `g_logstorage_cache_max'; CMakeFiles/dlt-daemon.dir/dlt-daemon.c.o:./obj-x86_64-linux-gnu/src/daemon/./src/offlinelogstorage/dlt_offline_logstorage.h:116: first defined here
15/usr/bin/ld: CMakeFiles/dlt-daemon.dir/dlt_daemon_offline_logstorage.c.o:./obj-x86_64-linux-gnu/src/daemon/./src/offlinelogstorage/dlt_offline_logstorage.h:116: multiple definition of `g_logstorage_cache_max'; CMakeFiles/dlt-daemon.dir/dlt-daemon.c.o:./obj-x86_64-linux-gnu/src/daemon/./src/offlinelogstorage/dlt_offline_logstorage.h:116: first defined here
16---
17 src/daemon/dlt_daemon_offline_logstorage.c | 1 +
18 src/offlinelogstorage/dlt_offline_logstorage.h | 4 ++--
19 src/offlinelogstorage/dlt_offline_logstorage_behavior.c | 1 +
20 tests/gtest_dlt_daemon_offline_log.cpp | 1 +
21 4 files changed, 5 insertions(+), 2 deletions(-)
22
23diff --git a/src/daemon/dlt_daemon_offline_logstorage.c b/src/daemon/dlt_daemon_offline_logstorage.c
24index 0b3c14f..db9637e 100644
25--- a/src/daemon/dlt_daemon_offline_logstorage.c
26+++ b/src/daemon/dlt_daemon_offline_logstorage.c
27@@ -56,6 +56,7 @@ DLT_STATIC DltReturnValue dlt_logstorage_split_ecuid(char *key,
28 return DLT_RETURN_OK;
29 }
30
31+unsigned int g_logstorage_cache_max;
32 /**
33 * dlt_logstorage_split_ctid
34 *
35diff --git a/src/offlinelogstorage/dlt_offline_logstorage.h b/src/offlinelogstorage/dlt_offline_logstorage.h
36index b58da70..c9bc93b 100644
37--- a/src/offlinelogstorage/dlt_offline_logstorage.h
38+++ b/src/offlinelogstorage/dlt_offline_logstorage.h
39@@ -114,9 +114,9 @@
40 #define DLT_OFFLINE_LOGSTORAGE_IS_STRATEGY_SET(S, s) ((S)&(s))
41
42 /* logstorage max cache */
43-unsigned int g_logstorage_cache_max;
44+extern unsigned int g_logstorage_cache_max;
45 /* current logstorage cache size */
46-unsigned int g_logstorage_cache_size;
47+extern unsigned int g_logstorage_cache_size;
48
49 typedef struct
50 {
51diff --git a/src/offlinelogstorage/dlt_offline_logstorage_behavior.c b/src/offlinelogstorage/dlt_offline_logstorage_behavior.c
52index afbf8c4..edef482 100644
53--- a/src/offlinelogstorage/dlt_offline_logstorage_behavior.c
54+++ b/src/offlinelogstorage/dlt_offline_logstorage_behavior.c
55@@ -32,6 +32,7 @@
56 #include "dlt_offline_logstorage_behavior.h"
57 #include "dlt_offline_logstorage_behavior_internal.h"
58
59+unsigned int g_logstorage_cache_size;
60 /**
61 * dlt_logstorage_log_file_name
62 *
63diff --git a/tests/gtest_dlt_daemon_offline_log.cpp b/tests/gtest_dlt_daemon_offline_log.cpp
64index b8965de..0bd4d5e 100644
65--- a/tests/gtest_dlt_daemon_offline_log.cpp
66+++ b/tests/gtest_dlt_daemon_offline_log.cpp
67@@ -29,6 +29,7 @@ extern "C"
68 #include <fcntl.h>
69 }
70
71+unsigned int g_logstorage_cache_max;
72 /* Begin Method: dlt_logstorage::t_dlt_logstorage_list_add*/
73 TEST(t_dlt_logstorage_list_add, normal)
74 {
diff --git a/meta-oe/recipes-extended/dlt-daemon/dlt-daemon/275.patch b/meta-oe/recipes-extended/dlt-daemon/dlt-daemon/275.patch
deleted file mode 100644
index 75065eb05..000000000
--- a/meta-oe/recipes-extended/dlt-daemon/dlt-daemon/275.patch
+++ /dev/null
@@ -1,38 +0,0 @@
1Upstream-status: Backport
2CVE: CVE-2020-29394
3From 7f5cd5404a03fa330e192084f6bdafb2dc9bdcb7 Mon Sep 17 00:00:00 2001
4From: GwanYeong Kim <gy741.kim@gmail.com>
5Date: Sat, 28 Nov 2020 12:24:46 +0900
6Subject: [PATCH] dlt_common: Fix buffer overflow in dlt_filter_load
7
8A buffer overflow in the dlt_filter_load function in dlt_common.c in dlt-daemon allows arbitrary code execution via an unsafe usage of fscanf, because it does not limit the number of characters to be read in a format argument.
9
10Fixed: #274
11
12Signed-off-by: GwanYeong Kim <gy741.kim@gmail.com>
13---
14 src/shared/dlt_common.c | 4 ++--
15 1 file changed, 2 insertions(+), 2 deletions(-)
16
17diff --git a/src/shared/dlt_common.c b/src/shared/dlt_common.c
18index 254f4ce4..d15b1cec 100644
19--- a/src/shared/dlt_common.c
20+++ b/src/shared/dlt_common.c
21@@ -404,7 +404,7 @@ DltReturnValue dlt_filter_load(DltFilter *filter, const char *filename, int verb
22 while (!feof(handle)) {
23 str1[0] = 0;
24
25- if (fscanf(handle, "%s", str1) != 1)
26+ if (fscanf(handle, "%254s", str1) != 1)
27 break;
28
29 if (str1[0] == 0)
30@@ -419,7 +419,7 @@ DltReturnValue dlt_filter_load(DltFilter *filter, const char *filename, int verb
31
32 str1[0] = 0;
33
34- if (fscanf(handle, "%s", str1) != 1)
35+ if (fscanf(handle, "%254s", str1) != 1)
36 break;
37
38 if (str1[0] == 0)
diff --git a/meta-oe/recipes-extended/dlt-daemon/dlt-daemon_2.18.5.bb b/meta-oe/recipes-extended/dlt-daemon/dlt-daemon_2.18.6.bb
index c0b1750e0..b7a6cdaa2 100644
--- a/meta-oe/recipes-extended/dlt-daemon/dlt-daemon_2.18.5.bb
+++ b/meta-oe/recipes-extended/dlt-daemon/dlt-daemon_2.18.6.bb
@@ -17,11 +17,8 @@ DEPENDS = "zlib gzip-native"
17SRC_URI = "git://github.com/GENIVI/${BPN}.git;protocol=https \ 17SRC_URI = "git://github.com/GENIVI/${BPN}.git;protocol=https \
18 file://0002-Don-t-execute-processes-as-a-specific-user.patch \ 18 file://0002-Don-t-execute-processes-as-a-specific-user.patch \
19 file://0004-Modify-systemd-config-directory.patch \ 19 file://0004-Modify-systemd-config-directory.patch \
20 file://275.patch \
21 file://241.patch \
22 file://245.patch \
23" 20"
24SRCREV = "f1ac087c766827b1d0ed9c3a814b3cc052e948f2" 21SRCREV = "22715aeceaa81ace2c832312529bde3a42d0814f"
25 22
26S = "${WORKDIR}/git" 23S = "${WORKDIR}/git"
27 24