@@ -363,7 +363,7 @@ def cve_update(cve_data, cve, entry):
if entry['status'] == "Unpatched" and cve_data[cve]['status'] == "Patched":
# Backported-patch (e.g. vendor kernel repo with cherry-picked CVE patch)
# has priority over unpatch from CNA
- if "detail" in cve_data and cve_data[cve]['detail'] == "backported-patch":
+ if cve_data[cve].get('detail') == "backported-patch":
return
logging.warning("CVE entry %s update from Patched to Unpatched from the scan result", cve)
cve_data[cve] = copy_data(cve_data[cve], entry)
@@ -382,7 +382,7 @@ def cve_update(cve_data, cve, entry):
logging.debug("CVE entry %s updated from Unpatched to Ignored", cve)
return
logging.warning("Unhandled CVE entry update for %s %s from %s %s to %s",
- cve, cve_data[cve]['status'], cve_data[cve]['detail'], entry['status'], entry['detail'])
+ cve, cve_data[cve]['status'], cve_data[cve].get('detail'), entry['status'], entry['detail'])
def main():
parser = argparse.ArgumentParser(