Vulnerability dashboard: Update result name in MySQL query. (#35368)

Changes:
- Updated the query to find critically vulnerable rare software for
MySQL databases to return affected host names as `hostNames`
This commit is contained in:
Eric 2025-11-07 14:38:17 -06:00 committed by GitHub
parent 7e76277604
commit ef2ce8bd7f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -511,7 +511,7 @@ module.exports = {
queryToFindTopUniqueCriticalSoftwareWithMostVulnerabilities = `
SELECT
vi.softwareName,
GROUP_CONCAT(DISTINCT h.displayName SEPARATOR ', ') AS host_names,
GROUP_CONCAT(DISTINCT h.displayName SEPARATOR ', ') AS hostNames,
GROUP_CONCAT(DISTINCT v.cveId SEPARATOR ', ') AS cves,
GROUP_CONCAT(DISTINCT v.cveDescription SEPARATOR '; ') AS descriptions,
COUNT(DISTINCT vi.host) AS host_install_count
@ -602,7 +602,6 @@ module.exports = {
fleetUrl: `${sails.config.custom.fleetBaseUrl}/software/vulnerabilities/${cveId}`
};
});
return {
softwareNameAndVersion: software.softwareName,
fleetUrl: `${sails.config.custom.fleetBaseUrl}/software/versions/${software.fleetApid}`,