Tweak the snmp_login code to actually only poll response packets every 10 sent and break out of infinite loop in the case of a target going crazy and continuously replying

git-svn-id: file:///home/svn/framework3/trunk@13891 4d416f70-5f16-0410-b530-b9f4589650da
This commit is contained in:
HD Moore
2011-10-12 20:14:58 +00:00
parent 9bbb104115
commit cce4aafd9b
+5 -2
View File
@@ -93,15 +93,18 @@ class Metasploit3 < Msf::Auxiliary
parse_reply(r)
end
end
idx += 1
end
end
while (r = udp_sock.recvfrom(65535, 3) and r[1])
idx = 0
while (r = udp_sock.recvfrom(65535, 3) and r[1] and idx < 500)
parse_reply(r)
idx += 1
end
if @found.keys.length > 0
print_status("Validating scan results from #{@found.keys.length} hosts...")
end