mirror of
https://github.com/nmap/nmap.git
synced 2025-12-10 09:49:05 +00:00
Use default EC curves instead of all throughout.
This commit is contained in:
@@ -120,12 +120,9 @@ local function test_ccs_injection(host, port, version)
|
|||||||
["ciphers"] = stdnse.keys(tls.CIPHERS),
|
["ciphers"] = stdnse.keys(tls.CIPHERS),
|
||||||
["compressors"] = {"NULL"},
|
["compressors"] = {"NULL"},
|
||||||
["extensions"] = {
|
["extensions"] = {
|
||||||
-- Claim to support every elliptic curve
|
-- Claim to support common elliptic curves
|
||||||
["elliptic_curves"] = tls.EXTENSION_HELPERS["elliptic_curves"](
|
["elliptic_curves"] = tls.EXTENSION_HELPERS["elliptic_curves"](
|
||||||
stdnse.keys(tls.ELLIPTIC_CURVES)),
|
tls.DEFAULT_ELLIPTIC_CURVES),
|
||||||
-- Claim to support every EC point format
|
|
||||||
["ec_point_formats"] = tls.EXTENSION_HELPERS["ec_point_formats"](
|
|
||||||
stdnse.keys(tls.EC_POINT_FORMATS)),
|
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|||||||
@@ -515,10 +515,8 @@ end
|
|||||||
local function base_extensions(host)
|
local function base_extensions(host)
|
||||||
local tlsname = tls.servername(host)
|
local tlsname = tls.servername(host)
|
||||||
return {
|
return {
|
||||||
-- Claim to support every elliptic curve
|
-- Claim to support common elliptic curves
|
||||||
["elliptic_curves"] = tls.EXTENSION_HELPERS["elliptic_curves"](sorted_keys(tls.ELLIPTIC_CURVES)),
|
["elliptic_curves"] = tls.EXTENSION_HELPERS["elliptic_curves"](tls.DEFAULT_ELLIPTIC_CURVES),
|
||||||
-- Claim to support every EC point format
|
|
||||||
["ec_point_formats"] = tls.EXTENSION_HELPERS["ec_point_formats"](sorted_keys(tls.EC_POINT_FORMATS)),
|
|
||||||
-- Enable SNI if a server name is available
|
-- Enable SNI if a server name is available
|
||||||
["server_name"] = tlsname and tls.EXTENSION_HELPERS["server_name"](tlsname),
|
["server_name"] = tlsname and tls.EXTENSION_HELPERS["server_name"](tlsname),
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -76,10 +76,8 @@ local function testversion(host, port, version)
|
|||||||
["ciphers"] = stdnse.keys(tls.CIPHERS),
|
["ciphers"] = stdnse.keys(tls.CIPHERS),
|
||||||
["compressors"] = {"NULL"},
|
["compressors"] = {"NULL"},
|
||||||
["extensions"] = {
|
["extensions"] = {
|
||||||
-- Claim to support every elliptic curve
|
-- Claim to support common elliptic curves
|
||||||
["elliptic_curves"] = tls.EXTENSION_HELPERS["elliptic_curves"](stdnse.keys(tls.ELLIPTIC_CURVES)),
|
["elliptic_curves"] = tls.EXTENSION_HELPERS["elliptic_curves"](tls.DEFAULT_ELLIPTIC_CURVES),
|
||||||
-- Claim to support every EC point format
|
|
||||||
["ec_point_formats"] = tls.EXTENSION_HELPERS["ec_point_formats"](stdnse.keys(tls.EC_POINT_FORMATS)),
|
|
||||||
["heartbeat"] = "\x01", -- peer_not_allowed_to_send
|
["heartbeat"] = "\x01", -- peer_not_allowed_to_send
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -177,10 +177,8 @@ end
|
|||||||
local function base_extensions(host)
|
local function base_extensions(host)
|
||||||
local tlsname = tls.servername(host)
|
local tlsname = tls.servername(host)
|
||||||
return {
|
return {
|
||||||
-- Claim to support every elliptic curve
|
-- Claim to support common elliptic curves
|
||||||
["elliptic_curves"] = tls.EXTENSION_HELPERS["elliptic_curves"](sorted_keys(tls.ELLIPTIC_CURVES)),
|
["elliptic_curves"] = tls.EXTENSION_HELPERS["elliptic_curves"](tls.DEFAULT_ELLIPTIC_CURVES),
|
||||||
-- Claim to support every EC point format
|
|
||||||
["ec_point_formats"] = tls.EXTENSION_HELPERS["ec_point_formats"](sorted_keys(tls.EC_POINT_FORMATS)),
|
|
||||||
-- Enable SNI if a server name is available
|
-- Enable SNI if a server name is available
|
||||||
["server_name"] = tlsname and tls.EXTENSION_HELPERS["server_name"](tlsname),
|
["server_name"] = tlsname and tls.EXTENSION_HELPERS["server_name"](tlsname),
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -218,10 +218,8 @@ local function is_vuln(host, port, version)
|
|||||||
["ciphers"] = stdnse.keys(tls.CIPHERS),
|
["ciphers"] = stdnse.keys(tls.CIPHERS),
|
||||||
["compressors"] = {"NULL"},
|
["compressors"] = {"NULL"},
|
||||||
["extensions"] = {
|
["extensions"] = {
|
||||||
-- Claim to support every elliptic curve
|
-- Claim to support common elliptic curves
|
||||||
["elliptic_curves"] = tls.EXTENSION_HELPERS["elliptic_curves"](stdnse.keys(tls.ELLIPTIC_CURVES)),
|
["elliptic_curves"] = tls.EXTENSION_HELPERS["elliptic_curves"](tls.DEFAULT_ELLIPTIC_CURVES),
|
||||||
-- Claim to support every EC point format
|
|
||||||
["ec_point_formats"] = tls.EXTENSION_HELPERS["ec_point_formats"](stdnse.keys(tls.EC_POINT_FORMATS)),
|
|
||||||
["SessionTicket TLS"] = ticket,
|
["SessionTicket TLS"] = ticket,
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user