kumquat-buildroot/support
Titouan Christophe a35f51cee1 support/scripts/pkg-stats: iterate over CVEs in streaming
The NVD files that are used to build the list of CVEs affecting
Buildroot packages are quite large (a few hundreds MB of json),
and cause the pkg-stats scripts to have a huge memory footprint
(a few GB with Python 2.7).

However, because we only need to iterate on CVE items one by one,
we can process them in streaming (ie decoding one CVE at a time
from the JSON representation). Because the json module from the
python standard library does not support such a mode of operation,
we switch to the third-party package ijson, which is compatible
with both Python 2 and Python3.

To run the script with these modifications, one should install
the ijson python package. This can be done with pip:
`pip install ijson`. On Debian based distributions, this can
also be done with the apt package manager:
`apt install python-ijson`.

Signed-off-by: Titouan Christophe <titouan.christophe@railnova.eu>
Reviewed-by: Thomas De Schampheleire <thomas.de_schampheleire@nokia.com>
Tested-by: Thomas De Schampheleire <thomas.de_schampheleire@nokia.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2020-02-24 22:22:58 +01:00
..
config-fragments support/config-fragments/autobuild: fix riscv toolchains 2020-01-02 09:15:43 +01:00
dependencies core/dependencies: check if we need to build our own host-coreutils 2020-01-06 21:43:38 +01:00
docker support/docker: add python3 2019-10-27 20:24:10 +01:00
download support/download/svn: generate reproducible svn archives 2019-12-30 10:50:21 +01:00
gnuconfig
kconfig
legal-info core/legal-info: update list of saved material in README 2020-01-18 18:38:42 +01:00
libtool
misc Update for 2019.11 2019-12-01 22:39:47 +01:00
scripts support/scripts/pkg-stats: iterate over CVEs in streaming 2020-02-24 22:22:58 +01:00
testing support/run-tests: reorder imports 2020-02-17 10:13:08 +01:00