Skip to content

Commit d69492f

Browse files
committed
feat(checker): add wavpack checker
Signed-off-by: Fabrice Fontaine <[email protected]>
1 parent 3029cb0 commit d69492f

File tree

6 files changed

+48
-0
lines changed

6 files changed

+48
-0
lines changed

cve_bin_tool/checkers/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -376,6 +376,7 @@
376376
"vorbis_tools",
377377
"vsftpd",
378378
"vim",
379+
"wavpack",
379380
"webkitgtk",
380381
"wget",
381382
"wireshark",

cve_bin_tool/checkers/wavpack.py

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Copyright (C) 2025 Orange
2+
# SPDX-License-Identifier: GPL-3.0-or-later
3+
4+
5+
"""
6+
CVE checker for wavpack
7+
8+
https://www.cvedetails.com/product/36196/Wavpack-Project-Wavpack.html?vendor_id=16200
9+
https://www.cvedetails.com/product/43617/Wavpack-Wavpack.html?vendor_id=17637
10+
11+
"""
12+
from __future__ import annotations
13+
14+
from cve_bin_tool.checkers import Checker
15+
16+
17+
class WavpackChecker(Checker):
18+
CONTAINS_PATTERNS: list[str] = []
19+
FILENAME_PATTERNS: list[str] = []
20+
VERSION_PATTERNS = [r"([0-9]+\.[0-9]+\.[0-9]+)\r?\n(?:libwavpack|[wW]av)"]
21+
VENDOR_PRODUCT = [("wavpack", "wavpack"), ("wavpack_project", "wavpack")]
Binary file not shown.
Binary file not shown.
Binary file not shown.

test/test_data/wavpack.py

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# Copyright (C) 2025 Orange
2+
# SPDX-License-Identifier: GPL-3.0-or-later
3+
4+
mapping_test_data = [
5+
{"product": "wavpack", "version": "5.1.0", "version_strings": ["5.1.0\nlibwavpack"]}
6+
]
7+
package_test_data = [
8+
{
9+
"url": "http://rpmfind.net/linux/fedora/linux/development/rawhide/Everything/aarch64/os/Packages/w/",
10+
"package_name": "wavpack-5.7.0-11.fc42.aarch64.rpm",
11+
"product": "wavpack",
12+
"version": "5.7.0",
13+
},
14+
{
15+
"url": "http://ftp.debian.org/debian/pool/main/w/wavpack/",
16+
"package_name": "wavpack_5.4.0-1_arm64.deb",
17+
"product": "wavpack",
18+
"version": "5.4.0",
19+
},
20+
{
21+
"url": "https://dl-cdn.alpinelinux.org/alpine/v3.11/main/x86_64/",
22+
"package_name": "wavpack-5.1.0-r8.apk",
23+
"product": "wavpack",
24+
"version": "5.1.0",
25+
},
26+
]

0 commit comments

Comments
 (0)