diff mbox series

[3/4] improve_kernel_cve_report: update data if CVE exists

Message ID 20260204134235.3274889-3-daniel.turull@ericsson.com
State Under Review
Headers show
Series [1/4] improve_kernel_cve_report: sort kernel_compiled_files | expand

Commit Message

Daniel Turull Feb. 4, 2026, 1:42 p.m. UTC
From: Daniel Turull <daniel.turull@ericsson.com>

This allow to include additional information if one of the
sources is more complete. Updating description with more
up to date information and including summary.

For example:

Before while using cve_check:

       {
          "id": "CVE-2025-68167",
          "status": "Patched",
          "link": "https://nvd.nist.gov/vuln/detail/CVE-2025-68167",
          "detail": "fixed-version",
          "description": "Fixed from version 6.18"
        },

After:
        {
          "id": "CVE-2025-68167",
          "status": "Patched",
          "link": "https://nvd.nist.gov/vuln/detail/CVE-2025-68167",
          "detail": "fixed-version",
          "description": "Fixed from version 6.18",
          "summary": "In the Linux kernel, the following (...)"
        },

Signed-off-by: Daniel Turull <daniel.turull@ericsson.com>
---
 scripts/contrib/improve_kernel_cve_report.py | 1 +
 1 file changed, 1 insertion(+)
diff mbox series

Patch

diff --git a/scripts/contrib/improve_kernel_cve_report.py b/scripts/contrib/improve_kernel_cve_report.py
index 50d25b2239..903de0000c 100755
--- a/scripts/contrib/improve_kernel_cve_report.py
+++ b/scripts/contrib/improve_kernel_cve_report.py
@@ -358,6 +358,7 @@  def cve_update(cve_data, cve, entry):
         cve_data[cve] = copy_data(cve_data[cve], entry)
         return
     if cve_data[cve]['status'] == entry['status']:
+        cve_data[cve] = copy_data(cve_data[cve], entry)
         return
     if entry['status'] == "Unpatched" and cve_data[cve]['status'] == "Patched":
         # Backported-patch (e.g. vendor kernel repo with cherry-picked CVE patch)