Skip to content

Commit

Permalink
feat(checker): add dlt-daemon
Browse files Browse the repository at this point in the history
Fix #4457

Signed-off-by: Fabrice Fontaine <[email protected]>
  • Loading branch information
ffontaine committed Oct 20, 2024
1 parent 2b15bc5 commit 6814bb6
Show file tree
Hide file tree
Showing 5 changed files with 43 additions and 0 deletions.
1 change: 1 addition & 0 deletions cve_bin_tool/checkers/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@
"dhclient",
"dhcpcd",
"dhcpd",
"dlt_daemon",
"dmidecode",
"dnsmasq",
"docker",
Expand Down
22 changes: 22 additions & 0 deletions cve_bin_tool/checkers/dlt_daemon.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Copyright (C) 2024 Orange
# SPDX-License-Identifier: GPL-3.0-or-later


"""
CVE checker for dlt-daemon
https://www.cvedetails.com/product/136117/Covesa-Dlt-daemon.html?vendor_id=29885
"""
from __future__ import annotations

from cve_bin_tool.checkers import Checker


class DltDaemonChecker(Checker):
CONTAINS_PATTERNS: list[str] = []
FILENAME_PATTERNS: list[str] = []
VERSION_PATTERNS = [
r"([0-9]+\.[0-9]+\.[0-9]+)[A-Za-z0-9+_:%(), \[\]\.\-\r\n]*DLT[ _]"
]
VENDOR_PRODUCT = [("covesa", "dlt-daemon")]
Binary file not shown.
Binary file not shown.
20 changes: 20 additions & 0 deletions test/test_data/dlt_daemon.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Copyright (C) 2024 Orange
# SPDX-License-Identifier: GPL-3.0-or-later

mapping_test_data = [
{"product": "dlt-daemon", "version": "2.18.0", "version_strings": ["2.18.0\nDLT "]}
]
package_test_data = [
{
"url": "http://ftp.debian.org/debian/pool/main/d/dlt-daemon/",
"package_name": "dlt-daemon_2.18.0-1_amd64.deb",
"product": "dlt-daemon",
"version": "2.18.0",
},
{
"url": "http://ftp.debian.org/debian/pool/main/d/dlt-daemon/",
"package_name": "dlt-daemon_2.18.8-6_arm64.deb",
"product": "dlt-daemon",
"version": "2.18.8",
},
]

0 comments on commit 6814bb6

Please sign in to comment.