Skip to content

Commit

Permalink
feat(checker): add libvpx checker
Browse files Browse the repository at this point in the history
Signed-off-by: Fabrice Fontaine <[email protected]>
  • Loading branch information
ffontaine committed Dec 14, 2023
1 parent 098a96f commit 69c327e
Show file tree
Hide file tree
Showing 6 changed files with 51 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 @@ -185,6 +185,7 @@
"libvirt",
"libvncserver",
"libvorbis",
"libvpx",
"libxslt",
"lighttpd",
"linux_kernel",
Expand Down
20 changes: 20 additions & 0 deletions cve_bin_tool/checkers/libvpx.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Copyright (C) 2023 Orange
# SPDX-License-Identifier: GPL-3.0-or-later


"""
CVE checker for libvpx
https://www.cvedetails.com/product/62243/Webmproject-Libvpx.html?vendor_id=17610
"""
from __future__ import annotations

from cve_bin_tool.checkers import Checker


class LibvpxChecker(Checker):
CONTAINS_PATTERNS: list[str] = []
FILENAME_PATTERNS: list[str] = []
VERSION_PATTERNS = [r"WebM Project VP[8|9] Encoder v([0-9]+\.[0-9]+\.[0-9]+)"]
VENDOR_PRODUCT = [("webmproject", "libvpx")]
Binary file not shown.
Binary file not shown.
Binary file not shown.
30 changes: 30 additions & 0 deletions test/test_data/libvpx.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Copyright (C) 2023 Orange
# SPDX-License-Identifier: GPL-3.0-or-later

mapping_test_data = [
{
"product": "libvpx",
"version": "1.7.0",
"version_strings": ["WebM Project VP8 Encoder v1.7.0"],
}
]
package_test_data = [
{
"url": "http://rpmfind.net/linux/fedora/linux/development/rawhide/Everything/aarch64/os/Packages/l/",
"package_name": "libvpx-1.13.1-1.fc40.aarch64.rpm",
"product": "libvpx",
"version": "1.13.1",
},
{
"url": "http://ftp.fr.debian.org/debian/pool/main/libv/libvpx/",
"package_name": "libvpx5_1.7.0-3+deb10u1_amd64.deb",
"product": "libvpx",
"version": "1.7.0",
},
{
"url": "https://downloads.openwrt.org/releases/packages-19.07/x86_64/packages/",
"package_name": "libvpx1.8_1.8.0-1_x86_64.ipk",
"product": "libvpx",
"version": "1.8.0",
},
]

0 comments on commit 69c327e

Please sign in to comment.