@@ -102,10 +102,12 @@ def get_severity_justification(vulnerability):
102102def process_component (component ):
103103 mitigation = ""
104104 impact = "**Impact paths**\n \n - "
105+ fix_available = False
105106 fixed_versions = component .get ("fixed_versions" )
106107 if fixed_versions :
107108 mitigation = "**Versions containing a fix:**\n \n - "
108109 mitigation += "\n - " .join (fixed_versions )
110+ fix_available = True
109111 if "impact_paths" in component :
110112 refs = []
111113 impact_paths_l1 = component ["impact_paths" ]
@@ -117,7 +119,7 @@ def process_component(component):
117119 refs .append (item ["full_path" ])
118120 if refs :
119121 impact += "\n - " .join (sorted (set (refs ))) # deduplication
120- return mitigation , impact
122+ return mitigation , impact , fix_available
121123
122124
123125def get_cve (vulnerability ):
@@ -158,7 +160,7 @@ def get_item_set(vulnerability):
158160
159161 for component_name_with_version , component in vulnerability .get ("components" , {}).items ():
160162 component_name , component_version = get_component_name_version (component_name_with_version )
161- mitigation , impact = process_component (component )
163+ mitigation , impact , fix_available = process_component (component )
162164
163165 title = clean_title (vulnerability ["summary" ])
164166 # create the finding object
@@ -176,6 +178,7 @@ def get_item_set(vulnerability):
176178 dynamic_finding = False ,
177179 cvssv3 = cvssv3 ,
178180 vuln_id_from_tool = vuln_id_from_tool ,
181+ fix_available = fix_available ,
179182 )
180183 if vulnerability_ids :
181184 finding .unsaved_vulnerability_ids = vulnerability_ids
0 commit comments