diff --git a/lib4sbom/cyclonedx/cyclonedx_parser.py b/lib4sbom/cyclonedx/cyclonedx_parser.py index 76fed4c..8adb543 100644 --- a/lib4sbom/cyclonedx/cyclonedx_parser.py +++ b/lib4sbom/cyclonedx/cyclonedx_parser.py @@ -298,7 +298,8 @@ def _cyclondex_component(self, d): if "licenses" in d: license_data = self.process_license(d["licenses"]) elif "evidence" in d: - license_data = self.process_license(d["evidence"]) + if "licenses" in d["evidence"]: + license_data = self.process_license(d["evidence"]["licenses"]) if license_data is not None and len(license_data) > 0: # Multiple ways of defining licenses for license_info in license_data: