mirror of
https://github.com/nmap/nmap.git
synced 2025-12-17 13:09:02 +00:00
Avoid attempting TLS over UDP protocols in sslcert.lua
This commit is contained in:
@@ -640,6 +640,9 @@ local SPECIALIZED_WRAPPED_TLS_WITHOUT_RECONNECT = {
|
|||||||
-- @param port A port table with 'number' and 'service' keys
|
-- @param port A port table with 'number' and 'service' keys
|
||||||
-- @return A STARTTLS function or nil
|
-- @return A STARTTLS function or nil
|
||||||
function getPrepareTLSWithoutReconnect(port)
|
function getPrepareTLSWithoutReconnect(port)
|
||||||
|
if port.protocol == 'udp' then
|
||||||
|
return nil
|
||||||
|
end
|
||||||
if ( port.version and port.version.service_tunnel == 'ssl') then
|
if ( port.version and port.version.service_tunnel == 'ssl') then
|
||||||
return nil
|
return nil
|
||||||
end
|
end
|
||||||
@@ -656,6 +659,9 @@ end
|
|||||||
-- @param port A port table with 'number' and 'service' keys
|
-- @param port A port table with 'number' and 'service' keys
|
||||||
-- @return A STARTTLS function or nil
|
-- @return A STARTTLS function or nil
|
||||||
function isPortSupported(port)
|
function isPortSupported(port)
|
||||||
|
if port.protocol == 'udp' then
|
||||||
|
return nil
|
||||||
|
end
|
||||||
if ( port.version and port.version.service_tunnel == 'ssl') then
|
if ( port.version and port.version.service_tunnel == 'ssl') then
|
||||||
return nil
|
return nil
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user