1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-15 20:29:03 +00:00

Add kex strengths for alternative EC named curves

This commit is contained in:
dmiller
2017-10-31 04:26:57 +00:00
parent c0f605052d
commit 8efe4f35aa

View File

@@ -787,6 +787,10 @@ local function unpack_ecdhparams (blob, pos)
local size = ret.curve_params.curve:match("(%d+)[rk]%d$")
if size then
strength = tonumber(size)
elseif ret.curve_params.curve == "ecdh_x25519" then
strength = 256
elseif ret.curve_params.curve == "ecdh_x448" then
strength = 448
end
end
ret.public, pos = unpack("s1", blob, pos)