diff options
| -rw-r--r-- | meta-oe/recipes-extended/dlt-daemon/dlt-daemon/0001-Fix-memory-leak.patch | 34 | ||||
| -rw-r--r-- | meta-oe/recipes-extended/dlt-daemon/dlt-daemon_2.18.8.bb | 1 |
2 files changed, 35 insertions, 0 deletions
diff --git a/meta-oe/recipes-extended/dlt-daemon/dlt-daemon/0001-Fix-memory-leak.patch b/meta-oe/recipes-extended/dlt-daemon/dlt-daemon/0001-Fix-memory-leak.patch new file mode 100644 index 0000000000..72e3b9802d --- /dev/null +++ b/meta-oe/recipes-extended/dlt-daemon/dlt-daemon/0001-Fix-memory-leak.patch | |||
| @@ -0,0 +1,34 @@ | |||
| 1 | From b6149e203f919c899fefc702a17fbb78bdec3700 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Le Van Khanh <Khanh.LeVan@vn.bosch.com> | ||
| 3 | Date: Thu, 9 Feb 2023 03:17:13 -0500 | ||
| 4 | Subject: [PATCH] Fix memory leak | ||
| 5 | |||
| 6 | Free the ecuid_conf in case of memory alllocated | ||
| 7 | |||
| 8 | CVE: CVE-2023-26257 | ||
| 9 | |||
| 10 | Upstream-Status: Backport | ||
| 11 | [https://github.com/COVESA/dlt-daemon/pull/441/commits/b6149e203f919c899fefc702a17fbb78bdec3700] | ||
| 12 | |||
| 13 | Signed-off-by: Le Van Khanh <Khanh.LeVan@vn.bosch.com> | ||
| 14 | |||
| 15 | Signed-off-by: Yogita Urade <yogita.urade@windriver.com> | ||
| 16 | --- | ||
| 17 | src/console/dlt-control-common.c | 2 ++ | ||
| 18 | 1 file changed, 2 insertions(+) | ||
| 19 | |||
| 20 | diff --git a/src/console/dlt-control-common.c b/src/console/dlt-control-common.c | ||
| 21 | index abcaf92..64951c1 100644 | ||
| 22 | --- a/src/console/dlt-control-common.c | ||
| 23 | +++ b/src/console/dlt-control-common.c | ||
| 24 | @@ -124,6 +124,8 @@ void set_ecuid(char *ecuid) | ||
| 25 | if (dlt_parse_config_param("ECUId", &ecuid_conf) == 0) { | ||
| 26 | memset(local_ecuid, 0, DLT_CTRL_ECUID_LEN); | ||
| 27 | strncpy(local_ecuid, ecuid_conf, DLT_CTRL_ECUID_LEN); | ||
| 28 | + if (ecuid_conf !=NULL) | ||
| 29 | + free(ecuid_conf); | ||
| 30 | local_ecuid[DLT_CTRL_ECUID_LEN - 1] = '\0'; | ||
| 31 | } | ||
| 32 | else { | ||
| 33 | -- | ||
| 34 | 2.34.1 | ||
diff --git a/meta-oe/recipes-extended/dlt-daemon/dlt-daemon_2.18.8.bb b/meta-oe/recipes-extended/dlt-daemon/dlt-daemon_2.18.8.bb index aa5ef46a9d..cfbe0ff60d 100644 --- a/meta-oe/recipes-extended/dlt-daemon/dlt-daemon_2.18.8.bb +++ b/meta-oe/recipes-extended/dlt-daemon/dlt-daemon_2.18.8.bb | |||
| @@ -19,6 +19,7 @@ SRC_URI = "git://github.com/GENIVI/${BPN}.git;protocol=https;branch=master \ | |||
| 19 | file://0004-Modify-systemd-config-directory.patch \ | 19 | file://0004-Modify-systemd-config-directory.patch \ |
| 20 | file://0001-cmake-Link-with-libatomic-on-rv32-rv64.patch \ | 20 | file://0001-cmake-Link-with-libatomic-on-rv32-rv64.patch \ |
| 21 | file://0001-dlt-system-Fix-buffer-overflow-detection-on-32bit-ta.patch \ | 21 | file://0001-dlt-system-Fix-buffer-overflow-detection-on-32bit-ta.patch \ |
| 22 | file://0001-Fix-memory-leak.patch \ | ||
| 22 | " | 23 | " |
| 23 | SRCREV = "6a3bd901d825c7206797e36ea98e10a218f5aad2" | 24 | SRCREV = "6a3bd901d825c7206797e36ea98e10a218f5aad2" |
| 24 | 25 | ||
