mirror of
https://gitlab.com/buildroot.org/buildroot.git
synced 2026-09-30 14:01:57 -09:00
support/scripts/pkg-stats: allow disabling CPE matching
This is useful when debugging/developing the pkg-stats script. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
This commit is contained in:
committed by
Yann E. MORIN
parent
2120113026
commit
cd8a576c6d
@@ -1125,7 +1125,7 @@ def parse_args():
|
|||||||
parser.add_argument('--nvd-path', dest='nvd_path',
|
parser.add_argument('--nvd-path', dest='nvd_path',
|
||||||
help='Path to the local NVD database', type=resolvepath)
|
help='Path to the local NVD database', type=resolvepath)
|
||||||
parser.add_argument('--disable', type=list_str,
|
parser.add_argument('--disable', type=list_str,
|
||||||
help='Features to disable, comma-separated (cve, upstream, url)',
|
help='Features to disable, comma-separated (cve, upstream, url, cpe)',
|
||||||
default=[])
|
default=[])
|
||||||
args = parser.parse_args()
|
args = parser.parse_args()
|
||||||
if not args.html and not args.json:
|
if not args.html and not args.json:
|
||||||
@@ -1184,6 +1184,8 @@ def __main__():
|
|||||||
if "cve" not in args.disable and args.nvd_path:
|
if "cve" not in args.disable and args.nvd_path:
|
||||||
print("Checking packages CVEs")
|
print("Checking packages CVEs")
|
||||||
check_package_cves(args.nvd_path, packages)
|
check_package_cves(args.nvd_path, packages)
|
||||||
|
if "cpe" not in args.disable and args.nvd_path:
|
||||||
|
print("Checking packages CPEs")
|
||||||
check_package_cpes(args.nvd_path, packages)
|
check_package_cpes(args.nvd_path, packages)
|
||||||
print("Calculate stats")
|
print("Calculate stats")
|
||||||
stats = calculate_stats(packages)
|
stats = calculate_stats(packages)
|
||||||
|
|||||||
Reference in New Issue
Block a user