mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-29 23:49:33 +00:00
Fixes flow alerts table column width and description
This commit is contained in:
parent
4f0ac39efe
commit
39d3618351
8 changed files with 17 additions and 12 deletions
|
|
@ -60,7 +60,8 @@ end
|
|||
-- @param alert_type_params Table `alert_type_params` as built in the `:init` method
|
||||
-- @return A human-readable string
|
||||
function alert_connection_issues.format(ifid, alert, alert_type_params)
|
||||
format_utils.formatConnectionIssues(alert_type_params)
|
||||
local res = format_utils.formatConnectionIssues(alert_type_params)
|
||||
return res
|
||||
end
|
||||
|
||||
-- #######################################################
|
||||
|
|
|
|||
|
|
@ -50,14 +50,14 @@ end
|
|||
-- @return A human-readable string
|
||||
function alert_tls_certificate_expired.format(ifid, alert, alert_type_params)
|
||||
if not alert_type_params then
|
||||
return i18n("flow_details.tls_certificate_expired")
|
||||
return
|
||||
end
|
||||
|
||||
local crts = {}
|
||||
crts[#crts + 1] = formatEpoch(alert_type_params["tls_crt.notBefore"])
|
||||
crts[#crts + 1] = formatEpoch(alert_type_params["tls_crt.notAfter"])
|
||||
|
||||
return string.format("%s [%s]", i18n("flow_details.tls_certificate_expired"), table.concat(crts, " - "))
|
||||
return string.format("[%s]", table.concat(crts, " - "))
|
||||
end
|
||||
|
||||
-- #######################################################
|
||||
|
|
|
|||
|
|
@ -52,7 +52,7 @@ end
|
|||
-- @return A human-readable string
|
||||
function alert_tls_certificate_mismatch.format(ifid, alert, alert_type_params)
|
||||
if not alert_type_params then
|
||||
return i18n("flow_details.tls_certificate_mismatch")
|
||||
return
|
||||
end
|
||||
|
||||
local crts = {}
|
||||
|
|
@ -64,7 +64,7 @@ function alert_tls_certificate_mismatch.format(ifid, alert, alert_type_params)
|
|||
crts[#crts + 1] = string.format("[%s: %s]", i18n("flow_details.tls_server_names"), alert_type_params["tls_crt.srv"]:gsub(",", ", "))
|
||||
end
|
||||
|
||||
return string.format("%s %s", i18n("flow_details.tls_certificate_mismatch"), table.concat(crts, " "))
|
||||
return string.format("%s", table.concat(crts, " "))
|
||||
end
|
||||
|
||||
-- #######################################################
|
||||
|
|
|
|||
|
|
@ -49,13 +49,13 @@ end
|
|||
-- @return A human-readable string
|
||||
function alert_tls_certificate_selfsigned.format(ifid, alert, alert_type_params)
|
||||
if not alert_type_params then
|
||||
return i18n("flow_details.tls_certificate_selfsigned")
|
||||
return
|
||||
end
|
||||
|
||||
local crts = {}
|
||||
crts[#crts + 1] = alert_type_params["tls_crt.issuerDN"]
|
||||
|
||||
return string.format("%s [Issuer/Subject: %s]", i18n("flow_details.tls_certificate_selfsigned"), table.concat(crts, " - "))
|
||||
return string.format("[Issuer/Subject: %s]", table.concat(crts, " - "))
|
||||
end
|
||||
|
||||
-- #######################################################
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ end
|
|||
-- @param alert_type_params Table `alert_type_params` as built in the `:init` method
|
||||
-- @return A human-readable string
|
||||
function alert_tls_old_protocol_version.format(ifid, alert, alert_type_params)
|
||||
local msg = i18n("flow_details.tls_old_protocol_version")
|
||||
local msg = ""
|
||||
|
||||
if(alert_type_params and alert_type_params.tls_version) then
|
||||
local ver_str = ntop.getTLSVersionName(alert_type_params.tls_version)
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@ end
|
|||
-- @param alert_type_params Table `alert_type_params` as built in the `:init` method
|
||||
-- @return A human-readable string
|
||||
function alert_tls_unsafe_ciphers.format(ifid, alert, alert_type_params)
|
||||
return i18n("flow_details.tls_unsafe_ciphers")
|
||||
return
|
||||
end
|
||||
|
||||
-- #######################################################
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue