Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.
Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.
Path: blob/master/modules/auxiliary/vsploit/malware/dns/dns_mariposa.rb
Views: 11766
##1# This module requires Metasploit: https://metasploit.com/download2# Current source: https://github.com/rapid7/metasploit-framework3##45class MetasploitModule < Msf::Auxiliary67def initialize8super(9'Name' => 'VSploit Mariposa DNS Query Module',10'Description' => 'This module queries known Mariposa Botnet DNS records.',11'Author' => 'MJC',12'License' => MSF_LICENSE,13'References' =>14[15[ 'URL', 'http://www.defintel.com/docs/Mariposa_Analysis.pdf']16]17)18register_options(19[20OptString.new('DNS_SERVER',[false, "Specifies a DNS Server"]),21OptInt.new('COUNT', [false, "Number of intervals to loop",1]),22OptInt.new('DELAY', [false, "Delay in seconds between intervals",3])23])24end2526def run27@res = Net::DNS::Resolver.new()2829domain = [30"lalundelau.sinip.es","bf2back.sinip.es","thejacksonfive.mobi",31"thejacksonfive.us","thejacksonfive.biz","butterfly.BigMoney.biz",32"bfisback.sinip.es","bfisback.no-ip.org","qwertasdfg.sinip.es",33"shv4b.getmyip.com","shv4.no-ip.biz","butterfly.sinip.es",34"defintelsucks.sinip.es","defintelsucks.net","defintelsucks.com",35"gusanodeseda.sinip.es","gusanodeseda.net","legion.sinip.es",36"booster.estr.es","sexme.in","extraperlo.biz",37"legionarios.servecounterstrike.com","thesexydude.com",38"yougotissuez.com","gusanodeseda.mobi","tamiflux.org",39"tamiflux.net","binaryfeed.in","youare.sexidude.com",40"mierda.notengodominio.com",41]4243if datastore['DNS_SERVER']44@res.nameservers = datastore['DNS_SERVER']45end4647count = 04849while count < datastore['COUNT']5051domain.each do |name|52query = @res.query(name, "A")53time = Time.new54time = time.strftime("%Y-%m-%d %H:%M:%S")55print_status("#{time} - DNS Query sent for => #{name}")56if query.answer.length == 057print_error("#{time} - #{name} => No Record Found")58else59a = query.answer[0].to_s.split(/[\s,]+/)60print_good("#{time} - #{name} => #{a[-1]}")61end62end63unless count == (datastore['COUNT'] - 1)64time = Time.new65time = time.strftime("%Y-%m-%d %H:%M:%S")66print_status("#{time} - Waiting #{datastore['DELAY']} seconds to query")67select(nil, nil, nil, datastore['DELAY'])68end69count += 170end71end72end737475