1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-10 09:49:05 +00:00

Pass "ssl" as the third paramater to connect() in pop3.lua capabilities() and

smtp-commands.nse if version detection set the port service_tunnel to "ssl".
This commit is contained in:
jah
2009-02-03 02:43:24 +00:00
parent b05f66d43a
commit c622a1518e
2 changed files with 5 additions and 3 deletions

View File

@@ -149,7 +149,8 @@ function capabilities(host, port)
local socket = nmap.new_socket()
local capas = {}
socket:set_timeout(10000)
if not socket:connect(host.ip, port.number) then return nil, "Could Not Connect" end
local proto = (port.version and port.version.service_tunnel == "ssl" and "ssl") or "tcp"
if not socket:connect(host.ip, port.number, proto) then return nil, "Could Not Connect" end
status, line = socket:receive_lines(1)
if not stat(line) then return nil, "No Response" end